Blame view
tools/extras/install_liblbfgs.sh
771 Bytes
8dcb6dfcb first commit |
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 |
#!/bin/bash VER=1.10 if [ ! -f liblbfgs-$VER.tar.gz ]; then wget https://github.com/downloads/chokkan/liblbfgs/liblbfgs-$VER.tar.gz fi tar -xzf liblbfgs-$VER.tar.gz cd liblbfgs-$VER ./configure --prefix=`pwd` make # due to the liblbfgs project directory structure, we have to use -i # but the erros are completely harmless make -i install cd .. ( [ ! -z "${LIBLBFGS}" ] && \ echo >&2 "LIBLBFGS variable is aleady defined. Undefining..." && \ unset LIBLBFGS [ -f ./env.sh ] && . ./env.sh [ ! -z "${LIBLBFGS}" ] && \ echo >&2 "libLBFGS config is already in env.sh" && exit wd=`pwd` wd=`readlink -f $wd || pwd` echo "export LIBLBFGS=$wd/liblbfgs-1.10" echo export LD_LIBRARY_PATH='${LD_LIBRARY_PATH:-}':'${LIBLBFGS}'/lib/.libs ) >> env.sh |