aboutsummaryrefslogtreecommitdiff
path: root/cmake/NativeCompiler.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake/NativeCompiler.cmake')
-rw-r--r--cmake/NativeCompiler.cmake13
1 files changed, 7 insertions, 6 deletions
diff --git a/cmake/NativeCompiler.cmake b/cmake/NativeCompiler.cmake
index 29682ec..35c7f41 100644
--- a/cmake/NativeCompiler.cmake
+++ b/cmake/NativeCompiler.cmake
@@ -18,6 +18,13 @@ else()
set(cpsc_linker_libraries lldELF)
endif()
+foreach(cpsc_native_library clangDriver ${cpsc_linker_libraries})
+ get_target_property(cpsc_native_type ${cpsc_native_library} TYPE)
+ if(NOT cpsc_native_type STREQUAL "STATIC_LIBRARY")
+ message(FATAL_ERROR "Native output requires static ${cpsc_native_library}; found ${cpsc_native_type}. See doc/build.md for static dependency setup.")
+ endif()
+endforeach()
+
set(cpsc_native_flags)
get_filename_component(cpsc_lld_prefix "${LLD_DIR}/../../.." ABSOLUTE)
if(APPLE)
@@ -105,9 +112,3 @@ foreach(cpsc_import IN LISTS CLANG_EXPORTED_TARGETS LLD_EXPORTED_TARGETS LLVM_AV
set_property(TARGET ${cpsc_import} PROPERTY INTERFACE_LINK_LIBRARIES "${cpsc_interface}")
endif()
endforeach()
-foreach(cpsc_native_library clangDriver ${cpsc_linker_libraries})
- get_target_property(cpsc_native_type ${cpsc_native_library} TYPE)
- if(NOT cpsc_native_type STREQUAL "STATIC_LIBRARY")
- message(FATAL_ERROR "Native output requires static ${cpsc_native_library}")
- endif()
-endforeach()