Commit 9f7c1a9b authored by Giovanni La Mura's avatar Giovanni La Mura
Browse files

Re-introduce definition of with-fflags configuration option

parent 39527eeb
Loading
Loading
Loading
Loading
+14 −7
Original line number Diff line number Diff line
@@ -10,6 +10,7 @@ DEBUGFLAGS=""
ENABLE_ILP64="yes"
FC_OPT=3
FC_DBG=" -ggdb"
FFLAGS=""
LAPACK="auto"
LIBMODE="static"
MAGMA="auto"
@@ -83,11 +84,13 @@ function print_help {
    echo "--enable-shared           Use shared libraries (default is static).       "
    echo "--help                    Print this help and exit.                       "
    echo "--with-cublas             Use cuBLAS (DEFAULT).                           "
    echo "--without-cublas          Disable cuBLAS.                                 "
    echo "--with-fflags=FFLAGS      Use specified FORTRAN compiler flags instead of "
    echo "                          detected ones.                                  "
    echo "--with-hdf5=HDF5_PATH     Use specified HDF5 distribution.                "
    echo "--with-lapack             Use LAPACK (DEFAULT).                           "
    echo "--with-magma=[MAGMA]      Use specified MAGMA distribution (DEFAULT).     "
    echo "--without-cublas          Disable cuBLAS.                                 "
    echo "--without-lapack          Disable LAPACK.                                 "
    echo "--with-magma=[MAGMA]      Use specified MAGMA distribution (DEFAULT).     "
    echo "--without-magma           Disable MAGMA.                                  "
    echo "                                                                          "
    echo "Some influential environment variables are:                               "
@@ -178,6 +181,11 @@ do
	CUBLAS="yes"
    elif [ "x$cut_arg" = "x--without-cublas" ]; then
	CUBLAS="no"
    elif [ "x$cut_arg" = "x--with-fflags" ]; then
	custom_flags=$(echo $arg | cut -d '=' -f2)
	if [ "x$custom_flags" != "x" ]; then
	    FFLAGS=$custom_flags
	fi
    elif [ "x$cut_arg" = "x--with-hdf5" ]; then
	HDF5_HOME=$(echo $arg | cut -d '=' -f2)
	if [ "x${HDF5_HOME}" = "x" ]; then
@@ -186,11 +194,6 @@ do
	fi
    elif [ "x$cut_arg" = "x--with-lapack" ]; then
	LAPACK="yes"
	#LAPACKHOME=$(echo $arg | cut -d '=' -f2)
	#if [ "x$LAPACKHOME" != "x" ]; then
	#    LAPACK_INCLUDE="$LAPACKHOME/include"
	#    LAPACK_LIB="$LAPACKHOME/lib"
	#fi
    elif [ "x$cut_arg" = "x--without-lapack" ]; then
	LAPACK="no"
    elif [ "x$cut_arg" = "x--with-magma" ]; then
@@ -764,6 +767,10 @@ if [ "x$CXXLDFLAGS" = "x" ]; then
	CXXLDFLAGS="-Llibnptm -lnptm ${HDF5LDFLAGS} ${LAPACKLDFLAGS}${CUBLASLDFLAGS}${MAGMALDFLAGS}"
    fi
fi

if [ "x$FFLAGS" != "x" ]; then
    FCFLAGS=$FFLAGS
fi
# End of configuration logic

# Print a summary of configuration options