renamed win q7s env script
This commit is contained in:
parent
44a0d4af61
commit
a359afb1c3
49
cmake/scripts/Q7S/win-q7s-env.sh
Normal file
49
cmake/scripts/Q7S/win-q7s-env.sh
Normal file
@ -0,0 +1,49 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
# Run with: source win-q7s-env.sh [OPTIONS]
|
||||||
|
function help () {
|
||||||
|
echo "source win-q7s-env.sh [options] -t|--toolchain=<toolchain path> -s|--sysroot=<sysroot path>"
|
||||||
|
}
|
||||||
|
|
||||||
|
TOOLCHAIN_PATH="/c/Xilinx/Vitis/2019.2/gnu/aarch32/nt/gcc-arm-linux-gnueabi/bin"
|
||||||
|
SYSROOT="/c/Users/${USER}/eive-software/cortexa9hf-neon-xiphos-linux-gnueabi"
|
||||||
|
|
||||||
|
for i in "$@"; do
|
||||||
|
case $i in
|
||||||
|
-t=*|--toolchain=*)
|
||||||
|
TOOLCHAIN_PATH="${i#*=}"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
-s=*|--sysroot=*)
|
||||||
|
SYSROOT="${i#*=}"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
-h|--help)
|
||||||
|
help
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
-*|--*)
|
||||||
|
echo "Unknown option $i"
|
||||||
|
help
|
||||||
|
return
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
if [ -d "$TOOLCHAIN_PATH" ]; then
|
||||||
|
export PATH=$PATH:"/c/Xilinx/Vitis/2019.2/gnu/aarch32/nt/gcc-arm-linux-gnueabi/bin"
|
||||||
|
export CROSS_COMPILE="arm-linux-gnueabihf"
|
||||||
|
echo "Set toolchain path to /c/Xilinx/Vitis/2019.2/gnu/aarch32/nt/gcc-arm-linux-gnueabi/bin"
|
||||||
|
else
|
||||||
|
echo "Toolchain path $TOOLCHAIN_PATH does not exist"
|
||||||
|
return
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -d "$SYSROOT" ]; then
|
||||||
|
export ZYNQ_7020_SYSROOT=$SYSROOT
|
||||||
|
echo "Set sysroot path to $SYSROOT"
|
||||||
|
else
|
||||||
|
echo "Sysroot path $SYSROOT does not exist"
|
||||||
|
return
|
||||||
|
fi
|
Loading…
Reference in New Issue
Block a user