1

TOUGH3 installation issue

I realized many people have difficulty in compilation of TOUGH3. After polishing the installation cmake scripts and reorganizing the installation package, compilation of TOUGH3 should be more easy, stable and fast. Attached are the introduction, updated cmake scripts, additional required files.

33 replies

null
    • kenny
    • 1 yr ago
    • Reported - view

    I noticed the original cmake script for compilation of AZTEC does not work properly in newer version of CMAKE. If this happen to you, please replace the original two filles with the attached ones, which are located at:  /esd-toughlib/tpls/template

    • SK_Kim
    • 1 yr ago
    • Reported - view

    Is there a way to compile TOUGH3 with the latest version of PETSC? Because older versions of PETSC require python2, whereas python2 is now depreciated.

    • kenny
    • 1 yr ago
    • Reported - view

    The TOUGH3 V1.1 allows using the latest version of PETSC

      • SK_Kim
      • 1 yr ago
      • Reported - view

      kenny Can I get version 1.1 if I already have version 1.0? Who can I contact?

      • kenny
      • 1 yr ago
      • Reported - view

      SK Kim  Please send us an email for the requesting. 

    • Yessica_Peralta
    • 1 yr ago
    • Reported - view

    The zip file t3_installation_additionalFiles is missing the Zip file of petsc-3.7.1.tar.gz

    • kenny
    • 1 yr ago
    • Reported - view

    I just checked. It was there.

      • Yessica_Peralta
      • 1 yr ago
      • Reported - view

      @kenny. I found it, Thanks

    • Yessica_Peralta
    • 1 yr ago
    • Reported - view

    I am trying to compile Tough3 in Cygwin (Windows) and I am getting the following error: Failed to configure TOUGH TPLS. I attached the CMakeError log for your reference. Could you please help me with it?. Thank you in advance. 

    • kenny
    • 1 yr ago
    • Reported - view

    Hi, I took a look of the log file. It seems something wrong with MPI installation. Have you installed the MPI (MPICH or OPENMPI)? I would suggest use WSL (Windows Linux Subsystem)  to replace the Cygwin for TOUGH codes compilation and execution. WSL is more robust compared to Cygwin for running TOUGH. 

    Kenny

    • Yessica_Peralta
    • 1 yr ago
    • Reported - view

    Hi, thank you for your reply. I have not installed MPI. I will take your advise about using WSL. 

    • Yessica_Peralta
    • 11 mths ago
    • Reported - view

    Hi,

    I am trying to compile cmake in ubuntu windows I get the following error: gmake[2]: Leaving directory '/home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2'                                                                                                                                                                                                                                                                           [ 84%] Built target CMakeLib                                                                                                                                                                                                                                                                                                                              gmake[2]: Entering directory '/home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2'                                                                                                                                                                                                                                                                          Scanning dependencies of target CMakeServerLib                                                                                                                                                                                                                                                                                                            gmake[2]: Leaving directory '/home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2'                                                                                                                                                                                                                                                                           gmake[2]: Entering directory '/home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2'                                                                                                                                                                                                                                                                          [ 85%] Building CXX object Source/CMakeFiles/CMakeServerLib.dir/cmFileMonitor.cxx.o                                                                                                                                                                                                                                                                       [ 85%] Building CXX object Source/CMakeFiles/CMakeServerLib.dir/cmServer.cxx.o                                                                                                                                                                                                                                                                            [ 85%] Building CXX object Source/CMakeFiles/CMakeServerLib.dir/cmServerConnection.cxx.o                                                                                                                                                                                                                                                                  [ 85%] Building CXX object Source/CMakeFiles/CMakeServerLib.dir/cmServerProtocol.cxx.o                                                                                                                                                                                                                                                                    /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmServerProtocol.cxx: In member function ‘std::size_t std::hash<LanguageData>::operator()(const LanguageData&) const’:                                                                                                                                                                           /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmServerProtocol.cxx:620:43: error: ‘numeric_limits’ is not a member of ‘std’                                                                                                                                                                                                                      620 |                          (i.second ? std::numeric_limits<size_t>::max() : 0));                                                                                                                                                                                                                                                                          |                                           ^~~~~~~~~~~~~~                                                                                                                                                                                                                                                                                          /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmServerProtocol.cxx:620:64: error: expected primary-expression before ‘>’ token                                                                                                                                                                                                                   620 |                          (i.second ? std::numeric_limits<size_t>::max() : 0));                                                                                                                                                                                                                                                                          |                                                                ^                                                                                                                                                                                                                                                                                  /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmServerProtocol.cxx:620:67: error: ‘::max’ has not been declared; did you mean ‘std::max’?                                                                                                                                                                                                        620 |                          (i.second ? std::numeric_limits<size_t>::max() : 0));                                                                                                                                                                                                                                                                          |                                                                   ^~~                                                                                                                                                                                                                                                                                   |                                                                   std::max                                                                                                                                                                                                                                                                        In file included from /usr/include/c++/11/algorithm:62,                                                                                                                                                                                                                                                                                                                    from /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmLinkItem.h:8,                                                                                                                                                                                                                                                                             from /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmGeneratorTarget.h:8,                                                                                                                                                                                                                                                                      from /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmServerProtocol.cxx:7:                                                                                                                                                                                                                                                    /usr/include/c++/11/bits/stl_algo.h:3467:5: note: ‘std::max’ declared here                                                                                                                                                                                                                                                                                 3467 |     max(initializer_list<_Tp> __l, _Compare __comp)                                                                                                                                                                                                                                                                                                     |     ^~~                                                                                                                                                                                                                                                                                                                                           /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmServerProtocol.cxx:626:39: error: ‘numeric_limits’ is not a member of ‘std’                                                                                                                                                                                                                      626 |       result ^ (in.IsGenerated ? std::numeric_limits<size_t>::max() : 0);                                                                                                                                                                                                                                                                               |                                       ^~~~~~~~~~~~~~                                                                                                                                                                                                                                                                                              /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmServerProtocol.cxx:626:60: error: expected primary-expression before ‘>’ token                                                                                                                                                                                                                   626 |       result ^ (in.IsGenerated ? std::numeric_limits<size_t>::max() : 0);                                                                                                                                                                                                                                                                               |                                                            ^                                                                                                                                                                                                                                                                                      /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmServerProtocol.cxx:626:63: error: ‘::max’ has not been declared; did you mean ‘std::max’?                                                                                                                                                                                                        626 |       result ^ (in.IsGenerated ? std::numeric_limits<size_t>::max() : 0);                                                                                                                                                                                                                                                                               |                                                               ^~~                                                                                                                                                                                                                                                                                       |                                                               std::max                                                                                                                                                                                                                                                                            In file included from /usr/include/c++/11/algorithm:62,                                                                                                                                                                                                                                                                                                                    from /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmLinkItem.h:8,                                                                                                                                                                                                                                                                             from /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmGeneratorTarget.h:8,                                                                                                                                                                                                                                                                      from /home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2/Source/cmServerProtocol.cxx:7:                                                                                                                                                                                                                                                    /usr/include/c++/11/bits/stl_algo.h:3467:5: note: ‘std::max’ declared here                                                                                                                                                                                                                                                                                 3467 |     max(initializer_list<_Tp> __l, _Compare __comp)                                                                                                                                                                                                                                                                                                     |     ^~~                                                                                                                                                                                                                                                                                                                                           gmake[2]: *** [Source/CMakeFiles/CMakeServerLib.dir/build.make:135: Source/CMakeFiles/CMakeServerLib.dir/cmServerProtocol.cxx.o] Error 1                                                                                                                                                                                                                  gmake[2]: Leaving directory '/home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2'                                                                                                                                                                                                                                                                           gmake[1]: *** [CMakeFiles/Makefile2:2113: Source/CMakeFiles/CMakeServerLib.dir/all] Error 2                                                                                                                                                                                                                                                               gmake[1]: Leaving directory '/home/yplinux/cmake-3.8.2/cmake-3.8.2/cmake-3.8.2'                                                                                                                                                                                                                                                                           gmake: *** [Makefile:163: all] Error 2                                                                  

    Could you please help me with it? Thank you in advance.

    Yessica

    • Hamed_Nasiri
    • 6 mths ago
    • Reported - view

     Hi Kenny

    I have the same issue when I want to compile TOUGH3 for the TMVOC module.

    I followed excatly what you said but still I get the same error: Failed to build TOUGH TPLS
     

    Scanning dependencies of target toughlib_parallel
    make[2]: Leaving directory `/home/hnasir2/Hamed/esd-tough3/build/tpl-build'
    make -f src/mpi_interface/CMakeFiles/toughlib_parallel.dir/build.make src/mpi_interface/CMakeFiles/toughlib_parallel.dir/build
    make[2]: Entering directory `/home/hnasir2/Hamed/esd-tough3/build/tpl-build'
    [ 65%] Building Fortran object src/mpi_interface/CMakeFiles/toughlib_parallel.dir/parallel.f90.o
    cd /home/hnasir2/Hamed/esd-tough3/build/tpl-build/src/mpi_interface && /usr/local/packages/gcc/9.3.0/5jmpgadg/bin/gfortran -DUSE_MPI -DUSE_PETSC -I/home/hnasir2/Hamed/esd-toughlib/src -I/home/hnasir2/Hamed/esd-tough3/tough3-install/tpls/include -I/home/hnasir2/Hamed/esd-tough3/tough3-install/tpls/conf  -cpp -ffree-form -ffree-line-length-none -O3 -DNDEBUG -O3   -c /home/hnasir2/Hamed/esd-toughlib/src/mpi_interface/parallel.f90 -o CMakeFiles/toughlib_parallel.dir/parallel.f90.o
    f951: Warning: Nonexistent include directory '/home/hnasir2/Hamed/esd-tough3/tough3-install/tpls/conf' [-Wmissing-include-dirs]
    /home/hnasir2/Hamed/esd-toughlib/src/mpi_interface/parallel.f90:24:2:

       24 | #else
          |  1~~~
    Fatal Error: petsc/finclude/petscsys.h: No such file or directory
    compilation terminated.
    make[2]: *** [src/mpi_interface/CMakeFiles/toughlib_parallel.dir/parallel.f90.o] Error 1
    make[2]: Leaving directory `/home/hnasir2/Hamed/esd-tough3/build/tpl-build'
    make[1]: *** [src/mpi_interface/CMakeFiles/toughlib_parallel.dir/all] Error 2
    make[1]: Leaving directory `/home/hnasir2/Hamed/esd-tough3/build/tpl-build'
    make: *** [all] Error 2

    Script ERROR: Failed to build TOUGH TPLS

    I also noticed that you mentioned the issue when compiling fortran codes and then I replaced the two cmake files in esd-tough3 and esd-toughlib/src/ with the codes you provided but the issue persist. what should I do?
    I am trying to compile this on hpc

    • kenny
    • 6 mths ago
    • Reported - view

    Please try TOUGH3 V1.1. If you have a license for TOUGH3, you get get it free from LBNL marketplace.

    • Yogendra_Narayanan_Sures
    • 1 mth ago
    • Reported - view

    Hi, I was trying to install tough3 ECO2N during which I encountered the error as shown in the image. What is the way to rectify it? I have also replaced and copied the additional files. Kindly help me in this regard.

      • kenny
      • 1 mth ago
      • Reported - view

       

      Please update your TOUGH3 to V1.1

      • Yogendra_Narayanan_Sures
      • 1 mth ago
      • Reported - view

       Thanks for your reply....I was able to successfully build and configure TOUGH TPLS. However, I am stuck at another error that can be found in the attachment. I have also attached the Cmake files for your reference. Kindly help me in this regard.

      • Yogendra_Narayanan_Sures
      • 1 mth ago
      • Reported - view

       Hi, can you please let me know the procedure for the upgradation to V1.1 and the e-mail id to whom we should write?

      • Yogendra_Narayanan_Sures
      • 3 wk ago
      • Reported - view

       I updated my TOUGH3 to V1.1. But I am facing the error shown in the attached image. Your help in this regards would be much appreciated. Thank you in advance.

      • kenny
      • 3 wk ago
      • Reported - view

       This is caused by the Verison of Gfortran. If you are using Gfortran Ver 10.0 or late version, you will see this problem. It can be solved by adding Fortran compiler option   "-fallow-argument-mismatch" to the following cmake script:

      1. esd-tough3/CMakeLists.txt (which is the code snippet you showed me), and
      2. esd-toughlib/src/CMakeLists.txt.

      see discussions in: https://tough.forumbee.com/t/x2h7t90#m1y8wf0

      • Yogendra_Narayanan_Sures
      • 3 wk ago
      • Reported - view

       I have made the changes in the above mentioned CMakelists. I have attached the CMakeLists file. Please let me know where have I gone wrong. Thank you in advance.

      • Yogendra_Narayanan_Sures
      • 2 wk ago
      • Reported - view

       Please ignore the earlier reply. I have made the changes in the above-mentioned cmakelists at esd-tough3 and esd-toughlib/src. But the error is still persisting. Could you please help me in this regard? I have attached the cmakelists file for your reference. Thanks in advance.

      • kenny
      • 2 wk ago
      • Reported - view

       The cmake script file looks good. Did you delete the "build" folder before recompilation? The error messages are still the same?

      • Yogendra_Narayanan_Sures
      • 2 wk ago
      • Reported - view

       Thank you for the reply. I have deleted the build folder (attached in first screenshot). Also, when I modified the cmakelists as mentioned earlier the type mismatch error during TOUGH TPLS configuration got rectified (attached in second screenshot). The present error is during building TOUGH (attached in third screenshot). Is it that any other cmakelists has to be edited for fallow-argument mismatch? Thank you in advance.

      • kenny
      • 2 wk ago
      • Reported - view

       

      Sorry, I did not check your cmake scripts very carefully. There are bugs over there. Please try the attached files

Content aside

  • 1 Likes
  • 9 days agoLast active
  • 33Replies
  • 486Views
  • 6 Following