mirror of
https://github.com/LCPQ/quantum_package
synced 2024-12-22 20:35:19 +01:00
Fix ezfio path and ocaml version
This commit is contained in:
parent
9eae6e0d9c
commit
5dc7810bde
2
configure
vendored
2
configure
vendored
@ -453,7 +453,7 @@ def create_ninja_and_rc(l_installed):
|
||||
'export IRPF90={0}'.format(path_irpf90),
|
||||
'export NINJA={0}'.format(path_ninja),
|
||||
'export QP_PYTHON={0}'.format(":".join(l_python)), "",
|
||||
'export PYTHONPATH="${QP_EZFIO}":"${QP_PYTHON}":"${PYTHONPATH}"',
|
||||
'export PYTHONPATH="${QP_EZFIO}/Python":"${QP_PYTHON}":"${PYTHONPATH}"',
|
||||
'export PATH="${QP_PYTHON}":"${QP_ROOT}"/bin:"${QP_ROOT}"/ocaml:"${PATH}"',
|
||||
'export LD_LIBRARY_PATH="${QP_ROOT}"/lib:"${LD_LIBRARY_PATH}"',
|
||||
'export LIBRARY_PATH="${QP_ROOT}"/lib:"${LIBRARY_PATH}"', "",
|
||||
|
@ -7,9 +7,18 @@ cd -
|
||||
# Normal installation
|
||||
PACKAGES="core cryptokit ocamlfind sexplib"
|
||||
|
||||
declare -i i
|
||||
i=$(gcc -dumpversion | cut -d '.' -f 2)
|
||||
if [[ i -lt 6 ]]
|
||||
# return 0 if program version is equal or greater than check version
|
||||
check_version()
|
||||
{
|
||||
local version=$1 check=$2
|
||||
local winner=$(echo -e "$version\n$check" | sed '/^$/d' | sort -nr | head -1)
|
||||
[[ "$winner" = "$version" ]] && return 0
|
||||
return 1
|
||||
}
|
||||
|
||||
i=$(gcc -dumpversion)
|
||||
|
||||
if check_version i 4.6
|
||||
then
|
||||
echo "GCC version $(gcc -dumpversion) too old. GCC >= 4.6 required."
|
||||
exit 1
|
||||
|
Loading…
Reference in New Issue
Block a user