-
Notifications
You must be signed in to change notification settings - Fork 15.5k
[runtimes] Remove dependencies on cxx_experimental for test-suite installs #171678
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[runtimes] Remove dependencies on cxx_experimental for test-suite installs #171678
Conversation
…talls This patch removes explicit dependencies on cxx_experimental for installations that are local to the test suite. Such dependencies are not required anymore from the test-suite installation targets since the proper dependency is now encoded between cxx and cxx_experimental.
693ea8f to
ca5ec85
Compare
|
@llvm/pr-subscribers-libcxx @llvm/pr-subscribers-libunwind Author: Louis Dionne (ldionne) ChangesThis patch removes explicit dependencies on cxx_experimental for Full diff: https://github.com/llvm/llvm-project/pull/171678.diff 4 Files Affected:
diff --git a/libcxx/src/CMakeLists.txt b/libcxx/src/CMakeLists.txt
index 3d70e1197236a..2c04cbd1b2729 100644
--- a/libcxx/src/CMakeLists.txt
+++ b/libcxx/src/CMakeLists.txt
@@ -345,8 +345,8 @@ set_target_properties(cxx_experimental
cxx_add_common_build_flags(cxx_experimental)
target_compile_options(cxx_experimental PUBLIC -D_LIBCPP_ENABLE_EXPERIMENTAL)
-# Add a meta-target for both libraries.
-add_custom_target(cxx)
+# Add a meta-target for both libraries and the experimental library.
+add_custom_target(cxx DEPENDS cxx_experimental)
if (LIBCXX_ENABLE_SHARED)
add_dependencies(cxx cxx_shared)
endif()
@@ -389,9 +389,6 @@ if (NOT CMAKE_CONFIGURATION_TYPES)
add_custom_target(install-cxx-stripped
COMMAND "${CMAKE_COMMAND}" --install "${CMAKE_BINARY_DIR}" --component cxx --strip)
- add_dependencies(install-cxx cxx_experimental)
- add_dependencies(install-cxx-stripped cxx_experimental)
-
if (LIBCXX_INSTALL_LIBRARY)
add_dependencies(install-cxx cxx)
add_dependencies(install-cxx-stripped cxx)
diff --git a/libcxx/test/CMakeLists.txt b/libcxx/test/CMakeLists.txt
index 8db36bcda944c..6294319815b42 100644
--- a/libcxx/test/CMakeLists.txt
+++ b/libcxx/test/CMakeLists.txt
@@ -19,9 +19,6 @@ foreach(target IN LISTS libcxx_test_suite_install_targets)
--component "${target}")
add_dependencies(cxx-test-depends libcxx-test-suite-install-${target})
endforeach()
-if (TARGET cxx_experimental)
- add_dependencies(libcxx-test-suite-install-cxx cxx_experimental)
-endif()
set(AUTO_GEN_COMMENT "## Autogenerated by libcxx configuration.\n# Do not edit!")
set(SERIALIZED_LIT_PARAMS "# Lit parameters serialized here for llvm-lit to pick them up\n")
diff --git a/libcxxabi/test/CMakeLists.txt b/libcxxabi/test/CMakeLists.txt
index fadc818da2dc7..bc0902054a3be 100644
--- a/libcxxabi/test/CMakeLists.txt
+++ b/libcxxabi/test/CMakeLists.txt
@@ -23,9 +23,6 @@ foreach(target IN LISTS libcxxabi_test_suite_install_targets)
--component "${target}")
add_dependencies(cxxabi-test-depends libcxxabi-test-suite-install-${target})
endforeach()
-if (TARGET cxx_experimental)
- add_dependencies(libcxxabi-test-suite-install-cxx cxx_experimental)
-endif()
pythonize_bool(LIBCXXABI_USE_LLVM_UNWINDER)
diff --git a/libunwind/test/CMakeLists.txt b/libunwind/test/CMakeLists.txt
index 42838218dac49..2559ab34f9d5b 100644
--- a/libunwind/test/CMakeLists.txt
+++ b/libunwind/test/CMakeLists.txt
@@ -15,7 +15,7 @@ endmacro()
set(LIBUNWIND_TESTING_INSTALL_PREFIX "${LIBUNWIND_BINARY_DIR}/test-suite-install")
set(libunwind_test_suite_install_targets unwind-headers unwind)
if ("libcxx" IN_LIST LLVM_ENABLE_RUNTIMES)
- list(APPEND libunwind_test_suite_install_targets cxx-headers cxx cxx_experimental cxx-modules cxxabi-headers cxxabi)
+ list(APPEND libunwind_test_suite_install_targets cxx-headers cxx cxx-modules cxxabi-headers cxxabi)
endif()
foreach(target IN LISTS libunwind_test_suite_install_targets)
add_custom_target(libunwind-test-suite-install-${target} DEPENDS "${target}"
|
|
@llvm/pr-subscribers-libcxxabi Author: Louis Dionne (ldionne) ChangesThis patch removes explicit dependencies on cxx_experimental for Full diff: https://github.com/llvm/llvm-project/pull/171678.diff 4 Files Affected:
diff --git a/libcxx/src/CMakeLists.txt b/libcxx/src/CMakeLists.txt
index 3d70e1197236a..2c04cbd1b2729 100644
--- a/libcxx/src/CMakeLists.txt
+++ b/libcxx/src/CMakeLists.txt
@@ -345,8 +345,8 @@ set_target_properties(cxx_experimental
cxx_add_common_build_flags(cxx_experimental)
target_compile_options(cxx_experimental PUBLIC -D_LIBCPP_ENABLE_EXPERIMENTAL)
-# Add a meta-target for both libraries.
-add_custom_target(cxx)
+# Add a meta-target for both libraries and the experimental library.
+add_custom_target(cxx DEPENDS cxx_experimental)
if (LIBCXX_ENABLE_SHARED)
add_dependencies(cxx cxx_shared)
endif()
@@ -389,9 +389,6 @@ if (NOT CMAKE_CONFIGURATION_TYPES)
add_custom_target(install-cxx-stripped
COMMAND "${CMAKE_COMMAND}" --install "${CMAKE_BINARY_DIR}" --component cxx --strip)
- add_dependencies(install-cxx cxx_experimental)
- add_dependencies(install-cxx-stripped cxx_experimental)
-
if (LIBCXX_INSTALL_LIBRARY)
add_dependencies(install-cxx cxx)
add_dependencies(install-cxx-stripped cxx)
diff --git a/libcxx/test/CMakeLists.txt b/libcxx/test/CMakeLists.txt
index 8db36bcda944c..6294319815b42 100644
--- a/libcxx/test/CMakeLists.txt
+++ b/libcxx/test/CMakeLists.txt
@@ -19,9 +19,6 @@ foreach(target IN LISTS libcxx_test_suite_install_targets)
--component "${target}")
add_dependencies(cxx-test-depends libcxx-test-suite-install-${target})
endforeach()
-if (TARGET cxx_experimental)
- add_dependencies(libcxx-test-suite-install-cxx cxx_experimental)
-endif()
set(AUTO_GEN_COMMENT "## Autogenerated by libcxx configuration.\n# Do not edit!")
set(SERIALIZED_LIT_PARAMS "# Lit parameters serialized here for llvm-lit to pick them up\n")
diff --git a/libcxxabi/test/CMakeLists.txt b/libcxxabi/test/CMakeLists.txt
index fadc818da2dc7..bc0902054a3be 100644
--- a/libcxxabi/test/CMakeLists.txt
+++ b/libcxxabi/test/CMakeLists.txt
@@ -23,9 +23,6 @@ foreach(target IN LISTS libcxxabi_test_suite_install_targets)
--component "${target}")
add_dependencies(cxxabi-test-depends libcxxabi-test-suite-install-${target})
endforeach()
-if (TARGET cxx_experimental)
- add_dependencies(libcxxabi-test-suite-install-cxx cxx_experimental)
-endif()
pythonize_bool(LIBCXXABI_USE_LLVM_UNWINDER)
diff --git a/libunwind/test/CMakeLists.txt b/libunwind/test/CMakeLists.txt
index 42838218dac49..2559ab34f9d5b 100644
--- a/libunwind/test/CMakeLists.txt
+++ b/libunwind/test/CMakeLists.txt
@@ -15,7 +15,7 @@ endmacro()
set(LIBUNWIND_TESTING_INSTALL_PREFIX "${LIBUNWIND_BINARY_DIR}/test-suite-install")
set(libunwind_test_suite_install_targets unwind-headers unwind)
if ("libcxx" IN_LIST LLVM_ENABLE_RUNTIMES)
- list(APPEND libunwind_test_suite_install_targets cxx-headers cxx cxx_experimental cxx-modules cxxabi-headers cxxabi)
+ list(APPEND libunwind_test_suite_install_targets cxx-headers cxx cxx-modules cxxabi-headers cxxabi)
endif()
foreach(target IN LISTS libunwind_test_suite_install_targets)
add_custom_target(libunwind-test-suite-install-${target} DEPENDS "${target}"
|
|
I don't understand the Windows build failures. I'm struggling to see how that might be related to this patch. Re-running. |
|
Ok, the CI issue seems to be transient. It's the first time I see it, so I'll merge, but if we start seeing this more often we'll need to investigate. |
This patch removes explicit dependencies on cxx_experimental for
installations that are local to the test suite. Such dependencies
are not required anymore from the test-suite installation targets
since the proper dependency is now encoded between cxx and
cxx_experimental.