Can anybody help me with compile NWCHEM?

From NWChem

Viewed 93 times, With a total of 9 Posts
Jump to: navigation, search

Clicked A Few Times
Threads 1
Posts 6
install openmpi

shell$ gunzip -c openmpi-1.10.0.tar.gz | tar xf -
shell$ cd openmpi-1.10.0
shell$ ./configure --prefix=/usr/local/openmpi
<...lots of output...>
shell$ make all install

export PATH="....:/usr/local/openmpi/bin"
export LD_LIBRARY_PATH="/usr/local/openmpi/lib"

export NWCHEM_TOP="/diskB/bulat/Downloads/Nwchem-6.5"
export NWCHEM_TARGET="LINUX64"
export NWCHEM_MODULES="all"

export USE_MPI="y"
export USE_MPIF="y"
export USE_MPIF4="y"
export MPI_LIB="/usr/local/openmpi/lib"
export MPI_LOC="/usr/local/openmpi/"
export MPI_INCLUDE="/usr/local/openmpi/include"
export LIBMPI="-lmpi_f90 -lmpi_f77 -lmpi_usempi -lmpi_mpifh -lmpi
-lopen-rte -lopen-pal-ldl -Wl,--export-dynamic -lm -lpthread -lrt -lnsl -lutil"

mpicc -show
gcc -I/usr/local/openmpi/include -pthread -Wl,-rpath -Wl,/usr/local/openmpi/lib
-Wl,--enable-new-dtags -L/usr/local/openmpi/lib -lmpi

mpif90 -show
gfortran -I/usr/local/openmpi/include -pthread -I/usr/local/openmpi/lib -Wl,-rpath -Wl,/usr/local/openmpi/lib
-Wl,--enable-new-dtags -L/usr/local/openmpi/lib -lmpi_usempi -lmpi_mpifh -lmpi

cd $NWCHEM_TOP/src
make nwchem_config

make -C config -f make_nwchem_config NWCHEM_MODULES="all"
echo \# This configuration generated automatically on \
     `hostname` at `date` > nwchem_config.h
echo \# This configuration generated automatically on \
    `hostname` at `date` > NWCHEM_CONFIG
echo "# Request modules from user: all" >> NWCHEM_CONFIG
echo "# Request modules from user: all" >> nwchem_config.h
echo The following subdirectories are built: >> NWCHEM_CONFIG
echo "NW_MODULE_SUBDIRS = NWints atomscf ddscf gradients moints nwdft nwxc rimp2 stepper driver optim cphf ccsd vib mcscf prepar esp hessian selci dplot mp2_grad qhop property solvation nwpw fft analyz nwmd cafe space drdy vscf qmmm qmd etrans tce bq cons perfm dntmc dangchang ccca" >> nwchem_config.h
echo NWints analyz atomscf bq cafe ccca ccsd cons cphf dangchang ddscf dntmc dplot drdy driver esp etrans fft gradients hessian mcscf moints mp2_grad nwdft nwmd nwpw nwxc optim perfm prepar property qhop qmd qmmm rimp2 selci solvation space stepper symmetry tce vib vscf >> NWCHEM_CONFIG
echo "NW_MODULE_LIBS = -lccsd -lmcscf -lselci -lmp2 -lmoints -lstepper -ldriver -loptim -lnwdft -lgradients -lcphf -lesp -lddscf -ldangchang -lguess -lhessian -lvib -lnwcutil -lrimp2 -lproperty -lsolvation -lnwints -lprepar -lnwmd -lnwpw -lofpw -lpaw -lpspw -lband -lnwpwlib -lnwxc -lcafe -lspace -lanalyze -lqhop -lpfft -ldplot -ldrdy -lvscf -lqmmm -lqmd -letrans -lpspw -ltce -lbq -lcons -lperfm -ldntmc -lccca" >> nwchem_config.h
echo corresponding to these libraries: >> NWCHEM_CONFIG
echo "EXCLUDED_SUBDIRS = develop scfaux rimp2_grad python argos diana uccsdt rism geninterface smd nbo leps lucia" >> nwchem_config.h
echo -lnwints -lanalyze -lguess -lbq -lcafe -lccca -lccsd -lcons -lcphf -ldangchang -lddscf -ldntmc -ldplot -ldrdy -ldriver -lesp -letrans -lpfft -lgradients -lhessian -lmcscf -lmoints -lmp2 -lnwdft -lnwxc -lnwmd -lnwpw -lofpw -lpaw -lpspw -lband -lnwpwlib -lnwxc -lnwxc -loptim -lperfm -lprepar -lproperty -lqhop -lqmd -lqmmm -lrimp2 -lselci -lsolvation -lspace -lstepper -lnwcutil -ltce -lvib -lvscf >> NWCHEM_CONFIG
echo "CONFIG_LIBS = " >> nwchem_config.h
echo >> NWCHEM_CONFIG
cp census.skeleton ../stubs.F
echo The following directories are excluded from the build: >> NWCHEM_CONFIG
echo develop scfaux rimp2_grad python argos diana uccsdt rism geninterface smd nbo leps lucia >> NWCHEM_CONFIG
echo and these routines will be replaced by stubs: >> NWCHEM_CONFIG
echo argos argos_input crossing debtest dia_input diana gasdev geninterface jantest jvltest jvltest2 kgdtest leps_energy leps_gradient lucia mc_data mc_driver mc_init mc_main md_data md_driver md_set moints_screen mymc_input mymd_input nbo_input python_input raktest rimp2g rism_input rjhtest smd_input task_fragment_energy task_nbo task_python task_rism task_smd task_smd_dynamics task_smd_energy task_smd_fragment uccsdt uccsdtest urand >> NWCHEM_CONFIG
echo "No extra configuration libraries were added " >> NWCHEM_CONFIG
for routine in argos argos_input crossing debtest dia_input diana gasdev geninterface jantest jvltest jvltest2 kgdtest leps_energy leps_gradient lucia mc_data mc_driver mc_init mc_main md_data md_driver md_set moints_screen mymc_input mymd_input nbo_input python_input raktest rimp2g rism_input rjhtest smd_input task_fragment_energy task_nbo task_python task_rism task_smd task_smd_dynamics task_smd_energy task_smd_fragment uccsdt uccsdtest urand; do \
  sed s/STUBROUTINE/$routine/g stub.skeleton >> ../stubs.F ; \
