2017-02-16 21:40:17 +00:00
|
|
|
#!/bin/bash -ex
|
2016-02-04 09:16:52 +00:00
|
|
|
|
|
|
|
FILE=cross2-20130826.tgz
|
|
|
|
INSTALL_DIR=$PWD
|
|
|
|
|
|
|
|
[ ! -e $FILE ] && wget http://kozos.jp/books/asm/$FILE
|
2016-02-04 22:33:05 +00:00
|
|
|
tar xf $FILE
|
2016-02-04 09:16:52 +00:00
|
|
|
|
|
|
|
cd cross2/toolchain
|
|
|
|
./fetch.sh
|
|
|
|
./setup.sh
|
|
|
|
cd ..
|
|
|
|
sed -i -e "s|#makeopt=.*|makeopt='-j'|" config.sh
|
|
|
|
sed -i -e "s|install_dir.*|install_dir=\"$INSTALL_DIR\"|" config.sh
|
|
|
|
cd build
|
2016-02-04 22:33:05 +00:00
|
|
|
./build-install-all.sh
|
2016-02-04 22:30:18 +00:00
|
|
|
|
|
|
|
mkdir -p bin
|
|
|
|
cd bin
|
|
|
|
for i in ../*/bin/*
|
|
|
|
do
|
|
|
|
F=$(basename $i)
|
|
|
|
D=$(basename $(dirname $(dirname $i)))
|
|
|
|
[ -f $D-$F ] || ln -s $i $D-$F
|
|
|
|
done
|
|
|
|
cd ..
|