-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathenv_setup
executable file
·28 lines (19 loc) · 910 Bytes
/
env_setup
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
#!/bin/bash
set -a
# Guess the nxt files installation directory
NXT_PATH=`case $(dirname ${BASH_SOURCE:-$0}) in /*) dirname ${BASH_SOURCE:-$0} ;; *) dirname $PWD/${BASH_SOURCE:-$0} ;; esac`
# Add a pointer to the trampoline install directory.
NXT_TRAMPOLINE_PATH="${NXT_PATH}/trampoline/"
# Add a pointer to the cross-compiler install directory.
NXT_GCC_PATH="${NXT_PATH}/gcc-arm-elf/"
NXT_GCC_LIBGCC_VERSION=`[ -d "${NXT_GCC_PATH}/lib/gcc/arm-elf/" ] && ls -1p ${NXT_GCC_PATH}/lib/gcc/arm-elf/ | grep '/$' | tail -n 1 | sed -e 's#/$##' `
# Add a pointer to the application skeleton directory.
NXT_TEMPLATE_PATH="${NXT_PATH}/app_template/"
# Add gcc-arm to the path.
PATH="${PATH}:${NXT_GCC_PATH}/bin/"
# Add nexttool to the path.
PATH="${PATH}:${NXT_PATH}/nexttool"
# Add goil to the path.
PATH="${PATH}:${NXT_TRAMPOLINE_PATH}/bin"
# Add nxt_* scripts to the path
PATH="${PATH}:${NXT_PATH}/scripts"