done

make FC=gfortran >& make.log

make.log:
test \! -f 64_to_32 -o \! -f 32_to_64 || rm -f 64_to_32 32_to_64
test -d /diskB/bulat/Downloads/Nwchem-6.5/lib/LINUX64 || mkdir -p /diskB/bulat/Downloads/Nwchem-6.5/lib/LINUX64
Making libraries in tools
test -d /diskB/bulat/Downloads/Nwchem-6.5/bin/LINUX64 || mkdir -p /diskB/bulat/Downloads/Nwchem-6.5/bin/LINUX64
./util/util_nwchem_version.bash
which: no svn in (/usr/local/phenix-1.9-1690/build/intel-linux-2.6-x86_64/bin:/diskB/bulat/bin:/usr/local/bin:/usr/bin:/sbin:/usr/sbin:/bin:/usr/games:/usr/X11R6/bin:/usr/bin/X11:/usr/local/openmpi/bin)
make[1]: warning: -jN forced in submake: disabling jobserver mode.

      • Building Parallel Tools ****

make all-recursive
Making all in comex
make[4]: *** No rule to make target `all'. Stop.
make[3]: *** [all-recursive] Error 1
make[2]: *** [all] Error 2
make[1]: *** [build/.libs/libga.a] Error 1
make: *** [libraries] Error 1

thakyou
Edited On 1:59:21 AM PDT - Mon, Sep 28th 2015 by Bulat

Clicked A Few Times
Threads 1
Posts 6
I missed
export CC=gcc
export FC=gfortran

Now I have make.log:

configure: Aggregate Remote Memory Copy Interface (ARMCI) configured as follows:
configure: **************************************************************
configure:
configure: TARGET=LINUX64
configure: MSG_COMMS=MPI
configure: GA_MP_LIBS= -lmpi_f90 -lmpi_f77 -lmpi_usempi -lmpi_mpifh -lmpi -lopen-rte -lopen-pal-ldl -lm -lpthread -lrt -lnsl -lutil
configure: GA_MP_LDFLAGS= -L/usr/local/openmpi/lib -Wl,--export-dynamic -L/usr/local/openmpi//lib
configure: GA_MP_CPPFLAGS= -I/usr/local/openmpi/include -I/usr/local/openmpi//include
configure: ARMCI_NETWORK=MPI_TS
configure: ARMCI_NETWORK_LDFLAGS= configure: ARMCI_NETWORK_LIBS= configure: ARMCI_NETWORK_CPPFLAGS= configure: CC=gcc
configure: CFLAGS= configure: ARMCI_COPT=-O3 -funroll-loops
configure: CPP=gcc -E
configure: CPPFLAGS= configure: LDFLAGS= configure: LIBS=-lm
configure: FLIBS= configure: AR=ar
configure: AR_FLAGS=cru
configure: CCAS=gcc
configure: CCAS_FLAGS= configure: DEFS=-DHAVE_CONFIG_H
configure: SHELL=/bin/sh
configure: MPIEXEC=/usr/local/bin/mpirun -n %NP%
configure: NPROCS=4
configure:
=== configuring in comex (/diskB/bulat/Downloads/Nwchem-6.5/src/tools/build/comex)
configure: running /bin/sh ../../ga-5-3/comex/configure --disable-option-checking '--prefix=/diskB/bulat/Downloads/Nwchem-6.5/src/tools/install' '--with-tcgmsg' '--with-mpi=-I/usr/local/openmpi/include -L/usr/local/openmpi/lib -lmpi_f90 -lmpi_f77 -lmpi_usempi -lmpi_mpifh -lmpi -lopen-rte -lopen-pal-ldl -Wl,--export-dynamic -lm -lpthread -lrt -lnsl -lutil /usr/local/openmpi/' '--enable-peigs' '--enable-underscoring' '--disable-mpi-tests' '--without-scalapack' '--without-lapack' '--without-blas' '--with-mpi-ts' 'CC=gcc' 'F77=gfortran' 'ARMCI_DEFAULT_SHMMAX_UBOUND=131072' --cache-file=/dev/null --srcdir=../../ga-5-3/comex
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether to enable maintainer-specific portions of Makefiles... no
configure: Detected VPATH build
configure:
configure: C compiler
configure:
checking for style of include used by make... GNU
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking whether it is safe to define __EXTENSIONS__... yes
checking whether a simple C MPI program compiles... yes
configure: searching for MPI_TS...
checking mpi.h usability... yes
checking mpi.h presence... yes
checking for mpi.h... yes
checking for library containing MPI_Init... no
configure: error: test for COMEX_NETWORK=MPI_TS failed
configure: error: ../../ga-5-3/comex/configure failed for comex
make[1]: *** [build/config.status] Error 1
make: *** [libraries] Error 1

Clicked A Few Times
Threads 1
Posts 6
add export ARMCI_NETWORK=MPI-TS
now make.log again:

test \! -f 64_to_32 -o \! -f 32_to_64 || rm -f 64_to_32 32_to_64
test -d /diskB/bulat/Downloads/Nwchem-6.5/lib/LINUX64 || mkdir -p /diskB/bulat/Downloads/Nwchem-6.5/lib/LINUX64
test -d /diskB/bulat/Downloads/Nwchem-6.5/bin/LINUX64 || mkdir -p /diskB/bulat/Downloads/Nwchem-6.5/bin/LINUX64
./util/util_nwchem_version.bash
which: no svn in (/usr/local/phenix-1.9-1690/build/intel-linux-2.6-x86_64/bin:/diskB/bulat/bin:/usr/local/bin:/usr/bin:/sbin:/usr/sbin:/bin:/usr/games:/usr/X11R6/bin:/usr/bin/X11:/usr/local/openmpi/bin)
make[1]: warning: -jN forced in submake: disabling jobserver mode.

      • Building Parallel Tools ****

make all-recursive
Making all in comex
make[4]: *** No rule to make target `all'. Stop.
make[3]: *** [all-recursive] Error 1
make[2]: *** [all] Error 2
make[1]: *** [build/.libs/libga.a] Error 1
make: *** [libraries] Error 1

