From f7077f3332ad342036f44ea02d6673dc8bea17ce Mon Sep 17 00:00:00 2001 From: Jeremy Schonfeld <1004103+jmschonfeld@users.noreply.github.com> Date: Mon, 29 Jul 2024 09:27:09 -0700 Subject: [PATCH] Add explicit modulemap path to take priority over modulemap from SDK (#789) --- Sources/_FoundationCShims/CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Sources/_FoundationCShims/CMakeLists.txt b/Sources/_FoundationCShims/CMakeLists.txt index ef2a7fe22..1798a5bb0 100644 --- a/Sources/_FoundationCShims/CMakeLists.txt +++ b/Sources/_FoundationCShims/CMakeLists.txt @@ -19,6 +19,9 @@ add_library(_FoundationCShims STATIC target_include_directories(_FoundationCShims PUBLIC include) +target_compile_options(_FoundationCShims INTERFACE + "$<$:SHELL:-Xcc -fmodule-map-file=${CMAKE_CURRENT_SOURCE_DIR}/include/module.modulemap>") + set_property(GLOBAL APPEND PROPERTY SWIFT_FOUNDATION_EXPORTS _FoundationCShims) if(BUILD_SHARED_LIBS)