channotation / chap

CHAP is a tool for the functional annotation of ion channel structures:
http://www.channotation.org
Other
18 stars 10 forks source link

Issue with "Make" command #34

Open joe781114 opened 3 years ago

joe781114 commented 3 years ago

Hi sir, I am trying to install chap 0.9.1 on my workstation which is the Ubuntu 18.04.5 LTS and the gromacs version is 2020.5. Following the installation guide, I first touch the same issue here, then follow the command below by changing the "set(CMAKE_CXX_STANDARD 11)" to "set(CMAKE_CXX_STANDARD 14)", I can successfully get rid of this error message. However, when typing the "make" command again, it shows another error below:

[ 6%] Built target googletest [ 6%] Building CXX object CMakeFiles/chap.dir/src/analysis-setup/residue_information_provider.cpp.o In file included from /home/joe/Downloads/chap-version_0_9_1/src/analysis-setup/residue_information_provider.cpp:25:0: /home/joe/Downloads/chap-version_0_9_1/include/analysis-setup/residue_information_provider.hpp:32:10: fatal error: gromacs/topology/atoms.h: No such file or directory

include <gromacs/topology/atoms.h>

      ^~~~~~~~~~~~~~~~~~~~~~~~~~

compilation terminated. CMakeFiles/chap.dir/build.make:158: recipe for target 'CMakeFiles/chap.dir/src/analysis-setup/residue_information_provider.cpp.o' failed make[2]: [CMakeFiles/chap.dir/src/analysis-setup/residue_information_provider.cpp.o] Error 1 CMakeFiles/Makefile2:355: recipe for target 'CMakeFiles/chap.dir/all' failed make[1]: [CMakeFiles/chap.dir/all] Error 2 Makefile:140: recipe for target 'all' failed make: *** [all] Error 2

I am curious if that means my gromacs program just lost the file "atoms.h"? And I should reinstall the gromacs? Or anything else I should do to fix this error.

Sorry for the interruption, and looking forward to any idea/solution.

jesucastin commented 3 years ago

I am facing the same error. Can anyone help?

philbiggin commented 3 years ago

I believe you need to compile this with an older version of gromacs (2018 or 2019) - the gromacs library changed in the 2020 version onwards.

philbiggin commented 3 years ago

Or rather atoms.h and topology.h are no longer found in the include directory which is where CHAP expects to see them - in fact these files are still in the src directory of gromacs so another solution is to tell the install script where to find them.

Inniag commented 3 years ago

As explained by @philbiggin, the issue is that libgromacs has API-breaking changes between the major versions of Gromacs releases and CHAP has not yet been updated to keep up with these changes.

The easiest workaround is indeed to install CHAP against an older Gromacs version such as 2018. This should then still be able to process trajectories created with the newer Gromacs versions (unless Gromacs has changed something about the trajectory file format itself).

If anyone wants to create a pull request for adjusting the cmake directives to make CHAP find the atoms.h and topology.h files in their new locations, I would be happy to accept that. Only requirement would be that downward compatibility with older Gromacs versions (down to 2016) is maintained.

havebeen commented 2 years ago

Hi all,