Whats wrong?

Forum Vet
Threads 4
Posts 936
I just tried to use Openmpi 1.10.0 and I got an mpipf90 -show output different from yours (and I have eventually manage to build nwchem).
What is the output you get for
mpif90 -showme:version


This is what I am getting
$ mpif90 -showme:version
mpif90: Open MPI 1.10.0 (Language: Fortran)
$ mpif90 -show
ifort -I/home/edo/apps/ompi1100.ifort/include -I/home/edo/apps/ompi1100.ifort/lib -Wl,-rpath -Wl,/home/edo/apps/ompi1100.ifort/lib -Wl,--enable-new-dtags -L/home/edo/apps/ompi1100.ifort/lib -lmpi_usempif08 -lmpi_usempi_ignore_tkr -lmpi_mpifh -lmpi

This is what I used to build NWChem. Please notice the LIBMPI value, that seems very different from yours
MPI_INCLUDE=/home/edo/apps/ompi1100.ifort/include
MPI_LIB=/home/edo/apps/ompi1100.ifort/lib
LIBMPI="-lmpi_usempif08 -lmpi_usempi_ignore_tkr -lmpi_mpifh -lmpi"
Edited On 9:51:12 AM PDT - Tue, Sep 29th 2015 by Edoapra

Clicked A Few Times
Threads 1
Posts 6
version is the same: mpif90: Open MPI 1.10.0 (Language: Fortran )

