Merge branch 'confifox' into 'develop'

[skip-CI] Added option --with-fox to configure

See merge request QEF/q-e!1901
This commit is contained in:
giannozz 2022-07-03 07:36:03 +00:00
commit ebfa3d8978
7 changed files with 89 additions and 29 deletions

View File

@ -378,7 +378,7 @@ common to all packages:
\texttt{KS\_Solvers/}& Iterative diagonalization routines\\
\texttt{UtilXlib/} & Miscellaneous timing, error handling, MPI utilites\\
\texttt{XClib/} & Exchange-correlation functionals (excepted van der Waals)\\
\texttt{MBD/} & Routines for many-body dispersions
\texttt{MBD/} & Routines for many-body dispersions\\
\texttt{LR\_Modules/}& Fortran modules and utilities used by linear-response codes\\
\texttt{install/} & installation scripts and utilities\\
\texttt{pseudo}/ & pseudopotential files used by examples\\
@ -400,7 +400,7 @@ while others are specific to a single package:
\texttt{CPV/} & \CP\ package\\
\texttt{atomic/} & \texttt{atomic} package\\
\texttt{GUI/} & \texttt{PWGui} package\\
\texttt{HP/} & \texttt{HP} package
\texttt{HP/} & \texttt{HP} package\\
\texttt{QEHeat/} & \texttt{QEHeat} package\\
\texttt{KCW/} & \texttt{KCW} package
\end{tabular}
@ -503,10 +503,11 @@ in any \texttt{Makefile}, type \texttt{make depend}, or run
It is convenient to use "parallel make" to speed up compilation:
\texttt{make -jN} compiles in parallel on N processors. Note that
if you interrupt \make, depending upon what it was doing
you may run into trouble the next time you type \make (for instance,
if \make\ is interrupted while unpacking and compiling the FoX library).
If so, run \texttt{make clean} before running \make\ again.
if you interrupt \make, you may run into trouble the next time you
type \make (for instance, if \make\ is interrupted while unpacking
and compiling an external library).
If so, run \texttt{make clean}, or even \texttt{make distclean},
before running \make\ again.
You should always be able to compile the \qe\ suite
of programs without having to edit any of the generated files. However you
@ -529,7 +530,7 @@ Some environment variables that are relevant to \configure\ are:
\begin{tabular}{ll}
\texttt{ARCH}& label identifying the machine type (see below)\\
\texttt{F90, F77, CC} &names of Fortran, Fortran-77, and C compilers\\
\texttt{F90, CC} &names of Fortran and C compilers\\
\texttt{MPIF90} & name of parallel Fortran 90 compiler (using MPI)\\
\texttt{CPP} & source file preprocessor (defaults to \$CC -E)\\
\texttt{LD} & linker (defaults to \$MPIF90)\\
@ -557,8 +558,8 @@ compilation.
If your machine type is unknown to \configure, you may use the
\texttt{ARCH}
variable to suggest an architecture among supported ones. Some large
parallel machines using a front-end (e.g. Cray XT) will actually
variable to suggest an architecture among supported ones. Some
parallel machines using a front-end may actually
need it, or else \configure\ will correctly recognize the front-end
but not the specialized compilation environment of those machines.
In some cases, cross-compilation requires to specify the target machine
@ -605,6 +606,7 @@ is between bracket:\\
\\
and the following optional packages:\\
\begin{tabular}{ll}
\texttt{--with-fox} & Use official FoX library instead of built-in replacement (default:yes)\\
\texttt{--with-scalapack}& (yes$|$no$|$intel) Use scalapack if available. \\
&Set to \texttt{intel} to use Intel MPI and BLACS (default: use OpenMPI)\\
\texttt{--with-elpa-include}& Specify full path of ELPA include and modules

View File

@ -190,7 +190,7 @@ pw4gwwlib : phlibs
if test -d GWW ; then \
( cd GWW ; $(MAKE) pw4gwwa || exit 1 ) ; fi
mods : libfox libutil libla libfft libupf libmbd librxc
mods : $(FOX) libutil libla libfft libupf libmbd librxc
( cd Modules ; $(MAKE) TLDEPS= all || exit 1 )
libks_solvers : libutil libla

View File

@ -227,11 +227,6 @@ TLDEPS= libfox libla libfft libutil libmbd librxc libupf
all : libqemod.a
## The following is needed only for lapack compiled from sources
dlamch.o : dlamch.f
$(F77) $(FFLAGS_NOOPT) -c $<
libqemod.a: $(MODULES) $(OBJS) $(RISMLIB)
$(AR) $(ARFLAGS) $@ $?
$(RANLIB) $@

1
install/aclocal.m4 vendored
View File

@ -26,6 +26,7 @@ m4_include([m4/x_ac_qe_environ.m4])
m4_include([m4/x_ac_qe_f90.m4])
m4_include([m4/x_ac_qe_f90rule.m4])
m4_include([m4/x_ac_qe_fft.m4])
m4_include([m4/x_ac_qe_fox.m4])
m4_include([m4/x_ac_qe_hdf5.m4])
m4_include([m4/x_ac_qe_lapack.m4])
m4_include([m4/x_ac_qe_ld.m4])

75
install/configure vendored
View File

