Skip to content

Commit d48220d

Browse files
committed
Platform: attempt to split out the bionic modulemap
This splits out the bionic modulemap from the glibc modulemap. They are sufficiently different that the duplication is worth it. Furthermore, it will enable properly identifying the libc on android. Once fully detangled, this will enable the use of bionic on non-android platforms.
1 parent 9e819ea commit d48220d

File tree

3 files changed

+403
-25
lines changed

3 files changed

+403
-25
lines changed

stdlib/public/Platform/CMakeLists.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,11 @@ foreach(sdk ${SWIFT_SDKS})
9595
set(GLIBC_ARCH_INCLUDE_PATH "${SWIFT_SDK_${sdk}_ARCH_${arch}_PATH}${GLIBC_ARCH_INCLUDE_PATH}")
9696
endif()
9797

98-
set(glibc_modulemap_source "glibc.modulemap.gyb")
98+
if(sdk STREQUAL ANDROID)
99+
set(glibc_modulemap_source "bionic.modulemap.gyb")
100+
else()
101+
set(glibc_modulemap_source "glibc.modulemap.gyb")
102+
endif()
99103
set(glibc_modulemap_out "${module_dir}/glibc.modulemap")
100104

101105
# Configure the module map based on the target. Each platform needs to

0 commit comments

Comments
 (0)