Skip to content

Conversation

@drroe
Copy link
Contributor

@drroe drroe commented Mar 4, 2021

Inspired by some recent incidents where users had a difficult time building a fully-functional CPPTRAJ due to missing external dependencies like NetCDF. This PR makes it so configure will ask the user if they want to download and build any libraries that are enabled but missing. By default the configure script will ask users before doing this. If --buildlibs is specified, the configure script will try to do this without being asked. If --nobuildlibs is specified, the script will not attempt to do this. The new behavior looks like this:

$ ./configure -fftw3 --buildlibs
  fftw3 enabled.
No compilers specified; defaulting to gnu

  Testing C++ compiler: OK
  Testing C compiler: OK
  Testing Fortran compiler: OK
  Testing basic C++11 support: OK
  Testing system headers for C++11 support: OK
Warning: Compilation of sanderlib requires AMBERHOME to be set
Warning:   if --with-sanderlib not specified.
Enabled libraries will be built if not present.
  Checking BZLIB: OK
  Checking ZLIB: OK
  Checking NetCDF:   Checking for bundled NetCDF:     Configuring netcdf... Success.
    MAKE_COMMAND is not set; set to 'make -j12'
    Compiling netcdf (may be time-consuming)... Success.
  Checking built NetCDF: OK
  Checking LAPACK/BLAS:   Checking for bundled LAPACK/BLAS:     Configuring lapack... (using generated make.inc) Success.
    MAKE_COMMAND is not set; set to 'make -j12'
    Compiling lapack (may be time-consuming)... Success.
  Checking built LAPACK/BLAS: OK
  Checking FFTW3:   Checking for bundled FFTW:     Configuring fftw... Success.
    MAKE_COMMAND is not set; set to 'make -j12'
    Compiling fftw (may be time-consuming)... Success.
  Checking built FFTW: OK

Configuration summary:
  Build type: Serial
  Options: netcdf bzlib tng zlib arpack lapack blas fftw3 readline xdrfile
  Target platform: Linux, 64-bit.
  gnu compilers in use.
  C++11 support enabled.
  PME support enabled.
  Compiler optimizations are on.

Cleaning source directory.

--------------------------------------------------------------------------------
An environment resource file for CPPTRAJ has been created:
  /u/droe/Local_work/Cpptraj/work1.cpptraj/cpptraj.sh
You may 'source' this file to set up your environment for CPPTRAJ.
--------------------------------------------------------------------------------

CPPTRAJ configuration complete.
  • This PR also makes sure that files in the dat directory are properly installed for a --prefix install.
  • Also fix a compile error with some Intel compilers: 'error: identifier "_LIB_VERSION_TYPE" is undefined'
  • Also fixes test behavior when CPPTRAJHOME is not where tests are located.

drroe and others added 30 commits February 28, 2021 12:53
…Flink return with a status instead of exit on error.
…t FFLAGS since they might not be appropriate for F77 style code
@drroe drroe added the configure label Mar 4, 2021
@drroe drroe self-assigned this Mar 4, 2021
@AmberJenkins
Copy link
Collaborator

The PGI build in Jenkins failed.

Daniel R. Roe and others added 2 commits March 4, 2021 12:49
…is not interactive. Will also serve as a partial test of --buildlibs.
@drroe drroe merged commit 3edbe2e into Amber-MD:master Mar 4, 2021
@drroe drroe deleted the netcdf-script branch March 4, 2021 19:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants