1
0
mirror of https://github.com/aportelli/LatAnalyze.git synced 2025-06-17 06:47:06 +01:00

CI with Travis and loads of portability fixes

This commit is contained in:
2016-04-08 00:42:11 +01:00
parent 8dd3b110e0
commit cdf516b5ac
10 changed files with 214 additions and 12 deletions

10
ci-scripts/install-deps.sh Executable file
View File

@ -0,0 +1,10 @@
#!/usr/bin/env bash
set -ex
mkdir -p local/build
for d in nlopt minuit hdf5; do
if [ ! -e local/.built.${d} ]; then
./install-${d}.sh
fi
done
./install-latcore.sh

17
ci-scripts/install-hdf5.sh Executable file
View File

@ -0,0 +1,17 @@
#!/usr/bin/env bash
NAME='hdf5-1.8.16'
set -ex
INITDIR=`pwd`
cd local/build
wget http://www.hdfgroup.org/ftp/HDF5/current/src/${NAME}.tar.gz
tar -xzvf ${NAME}.tar.gz
mkdir ${NAME}/build
cd ${NAME}/build
../configure --prefix=${INITDIR}/local --enable-cxx
make -j4
make install
cd ${INITDIR}/local
touch .built.hdf5
cd ${INITDIR}

20
ci-scripts/install-latan.sh Executable file
View File

@ -0,0 +1,20 @@
#!/usr/bin/env bash
if (( $# != 2 )); then
echo "usage: `basename $0` <prefix> {osx|linux}" 1>&2
exit 1
fi
LATAN_PREFIX=$1
OS=$2
set -ex
PREFIX=`pwd`/local
./install-deps.sh
cd ..
./bootstrap.sh
mkdir -p build
cd build
if [[ "$OS" == "osx" ]]; then EXTRA_FLAGS='--with-gsl=/usr/local'; fi
../configure --prefix=$LATAN_PREFIX --with-minuit=$PREFIX --with-nlopt=$PREFIX --with-latcore=$PREFIX --with-hdf5=$PREFIX $EXTRA_FLAGS
make -j4
make install

19
ci-scripts/install-latcore.sh Executable file
View File

@ -0,0 +1,19 @@
#!/usr/bin/env bash
set -ex
INITDIR=`pwd`
cd local/build
if [ -d LatCore ]; then
cd LatCore
git pull origin master
else
git clone https://github.com/aportelli/LatCore.git
mkdir LatCore/build
cd LatCore
./bootstrap.sh
fi
cd build
../configure --prefix=${INITDIR}/local
make -j4
make install
cd ${INITDIR}

17
ci-scripts/install-minuit.sh Executable file
View File

@ -0,0 +1,17 @@
#!/usr/bin/env bash
NAME='Minuit2-5.34.14'
set -ex
INITDIR=`pwd`
cd local/build
wget http://www.cern.ch/mathlibs/sw/5_34_14/Minuit2/${NAME}.tar.gz
tar -xzvf ${NAME}.tar.gz
mkdir -p ${NAME}/build
cd ${NAME}/build
../configure --prefix=${INITDIR}/local --disable-openmp
make -j4
make install
cd ${INITDIR}/local
touch .built.minuit
cd ${INITDIR}

17
ci-scripts/install-nlopt.sh Executable file
View File

@ -0,0 +1,17 @@
#!/usr/bin/env bash
NAME='nlopt-2.4.2'
set -ex
INITDIR=`pwd`
cd local/build
wget http://ab-initio.mit.edu/nlopt/${NAME}.tar.gz
tar -xzvf ${NAME}.tar.gz
mkdir -p ${NAME}/build
cd ${NAME}/build
../configure --prefix=${INITDIR}/local --with-cxx --without-guile --without-python --without-octave --without-matlab --with-pic
make -j4
make install
cd ${INITDIR}/local
touch .built.nlopt
cd ${INITDIR}