]> https://gitweb.dealii.org/ - dealii.git/commitdiff
CMake: use CXX language guard consistently
authorMatthias Maier <tamiko@43-1.org>
Mon, 6 Mar 2023 15:34:06 +0000 (09:34 -0600)
committerMatthias Maier <tamiko@43-1.org>
Fri, 17 Mar 2023 12:44:54 +0000 (07:44 -0500)
cmake/macros/macro_populate_target_properties.cmake

index bbfdc9f12a557c1499a4239b5b4d5a81e48e40a0..8363484ea7b11843b9c1bb90d73860b9a86c5759 100644 (file)
@@ -106,7 +106,9 @@ function(populate_target_properties _target _build)
     separate_arguments(_link_options UNIX_COMMAND
       "${DEAL_II_LINKER_FLAGS} ${DEAL_II_LINKER_FLAGS_${_build}}"
       )
-    target_link_options(${_target} PRIVATE ${_link_options})
+    target_link_options(${_target} PRIVATE
+      $<$<COMPILE_LANGUAGE:CXX>:${_link_options}>
+      )
   endif()
 
   target_link_libraries(${_target} ${_visibility}

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.