1 # Defines targets for the C++ restraints implemented here. These CMake targets are used by the
2 # unit tests and by the Python module target defined in ../pythonmodule/CMakeLists.txt
4 # Create a shared object library for our restrained ensemble plugin.
5 add_library(gmxapi_extension_ensemblepotential STATIC
9 set_target_properties(gmxapi_extension_ensemblepotential PROPERTIES POSITION_INDEPENDENT_CODE ON)
11 target_include_directories(gmxapi_extension_ensemblepotential PUBLIC
12 $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
13 $<INSTALL_INTERFACE:include>
16 # don't skip the full RPATH for the build tree
17 set_target_properties(gmxapi_extension_ensemblepotential PROPERTIES SKIP_BUILD_RPATH FALSE)
19 # (but later on when installing)
20 # If building with setuptools, CMake will not be performing the install
21 set_target_properties(gmxapi_extension_ensemblepotential PROPERTIES BUILD_WITH_INSTALL_RPATH TRUE)
23 target_link_libraries(gmxapi_extension_ensemblepotential PUBLIC Gromacs::libgromacs Gromacs::gmxapi)