[libcxx-commits] [libcxx] [libc++abi][test][VE] Add '-ldl' to support VE (PR #66605)

Kazushi Marukawa via libcxx-commits libcxx-commits at lists.llvm.org
Mon Sep 25 18:12:26 PDT 2023


================
@@ -0,0 +1,28 @@
+# This testing configuration handles running the test suite against LLVM's
+# libc++ for VE using a shared library.
+
+lit_config.load_config(config, '@CMAKE_CURRENT_BINARY_DIR@/cmake-bridge.cfg')
+
+config.substitutions.append(('%{flags}',
+    '-pthread' + (' -isysroot {}'.format('@CMAKE_OSX_SYSROOT@') if '@CMAKE_OSX_SYSROOT@' else '')
+))
+config.substitutions.append(('%{compile_flags}',
+    '-nostdinc++ -I %{include} -I %{target-include} -I %{libcxx}/test/support'
+))
+# VE requires libdl library.
+config.substitutions.append(('%{link_flags}',
+    '-nostdlib++ -L %{lib} -Wl,-rpath,%{lib} -lc++ -ldl'
----------------
kaz7 wrote:

I've noticed that It is possible to solve this problem by not modifying this cfg file but specifying cmake option like `-D_LIBCXX_TEST_COMPILER_CFLAGS="-ldl"`  Was that better for a solution of similar problems?  If so, I'd like to drop this ticket.  Thanks.

https://github.com/llvm/llvm-project/pull/66605


More information about the libcxx-commits mailing list