I took your offer LIBMPI, but log is not changed.

Forum Vet
Threads 4
Posts 936
Please send me the output of the following commands

1)
cd $NWCHEM_TOP/src
make FC=gfortran LIBMPI="-lmpi_usempi -lmpi_mpifh -lmpi" MPI_LIB=/usr/local/openmpi/lib link

2)
mpif90 -showme

3)
mpicc -showme

4)
which mpif90

Clicked A Few Times
Threads 1
Posts 6
1)
make nwchem.o stubs.o
make[1]: warning: -jN forced in submake: disabling jobserver mode.
gfortran -m64 -ffast-math -Wuninitialized -fdefault-integer-8 -g -g -O -I. -I/diskB/bulat/Downloads/Nwchem-6.5/src/include -I/diskB/bulat/Downloads/Nwchem-6.5/src/tools/install/include -DGFORTRAN -DCHKUNDFLW -DGCC4 -DGCC46 -DEXT_INT -DLINUX -DLINUX64 -DPARALLEL_DIAG -DCOMPILATION_DATE="'`date +%a_%b_%d_%H:%M:%S_%Y`'" -DCOMPILATION_DIR="'/diskB/bulat/Downloads/Nwchem-6.5'" -DNWCHEM_BRANCH="'6.5'" -c -o nwchem.o nwchem.F
gfortran -m64 -ffast-math -Wuninitialized -fdefault-integer-8 -g -g -O -I. -I/diskB/bulat/Downloads/Nwchem-6.5/src/include -I/diskB/bulat/Downloads/Nwchem-6.5/src/tools/install/include -DGFORTRAN -DCHKUNDFLW -DGCC4 -DGCC46 -DEXT_INT -DLINUX -DLINUX64 -DPARALLEL_DIAG -DCOMPILATION_DATE="'`date +%a_%b_%d_%H:%M:%S_%Y`'" -DCOMPILATION_DIR="'/diskB/bulat/Downloads/Nwchem-6.5'" -DNWCHEM_BRANCH="'6.5'" -c -o stubs.o stubs.F
nwchem.F:3:0: fatal error: errquit.fh: No such file or directory
compilation terminated.
stubs.F:15:0: fatal error: errquit.fh: No such file or directory
compilation terminated.
make[1]: *** [nwchem.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: *** [stubs.o] Error 1
make: *** [link] Error 2

2)
gfortran -I/usr/local/openmpi/include -pthread -I/usr/local/openmpi/lib -Wl,-rpath -Wl,/usr/local/openmpi/lib -Wl,--enable-new-dtags -L/usr/local/openmpi/lib -lmpi_usempi -lmpi_mpifh -lmpi

3)
gcc -I/usr/local/openmpi/include -pthread -Wl,-rpath -Wl,/usr/local/openmpi/lib -Wl,--enable-new-dtags -L/usr/local/openmpi/lib -lmpi

4)
/usr/local/bin/mpif90

Forum Vet
Threads 4
Posts 936
Could you please try the 6.6 beta version since the MPI part of the installation has been simplified?
http://www.nwchem-sw.org/index.php/Compiling_NWChem#How-to:_Linux_platforms

Download instructions at
http://www.nwchem-sw.org/index.php/Download#Download_the_beta_version_of_the_NWChem_6.6_Re...

Clicked A Few Times
Threads 1
Posts 6
Compiling successfull without any problems and errors! Thanks
One question: I ll must compiling realise version in future or I may use beta for work?
Edited On 8:32:59 AM PDT - Thu, Oct 1st 2015 by Bulat

Forum Vet
Threads 4
Posts 936
Quote:Bulat Oct 1st 7:26 am
Compiling successfull without any problems and errors! Thanks
One question: I ll must compiling realise version in future or I may use beta for work?


I would suggest you to check some of the results your obtain from the beta version with run from the release (it will be out soon,m anyway)

Another good (= suggested) practice is to run the QA tests as explained in the file $NWCHEM_TOP/QA/HOW-TO-RUN-TESTS


Forum >> NWChem's corner >> Compiling NWChem



Who's here now Members 0 Guests 1 Bots/Crawler 0


AWC's: 2.5.10 MediaWiki - Stand Alone Forum Extension
Forum theme style by: AWC