-
Notifications
You must be signed in to change notification settings - Fork 454
/
setup_env.sh
executable file
·34 lines (28 loc) · 1.15 KB
/
setup_env.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
OLD_PWD=$(pwd)
cd $(dirname ${BASH_SOURCE[0]})
export ARCH=arm
export SUBARCH=arm
export KERNEL=kernel7
export HOSTUNAME=$(uname -s)
export PLATFORMUNAME=$(uname -m)
export NEXMON_ROOT=$(pwd)
if [ $HOSTUNAME == "Darwin" ]; then
export CC=$NEXMON_ROOT/buildtools/gcc-arm-none-eabi-5_4-2016q2-osx/bin/arm-none-eabi-
export CCPLUGIN=$NEXMON_ROOT/buildtools/gcc-nexmon-plugin-osx/nexmon.so
export ZLIBFLATE="openssl zlib"
else if [ $HOSTUNAME == "Linux" ] && [ $PLATFORMUNAME == "x86_64" ]; then
export CC=$NEXMON_ROOT/buildtools/gcc-arm-none-eabi-5_4-2016q2-linux-x86/bin/arm-none-eabi-
export CCPLUGIN=$NEXMON_ROOT/buildtools/gcc-nexmon-plugin/nexmon.so
export ZLIBFLATE="zlib-flate -compress"
else if [[ $HOSTUNAME == "Linux" ]] && [[ $PLATFORMUNAME == "armv7l" || $PLATFORMUNAME == "armv6l" || $PLATFORMUNAME == "aarch64" ]]; then
export CC=$NEXMON_ROOT/buildtools/gcc-arm-none-eabi-5_4-2016q2-linux-armv7l/bin/arm-none-eabi-
export CCPLUGIN=$NEXMON_ROOT/buildtools/gcc-nexmon-plugin-arm/nexmon.so
export ZLIBFLATE="zlib-flate -compress"
else
echo "Platform not supported!"
fi
fi
fi
export Q=@
export NEXMON_SETUP_ENV=1
cd "$OLD_PWD"