I faced this problem as well, and I took the recommendation from Inniag to install Gromacs 2016. However, the link of the regression tests (http://gerrit.**) is failed during installing. Please modify the link in gromacs-2016/tests/CMakeLists.txt to https://ftp.gromacs.org/regressiontests/regressiontests-2016.tar.gz accordingly. In the end, I install the package successfully, and I hope the comment will help others.

DSeiferth commented 2 years ago

Hi @havebeen ,

thanks for your comment!

We have uploaded a precompiled chap version with a singularity image (using gmx 2018). If you have singularity installed, you can use chap without worrying about the dependencies.

https://github.com/channotation/chap/blob/singularity_branch/docs/_docs/getting-started/index.md

havebeen commented 2 years ago

Hi @DSeiferth ,

Speaking to the singularity image... I cannot use that since the singularity said it cannot recognise the image format. I'm quite not sure why it is. For the both .sif and .simg. :(

image

amagg2024 commented 6 months ago

Hi Everyone,

I got a similar error as follows with the make command. Can anyone help me to solve the problem?

[ 40%] Building CXX object CMakeFiles/chap.dir/src/statistics/kernel_density_estimator.cpp.o [ 40%] Building CXX object CMakeFiles/chap.dir/src/statistics/kernel_function.cpp.o [ 41%] Building CXX object CMakeFiles/chap.dir/src/statistics/summary_statistics.cpp.o [ 42%] Building CXX object CMakeFiles/chap.dir/src/statistics/weighted_kernel_density_estimator.cpp.o [ 43%] Building CXX object CMakeFiles/chap.dir/src/trajectory-analysis/chap_trajectory_analysis.cpp.o [ 43%] Building CXX object CMakeFiles/chap.dir/config/version.cpp.o [ 44%] Building CXX object CMakeFiles/chap.dir/config/config.cpp.o [ 45%] Linking CXX executable chap /usr/bin/ld: CMakeFiles/chap.dir/src/analysis-setup/residue_information_provider.cpp.o: in function ResidueInformationProvider::nameFromTopology(gmx::TopologyInformation const&)': residue_information_provider.cpp:(.text+0x707): undefined reference togmx::TopologyInformation::topology() const' /usr/bin/ld: CMakeFiles/chap.dir/src/analysis-setup/residue_information_provider.cpp.o: in function ResidueInformationProvider::chainFromTopology(gmx::TopologyInformation const&)': residue_information_provider.cpp:(.text+0x9f9): undefined reference togmx::TopologyInformation::topology() const' /usr/bin/ld: CMakeFiles/chap.dir/src/io/pdb_io.cpp.o: in function PdbStructure::fromTopology(gmx::TopologyInformation const&)': pdb_io.cpp:(.text+0x1c): undefined reference togmx::TopologyInformation::getTopologyConf(float () [3], float (*) [3]) const' /usr/bin/ld: pdb_io.cpp:(.text+0x24): undefined reference to gmx::TopologyInformation::topology() const' /usr/bin/ld: CMakeFiles/chap.dir/src/io/pdb_io.cpp.o: in functionPdbIo::write(std::__cxx11::basic_string<char, std::char_traits, std::allocator >, PdbStructure)': pdb_io.cpp:(.text+0x2e3): undefined reference to write_sto_conf' /usr/bin/ld: CMakeFiles/chap.dir/src/main.cpp.o: in functionmain': main.cpp:(.text.startup+0x117): undefined reference to gmx::TrajectoryAnalysisCommandLineRunner::runAsMain(int, char**, std::function<std::unique_ptr<gmx::TrajectoryAnalysisModule, std::default_delete<gmx::TrajectoryAnalysisModule> > ()>)' /usr/bin/ld: CMakeFiles/chap.dir/src/path-finding/vdw_radius_provider.cpp.o: in functionVdwRadiusProvider::vdwRadiiForTopology(gmx::TopologyInformation const&, std::vector<int, std::allocator >)': vdw_radius_provider.cpp:(.text+0x25ac): undefined reference to gmx::TopologyInformation::topology() const' /usr/bin/ld: CMakeFiles/chap.dir/src/trajectory-analysis/chap_trajectory_analysis.cpp.o: in functionChapTrajectoryAnalysis::initAnalysis(gmx::TrajectoryAnalysisSettings const&, gmx::TopologyInformation const&)': chap_trajectory_analysis.cpp:(.text+0x1b8c): undefined reference to gmx::AbstractAnalysisData::addModule(std::shared_ptr<gmx::IAnalysisDataModule>)' /usr/bin/ld: chap_trajectory_analysis.cpp:(.text+0x1cee): undefined reference togmx::SelectionCollection::setTopology(gmx_mtop_t, int)' /usr/bin/ld: chap_trajectory_analysis.cpp:(.text+0x1dd3): undefined reference to `gmx::SelectionCollection::setTopology(gmx_mtop_t, int)' /usr/bin/ld: CMakeFiles/chap.dir/src/trajectory-analysis/chap_trajectory_analysis.cpp.o: in function gmx::EnumOption<eHydrophobicityDatabase>::createStorage(gmx::OptionManagerContainer const&) const': chap_trajectory_analysis.cpp:(.text._ZNK3gmx10EnumOptionI23eHydrophobicityDatabaseE13createStorageERKNS_22OptionManagerContainerE[_ZNK3gmx10EnumOptionI23eHydrophobicityDatabaseE13createStorageERKNS_22OptionManagerContainerE]+0x182): undefined reference togmx::internal::createEnumOptionStorage(gmx::AbstractOption const&, char const const, int, int, int, gmx::IOptionValueStore)' /usr/bin/ld: CMakeFiles/chap.dir/src/trajectory-analysis/chap_trajectory_analysis.cpp.o: in function gmx::EnumOption<eDensityEstimator>::createStorage(gmx::OptionManagerContainer const&) const': chap_trajectory_analysis.cpp:(.text._ZNK3gmx10EnumOptionI17eDensityEstimatorE13createStorageERKNS_22OptionManagerContainerE[_ZNK3gmx10EnumOptionI17eDensityEstimatorE13createStorageERKNS_22OptionManagerContainerE]+0x182): undefined reference togmx::internal::createEnumOptionStorage(gmx::AbstractOption const&, char const const, int, int, int, gmx::IOptionValueStore)' /usr/bin/ld: CMakeFiles/chap.dir/src/trajectory-analysis/chap_trajectory_analysis.cpp.o: in function gmx::EnumOption<ePathAlignmentMethod>::createStorage(gmx::OptionManagerContainer const&) const': chap_trajectory_analysis.cpp:(.text._ZNK3gmx10EnumOptionI20ePathAlignmentMethodE13createStorageERKNS_22OptionManagerContainerE[_ZNK3gmx10EnumOptionI20ePathAlignmentMethodE13createStorageERKNS_22OptionManagerContainerE]+0x182): undefined reference togmx::internal::createEnumOptionStorage(gmx::AbstractOption const&, char const const, int, int, int, gmx::IOptionValueStore)' /usr/bin/ld: CMakeFiles/chap.dir/src/trajectory-analysis/chap_trajectory_analysis.cpp.o: in function gmx::EnumOption<eVdwRadiusDatabase>::createStorage(gmx::OptionManagerContainer const&) const': chap_trajectory_analysis.cpp:(.text._ZNK3gmx10EnumOptionI18eVdwRadiusDatabaseE13createStorageERKNS_22OptionManagerContainerE[_ZNK3gmx10EnumOptionI18eVdwRadiusDatabaseE13createStorageERKNS_22OptionManagerContainerE]+0x182): undefined reference togmx::internal::createEnumOptionStorage(gmx::AbstractOption const&, char const const, int, int, int, gmx::IOptionValueStore)' /usr/bin/ld: CMakeFiles/chap.dir/src/trajectory-analysis/chap_trajectory_analysis.cpp.o: in function gmx::EnumOption<ePathFindingMethod>::createStorage(gmx::OptionManagerContainer const&) const': chap_trajectory_analysis.cpp:(.text._ZNK3gmx10EnumOptionI18ePathFindingMethodE13createStorageERKNS_22OptionManagerContainerE[_ZNK3gmx10EnumOptionI18ePathFindingMethodE13createStorageERKNS_22OptionManagerContainerE]+0x182): undefined reference togmx::internal::createEnumOptionStorage(gmx::AbstractOption const&, char const const, int, int, int, gmx::IOptionValueStore*)' collect2: error: ld returned 1 exit status make[2]: ** [CMakeFiles/chap.dir/build.make:889: chap] Error 1 make[1]: [CMakeFiles/Makefile2:157: CMakeFiles/chap.dir/all] Error 2 make: *** [Makefile:146: all] Error 2

k3nick101 commented 4 days ago

I got an error at this point [ 7%] Building CXX object CMakeFiles/chap.dir/src/aggregation/multiscalar_time_series.cpp.o /mnt/c/Users/k1nic/chap-version_0_9_1/src/aggregation/multiscalar_time_series.cpp: In member function ‘void MultiscalarTimeSeries::addScalarTimeSeries(const ScalarTimeSeries&)’: /mnt/c/Users/k1nic/chap-version_0_9_1/src/aggregation/multiscalar_time_series.cpp:56:28: error: ‘logic_error’ is not a member of ‘std’ 56 | throw std::logic_error("Time stamps of new time series do " | ^~~ /mnt/c/Users/k1nic/chap-version_0_9_1/src/aggregation/multiscalar_time_series.cpp:72:24: error: ‘logic_error’ is not a member of ‘std’ 72 | throw std::logic_error("Multiscalar time series can not accept " | ^~~ make[2]: [CMakeFiles/chap.dir/build.make:90: CMakeFiles/chap.dir/src/aggregation/multiscalar_time_series.cpp.o] Error 1 make[1]: [CMakeFiles/Makefile2:157: CMakeFiles/chap.dir/all] Error 2 make: *** [Makefile:146: all] Error 2

philbiggin commented 4 days ago

Which combinations of compilers and gromacs are you using?

On 3 Sep 2024, at 04:51, k3nick101 @.***> wrote:

I got an error at this point [ 7%] Building CXX object CMakeFiles/chap.dir/src/aggregation/multiscalar_time_series.cpp.o /mnt/c/Users/k1nic/chap-version_0_9_1/src/aggregation/multiscalar_time_series.cpp: In member function ‘void MultiscalarTimeSeries::addScalarTimeSeries(const ScalarTimeSeries&)’: /mnt/c/Users/k1nic/chap-version_0_9_1/src/aggregation/multiscalar_time_series.cpp:56:28: error: ‘logic_error’ is not a member of ‘std’ 56 | throw std::logic_error("Time stamps of new time series do " | ^~~ /mnt/c/Users/k1nic/chap-version_0_9_1/src/aggregation/multiscalar_time_series.cpp:72:24: error: ‘logic_error’ is not a member of ‘std’ 72 | throw std::logic_error("Multiscalar time series can not accept " | ^~~ make[2]: [CMakeFiles/chap.dir/build.make:90: CMakeFiles/chap.dir/src/aggregation/multiscalar_time_series.cpp.o] Error 1 make[1]: [CMakeFiles/Makefile2:157: CMakeFiles/chap.dir/all] Error 2 make: *** [Makefile:146: all] Error 2

— Reply to this email directly, view it on GitHubhttps://github.com/channotation/chap/issues/34#issuecomment-2325554740, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AMMKVGXYC66UYZPLNTPO6YTZUUW3LAVCNFSM6AAAAABNRH2BBKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMRVGU2TINZUGA. You are receiving this because you were mentioned.Message ID: @.***>