10
1
mirror of https://gitlab.com/scemama/qmcchem.git synced 2024-11-15 18:43:39 +01:00
qmcchem/install/scripts/install_ocaml_zmq.sh

37 lines
561 B
Bash
Raw Normal View History

2015-12-18 22:25:32 +01:00
#!/bin/bash -x
2015-12-18 22:53:27 +01:00
cd .. ; QMCCHEM_PATH="$PWD" ; cd -
2015-12-18 22:25:32 +01:00
set -e
set -u
2015-12-18 22:53:27 +01:00
# Check GCC version
2015-12-18 22:25:32 +01:00
declare -i i
2015-12-18 22:53:27 +01:00
i=$(gcc -dumpversion | cut -d '.' -f 1)
if [[ i -lt 4 ]]
2015-12-18 22:25:32 +01:00
then
echo "GCC version $(gcc -dumpversion) too old. GCC >= 4.6 required."
exit 1
fi
2015-12-18 22:53:27 +01:00
if [[ i -eq 4 ]]
then
i=$(gcc -dumpversion | cut -d '.' -f 2)
if [[ i -lt 6 ]]
then
echo "GCC version $(gcc -dumpversion) too old. GCC >= 4.6 required."
exit 1
fi
fi
# End check GCC version
2015-12-18 22:25:32 +01:00
set +u
2015-12-18 22:53:27 +01:00
source "${QMCCHEM_PATH}"/qmcchemrc
2015-12-18 22:25:32 +01:00
set -u
opam install zmq
rm -f _build/ocaml_zmq.log
exit 0