Commit | Line | Data |
---|---|---|
29104708 LOK |
1 | TOOLCHAIN_GIT="git://github.com/raspberrypi/tools.git" |
2 | FIRMWARE_GIT="git://github.com/raspberrypi/firmware.git" | |
3 | TARBALL_LOCATION="http://sources.openelec.tv/devel/" | |
4 | LOCKDEV_TARBALL="lockdev-16b8996.tar.xz" | |
5 | ||
6 | _set_toolchain_path() | |
7 | { | |
8 | echo "Setting toolchain path to: '$1'" | |
9 | ||
10 | export TARGET_TOOLCHAIN_PATH="$1/arm-bcm2708/arm-bcm2708hardfp-linux-gnueabi/bin" | |
11 | export TARGET_TOOLCHAIN_LIB_PATH="$1/arm-bcm2708/arm-bcm2708hardfp-linux-gnueabi/lib" | |
12 | export TARGET_HOST="arm-bcm2708hardfp-linux-gnueabi" | |
13 | ||
14 | export CC=${TARGET_TOOLCHAIN_PATH}/${TARGET_HOST}-gcc | |
15 | export CXX=${TARGET_TOOLCHAIN_PATH}/${TARGET_HOST}-g++ | |
16 | export LD=${TARGET_TOOLCHAIN_PATH}/${TARGET_HOST}-ld | |
17 | export AS=${TARGET_TOOLCHAIN_PATH}/${TARGET_HOST}-as | |
18 | export AR=${TARGET_TOOLCHAIN_PATH}/${TARGET_HOST}-ar | |
19 | export NM=${TARGET_TOOLCHAIN_PATH}/${TARGET_HOST}-nm | |
20 | export RANLIB=${TARGET_TOOLCHAIN_PATH}/${TARGET_HOST}-ranlib | |
21 | export OBJCOPY=${TARGET_TOOLCHAIN_PATH}/${TARGET_HOST}-objcopy | |
22 | export OBJDUMP=${TARGET_TOOLCHAIN_PATH}/${TARGET_HOST}-objdump | |
23 | export STRIP=${TARGET_TOOLCHAIN_PATH}/${TARGET_HOST}-strip | |
24 | ||
25 | export CPPFLAGS="-I${SCRIPT_PATH}/deps/include" | |
26 | export CFLAGS="-march=armv6 -mfpu=vfp -mfloat-abi=hard -Wno-psabi -Wa,-mno-warn-deprecated -O3 -fexcess-precision=fast -ffast-math -I${SCRIPT_PATH}/deps/include" | |
27 | export CXXFLAGS="$CFLAGS" | |
28 | export LDFLAGS="-march=armv6 -mtune=arm1176jzf-s -L${SCRIPT_PATH}/deps/lib" | |
29 | ||
30 | #export PKG_CONFIG_PATH="$TARGET_PKG_CONFIG_PATH" | |
31 | export PKG_CONFIG_LIBDIR="${SCRIPT_PATH}/deps/lib/pkgconfig:${SCRIPT_PATH}/deps/lib/share/pkgconfig" | |
32 | export PKG_CONFIG_SYSROOT_DIR="${SCRIPT_PATH}/deps" | |
33 | ||
34 | export PATH="$TARGET_TOOLCHAIN_PATH:$PATH" | |
35 | export LD_LIBRARY_PATH="$TARGET_TOOLCHAIN_LIB_PATH:$LD_LIBRARY_PATH" | |
36 | } | |
37 |