We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent db9b0d2 commit f0a1456Copy full SHA for f0a1456
1 file changed
CMakeLists.txt
@@ -735,13 +735,17 @@ if(openPMD_USE_INVASIVE_TESTS)
735
target_compile_definitions(openPMD PRIVATE openPMD_USE_INVASIVE_TESTS=1)
736
endif()
737
738
-foreach(target openPMD openPMD.py)
+function(set_filesystem_header_for_target target)
739
if(openPMD_USE_FILESYSTEM_HEADER)
740
target_compile_definitions(${target} PRIVATE openPMD_USE_FILESYSTEM_HEADER=1)
741
else()
742
target_compile_definitions(${target} PRIVATE openPMD_USE_FILESYSTEM_HEADER=0)
743
744
-endforeach()
+endfunction()
745
+set_filesystem_header_for_target(openPMD)
746
+if(openPMD_HAVE_PYTHON)
747
+ set_filesystem_header_for_target(openPMD.py)
748
+endif()
749
750
if(openPMD_BUILD_TESTING)
751
# compile Catch2 implementation part separately
0 commit comments