@ -664,6 +664,8 @@ mpi_line
mpi_libs
mass_line
mass_libs
foxlibs
extfox
libxc_line
LIBS_LIBXC
fft_line
@ -737,6 +739,7 @@ infodir
docdir
oldincludedir
includedir
runstatedir
localstatedir
sharedstatedir
sysconfdir
@ -773,8 +776,8 @@ enable_openacc
with_libxc
with_libxc_prefix
with_libxc_include
with_fox
with_scalapack
with_scalapack_qrcp
with_elpa_include
with_elpa_lib
with_elpa_version
@ -835,6 +838,7 @@ datadir='${datarootdir}'
sysconfdir='${prefix}/etc'
sharedstatedir='${prefix}/com'
localstatedir='${prefix}/var'
runstatedir='${localstatedir}/run'
includedir='${prefix}/include'
oldincludedir='/usr/include'
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
@ -1087,6 +1091,15 @@ do
| -silent | --silent | --silen | --sile | --sil)
silent=yes ;;
-runstatedir | --runstatedir | --runstatedi | --runstated \
| --runstate | --runstat | --runsta | --runst | --runs \
| --run | --ru | --r)
ac_prev=runstatedir ;;
-runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
| --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
| --run=* | --ru=* | --r=*)
runstatedir=$ac_optarg ;;
-sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
ac_prev=sbindir ;;
-sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
@ -1224,7 +1237,7 @@ fi
for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
datadir sysconfdir sharedstatedir localstatedir includedir \
oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
libdir localedir mandir
libdir localedir mandir runstatedir
do
eval ac_val=\$$ac_var
# Remove trailing slashes.
@ -1377,6 +1390,7 @@ Fine tuning of the installation directories:
--sysconfdir=DIR read-only single-machine data [PREFIX/etc]
--sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
--localstatedir=DIR modifiable single-machine data [PREFIX/var]
--runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
--libdir=DIR object code libraries [EPREFIX/lib]
--includedir=DIR C header files [PREFIX/include]
--oldincludedir=DIR C header files for non-gcc [/usr/include]
@ -1435,6 +1449,7 @@ Optional Packages:
--with-libxc-include=DIR
Directory where libxc Fortran headers were
installed.
--with-fox use FoX library (default: yes)
--with-scalapack (yes|no|intel) Use scalapack if available. Set to
"intel" to use Intel MPI and blacs (default: use
openMPI)
@ -2352,7 +2367,7 @@ $as_echo "${arch}" >&6; }
try_dflags=""
# Add needed include directories
try_iflags="-I. -I\$(TOPDIR)/include -I\$(TOPDIR)/FoX/finclude "
try_iflags="-I. -I\$(TOPDIR)/include"
# Checking archiver...
@ -6316,6 +6331,40 @@ ac_compiler_gnu=$ac_cv_f77_compiler_gnu
fi
# Setting FoX...
# Check whether --with-fox was given.
if test "${with_fox+set}" = set; then :
withval=$with_fox; if test "$withval" = "no" ; then
with_fox=0
else
with_fox=1
fi
else
with_fox=1
fi
# Use internal code for xml read/write
if test "$with_fox" -eq 0 ; then
try_dflags="$try_dflags -D__outfoxed"
extfox=""
foxlibs=""
else
extfox="libfox"
foxlibs="-L\$(TOPDIR)/FoX/lib -lFoX_dom -lFoX_sax -lFoX_wxml \
-lFoX_common -lFoX_utils -lFoX_fsys "
try_iflags="$try_iflags -I\$(TOPDIR)/FoX/finclude "
fi
# Checking for IBM MASS library...
@ -7016,16 +7065,24 @@ fi
done
# Enable QRCP with scalapack if --with-scalapack-qrcp==yes is set.
# Requires Scalapack >= 2.1.0 or MKL >= 2020, but the version is not checked.
# If an old version is used, QRCP results might be buggy.
if test "${with_scalapack_qrcp+set}" = set; then :
withval=$with_scalapack_qrcp
if test "$withval" = "yes" && test "$have_scalapack" -eq 1; then
try_dflags="$try_dflags -D__SCALAPACK_QRCP"
# Check whether --with-scalapack was given.
if test "${with_scalapack+set}" = set; then :
withval=$with_scalapack; if test "$withval" = "yes" ; then
with_scalapack_qrcp=1
else
with_scalapack_qrcp=0
fi
else
with_scalapack_qrcp=0
fi
if test "$have_scalapack" -eq 1 && test "$with_scalapack_qrcp" -eq 1; then
try_dflags="$try_dflags -D__SCALAPACK_QRCP"
fi
# Configuring output message
if test "$have_scalapack" -eq 1; then
scalapack_line="SCALAPACK_LIBS=$scalapack_libs"

View File

@ -27,7 +27,7 @@ X_AC_QE_ARCH()
try_dflags=""
# Add needed include directories
try_iflags="-I. -I\$(TOPDIR)/include -I\$(TOPDIR)/FoX/finclude "
try_iflags="-I. -I\$(TOPDIR)/include"
# Checking archiver...
X_AC_QE_AR()
@ -73,6 +73,9 @@ X_AC_QE_FFT()
# Setting libxc...
ACX_LIBXC()
# Setting FoX...
X_AC_QE_FOX()
# Checking for IBM MASS library...
X_AC_QE_MASS()

View File

@ -157,8 +157,10 @@ FFT_LIBS = @fft_libs@
# HDF5
HDF5_LIBS = @hdf5_libs@
FOX_LIB = -L$(TOPDIR)/FoX/lib -lFoX_dom -lFoX_sax -lFoX_wxml -lFoX_common\
-lFoX_utils -lFoX_fsys
# FOX
FOX = @extfox@
FOX_LIB = @foxlibs@
FOX_FLAGS = @foxflags@
# ENVIRON