-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Put mpi suffix in MODL target_link_libraries
- Loading branch information
1 parent
d260a14
commit 382a5d3
Showing
2 changed files
with
8 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,22 @@ | ||
# on fedora, binaries built with mpi must ended by _mpich suffix | ||
file(GLOB cppfiles ${CMAKE_CURRENT_SOURCE_DIR}/*.cpp) | ||
add_executable(MODL${MPI_SUFFIX} ${cppfiles} MODL.rc) | ||
|
||
# MODL executable On Fedora, binaries built with mpi must be suffixed by _mpich (in stored ${MPI_SUFFIX}) | ||
add_executable(MODL${MPI_SUFFIX} ${cppfiles} MODL.rc) | ||
target_link_libraries(MODL${MPI_SUFFIX} PUBLIC DTForest KMDRRuleLibrary KWLearningProblem) | ||
|
||
set_khiops_options(MODL${MPI_SUFFIX}) | ||
if(MPI) | ||
target_link_libraries(MODL${MPI_SUFFIX} PUBLIC PLMPI) | ||
endif() | ||
|
||
# MODL_SO (shared library) | ||
add_library(MODL_SO SHARED ${cppfiles}) | ||
|
||
target_link_libraries(MODL_SO PUBLIC DTForest KMDRRuleLibrary KWLearningProblem) | ||
|
||
if(MPI) | ||
target_link_libraries(MODL PUBLIC PLMPI) | ||
target_link_libraries(MODL_SO PUBLIC PLMPI) | ||
endif() | ||
|
||
set_target_properties( | ||
MODL_SO | ||
PROPERTIES PUBLIC_HEADER MODL_dll.h | ||
SOVERSION ${PROJECT_VERSION_MAJOR} | ||
VERSION ${PROJECT_VERSION}) | ||
|
||
set_khiops_options(MODL_SO) |