Skip to content

Commit

Permalink
CMake: only enable link option -cuda when using ACC
Browse files Browse the repository at this point in the history
  • Loading branch information
CasparJungbacker committed Nov 28, 2024
1 parent 3a93c9e commit 5ebe749
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,9 @@ ecbuild_add_executable( TARGET dales
$<$<BOOL:${ENABLE_NVTX}>:CUDA::nvToolsExt>
)
# Temporary
target_link_options( dales PUBLIC -cuda )
if( ENABLE_ACC )
target_link_options( dales PUBLIC -cuda )
endif()

# DALES library, e.g. for use with OMUSE. Only built if -DENABLE_DALESLIB is turned on.
ecbuild_add_library( TARGET libdales
Expand Down

0 comments on commit 5ebe749

Please sign in to comment.