Switch to using the DAGMC exported target.

This commit is contained in:
Patrick Shriwise 2020-04-01 20:54:08 -05:00
parent 9b499b4096
commit b45484f940

View file

@ -40,13 +40,6 @@ endif()
#===============================================================================
if(dagmc)
find_package(DAGMC REQUIRED)
add_library(dagmc-imported INTERFACE IMPORTED)
link_directories(${DAGMC_LIBRARY_DIRS})
set_target_properties(dagmc-imported PROPERTIES
INTERFACE_LINK_LIBRARIES "${DAGMC_LIBRARIES}"
INTERFACE_INCLUDE_DIRECTORIES "${DAGMC_INCLUDE_DIRS}")
else()
set(DAGMC_FOUND false)
endif()
#===============================================================================
@ -371,7 +364,7 @@ target_link_libraries(libopenmc ${ldflags} ${HDF5_LIBRARIES} ${HDF5_HL_LIBRARIES
if(dagmc)
target_compile_definitions(libopenmc PRIVATE DAGMC)
target_link_libraries(libopenmc dagmc-imported)
target_link_libraries(libopenmc dagmc-shared pyne_dagmc-shared uwuw-shared)
endif()
#===============================================================================