Commit 78ceea82 authored by incardon's avatar incardon

New configure

parent 1c50460a
Pipeline #918 failed with stages
in 3 minutes and 16 seconds
...@@ -10,7 +10,6 @@ if [ ! -d $HOME/openfpm_dependencies/openfpm_data/LIBHILBERT ]; then ...@@ -10,7 +10,6 @@ if [ ! -d $HOME/openfpm_dependencies/openfpm_data/LIBHILBERT ]; then
./install_LIBHILBERT.sh $HOME/openfpm_dependencies/openfpm_data/ 4 ./install_LIBHILBERT.sh $HOME/openfpm_dependencies/openfpm_data/ 4
fi fi
rm -rf $HOME/openfpm_dependencies/openfpm_data/BOOST
if [ ! -d $HOME/openfpm_dependencies/openfpm_data/BOOST ]; then if [ ! -d $HOME/openfpm_dependencies/openfpm_data/BOOST ]; then
if [ x"$2" == x"mac," ]; then if [ x"$2" == x"mac," ]; then
......
...@@ -120,6 +120,7 @@ with_eigen ...@@ -120,6 +120,7 @@ with_eigen
enable_gpu enable_gpu
' '
rm -rf build
if [ ! -d "build" ]; then if [ ! -d "build" ]; then
mkdir build mkdir build
fi fi
...@@ -214,6 +215,7 @@ do ...@@ -214,6 +215,7 @@ do
case $ac_useropt in case $ac_useropt in
debug) debug)
conf_options="$conf_options -DCMAKE_BUILD_TYPE=Debug" conf_options="$conf_options -DCMAKE_BUILD_TYPE=Debug"
debug_mode=1
;; ;;
se_class1) se_class1)
conf_options="$conf_options -DSE_CLASS1=ON" conf_options="$conf_options -DSE_CLASS1=ON"
...@@ -224,6 +226,9 @@ do ...@@ -224,6 +226,9 @@ do
se_class3) se_class3)
conf_options="$conf_options -DSE_CLASS3=ON" conf_options="$conf_options -DSE_CLASS3=ON"
;; ;;
gpu)
conf_options="$conf_options -DENABLE_GPU=ON"
;;
*) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
ac_unrecognized_sep=', ' ac_unrecognized_sep=', '
;; ;;
...@@ -326,7 +331,10 @@ do ...@@ -326,7 +331,10 @@ do
-prefix | --prefix | --prefi | --pref | --pre | --pr | --p) -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
ac_prev=prefix ;; ac_prev=prefix ;;
-prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
prefix=$ac_optarg ;; prefix=$ac_optarg
conf_options="$conf_options -DCMAKE_INSTALL_PREFIX=$ac_optarg"
echo "$prefix" > install_dir
;;
-program-prefix | --program-prefix | --program-prefi | --program-pref \ -program-prefix | --program-prefix | --program-prefi | --program-pref \
| --program-pre | --program-pr | --program-p) | --program-pre | --program-pr | --program-p)
...@@ -429,6 +437,27 @@ do ...@@ -429,6 +437,27 @@ do
libhilbert) libhilbert)
conf_options="$conf_options -DLIBHILBERT_ROOT=$ac_optarg" conf_options="$conf_options -DLIBHILBERT_ROOT=$ac_optarg"
;; ;;
metis)
conf_options="$conf_options -DMETIS_ROOT=$ac_optarg"
;;
parmetis)
conf_options="$conf_options -DPARMETIS_ROOT=$ac_optarg"
;;
hdf5)
conf_options="$conf_options -DHDF5_ROOT=$ac_optarg"
;;
petsc)
conf_options="$conf_options -DPETSC_ROOT=$ac_optarg"
;;
blas)
conf_options="$conf_options -DOPENBLAS_ROOT=$ac_optarg"
;;
suitesparse)
conf_options="$conf_options -DSUITESPARSE_ROOT=$ac_optarg"
;;
eigen)
conf_options="$conf_options -DEIGEN3_ROOT=$ac_optarg"
;;
boost) boost)
conf_options="$conf_options -DBOOST_ROOT=$ac_optarg" conf_options="$conf_options -DBOOST_ROOT=$ac_optarg"
;; ;;
...@@ -496,24 +525,44 @@ Try \`$0 --help' for more information" ...@@ -496,24 +525,44 @@ Try \`$0 --help' for more information"
esac esac
done done
if [ x"$debug_mode" != x"1" ]; then
conf_options="$conf_options -DCMAKE_BUILD_TYPE=Release"
fi
cd build cd build
## remove enerything ## remove enerything
echo "Calling cmake ../. $conf_options" echo "Calling cmake ../. $conf_options"
rm ../error_code
cmake ../. $conf_options cmake ../. $conf_options
if [ $? != 0 ]; then if [ $? != 0 ]; then
exit 1 #ok something went wrong the install script analyze the return code to potentially fix the problem automatically
# Read the error code and exit with that
if [ -f ../error_code ]; then
ecod=$(cat ../error_code)
if [ x"$ecod" == x"0" ]; then
exit 1
else
echo "Analyze error $ecod"
exit $ecod
fi
else
exit 1
fi
fi fi
cd .. cd ..
echo "SUBDIRS := build echo "all:
\$(MAKE) -C build \$@
clean:
\$(MAKE) -C build \$@
all: \$(SUBDIRS) install:
\$(SUBDIRS): \$(MAKE) -C build \$@
\$(MAKE) -C \$@
.PHONY: all \$(SUBDIRS)" > Makefile .PHONY: all clean install" > Makefile
echo "$0 $@" > config.log echo "$0 $@" > config.log
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment