Skip to content

Commit

Permalink
Merge pull request #5530 from nilsvu/fix_external_io
Browse files Browse the repository at this point in the history
Fix linking of ExternalIO on Wheeler
  • Loading branch information
knelli2 authored Oct 3, 2023
2 parents 11217b8 + d28116c commit 374deb9
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions src/IO/External/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@

set(LIBRARY ExternalIO)

if (NOT TARGET SpEC::Exporter AND NOT TARGET FUKA::Exporter)
return()
set(_LIB_TYPE INTERFACE)
if (TARGET FUKA::Exporter)
set(_LIB_TYPE "")
endif()

add_spectre_library(${LIBRARY})
add_spectre_library(${LIBRARY} ${_LIB_TYPE})

if (TARGET SpEC::Exporter)
spectre_target_headers(
Expand All @@ -18,11 +19,14 @@ if (TARGET SpEC::Exporter)
)
target_link_libraries(
${LIBRARY}
PUBLIC
INTERFACE
DataStructures
ErrorHandling
SpEC::Exporter
Utilities
)
target_compile_definitions(
ExternalIO INTERFACE HAS_SPEC_EXPORTER)
${LIBRARY} INTERFACE HAS_SPEC_EXPORTER)
endif()

if (TARGET FUKA::Exporter)
Expand All @@ -40,18 +44,14 @@ if (TARGET FUKA::Exporter)
target_link_libraries(
${LIBRARY}
PUBLIC
DataStructures
FUKA::Exporter
GeneralRelativity
Hydro
Utilities
PRIVATE
ErrorHandling
)
target_compile_definitions(
ExternalIO INTERFACE HAS_FUKA_EXPORTER)
${LIBRARY} INTERFACE HAS_FUKA_EXPORTER)
endif()

target_link_libraries(
${LIBRARY}
PUBLIC
DataStructures
ErrorHandling
Utilities
)

0 comments on commit 374deb9

Please sign in to comment.