Skip to content

Commit 3c8397f

Browse files
committed
[libc++] Fix installation path for the modulemap
As pointed out in a post-commit comment of https://reviews.llvm.org/rGd00e035a4270. Differential Revision: https://reviews.llvm.org/D142365
1 parent 6363320 commit 3c8397f

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

libcxx/include/CMakeLists.txt

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -909,13 +909,18 @@ if (LIBCXX_INSTALL_HEADERS)
909909
)
910910
endforeach()
911911

912-
# Install the generated __config_site and the generated modulemap file.
912+
# Install the generated __config_site file to the per-target include dir.
913913
install(FILES "${LIBCXX_GENERATED_INCLUDE_TARGET_DIR}/__config_site"
914-
"${LIBCXX_GENERATED_INCLUDE_DIR}/module.modulemap"
915914
DESTINATION "${LIBCXX_INSTALL_INCLUDE_TARGET_DIR}"
916915
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ
917916
COMPONENT cxx-headers)
918917

918+
# Install the generated modulemap file to the generic include dir.
919+
install(FILES "${LIBCXX_GENERATED_INCLUDE_DIR}/module.modulemap"
920+
DESTINATION "${LIBCXX_INSTALL_INCLUDE_DIR}"
921+
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ
922+
COMPONENT cxx-headers)
923+
919924
if (NOT CMAKE_CONFIGURATION_TYPES)
920925
add_custom_target(install-cxx-headers
921926
DEPENDS cxx-headers

0 commit comments

Comments
 (0)