diff options
Diffstat (limited to 'sys-devel/llvm/files/9999/0007-llvm-config-Clean-up-exported-values-update-for-shar.patch')
-rw-r--r-- | sys-devel/llvm/files/9999/0007-llvm-config-Clean-up-exported-values-update-for-shar.patch | 47 |
1 files changed, 10 insertions, 37 deletions
diff --git a/sys-devel/llvm/files/9999/0007-llvm-config-Clean-up-exported-values-update-for-shar.patch b/sys-devel/llvm/files/9999/0007-llvm-config-Clean-up-exported-values-update-for-shar.patch index 0ae66bd5..5def55d3 100644 --- a/sys-devel/llvm/files/9999/0007-llvm-config-Clean-up-exported-values-update-for-shar.patch +++ b/sys-devel/llvm/files/9999/0007-llvm-config-Clean-up-exported-values-update-for-shar.patch @@ -1,27 +1,20 @@ -From df2ea14b7c07dd7cf3e33f2e66f36af8af3b425e Mon Sep 17 00:00:00 2001 +From 628b899be14a6bab4b32dbd53aabd447dcc16cb7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org> Date: Sat, 20 Aug 2016 23:47:41 +0200 -Subject: [PATCH 6/9] llvm-config: Clean up exported values, update for shared +Subject: [PATCH] llvm-config: Clean up exported values, update for shared linking Gentoo-specific fixup for llvm-config, including: - wiping build-specific CFLAGS, CXXFLAGS, -- updating library suffixes for shared libs, -- wiping --system-libs for shared linking, -- making --src-root return invalid path (/dev/null), -- making --build-mode return "Release" rather than "Gentoo". +- making --src-root return invalid path (/dev/null). Thanks to Steven Newbury for the initial patch. Bug: https://bugs.gentoo.org/565358 Bug: https://bugs.gentoo.org/501684 ---- - tools/llvm-config/CMakeLists.txt | 11 ++++++++--- - tools/llvm-config/llvm-config.cpp | 9 +++++++-- - 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/tools/llvm-config/CMakeLists.txt b/tools/llvm-config/CMakeLists.txt -index 744fa4e..593788a 100644 +index 744fa4e44d1..593788aaef3 100644 --- a/tools/llvm-config/CMakeLists.txt +++ b/tools/llvm-config/CMakeLists.txt @@ -32,8 +32,12 @@ get_property(COMPILE_FLAGS TARGET llvm-config PROPERTY COMPILE_FLAGS) @@ -39,31 +32,11 @@ index 744fa4e..593788a 100644 set(LLVM_BUILD_SYSTEM cmake) set(LLVM_HAS_RTTI ${LLVM_CONFIG_HAS_RTTI}) set(LLVM_DYLIB_VERSION "${LLVM_VERSION_MAJOR}.${LLVM_VERSION_MINOR}${LLVM_VERSION_SUFFIX}") -@@ -46,7 +50,8 @@ endif() - # Use the C++ link flags, since they should be a superset of C link flags. - set(LLVM_LDFLAGS "${CMAKE_CXX_LINK_FLAGS}") - set(LLVM_BUILDMODE ${CMAKE_BUILD_TYPE}) --set(LLVM_SYSTEM_LIBS ${SYSTEM_LIBS}) -+# We don't do static libs, so we don't need to supply any system-libs -+set(LLVM_SYSTEM_LIBS "") - if(BUILD_SHARED_LIBS) - set(LLVM_ENABLE_SHARED ON) - else() diff --git a/tools/llvm-config/llvm-config.cpp b/tools/llvm-config/llvm-config.cpp -index c63733f..3162091 100644 +index d780094861c..c61c72ff48c 100644 --- a/tools/llvm-config/llvm-config.cpp +++ b/tools/llvm-config/llvm-config.cpp -@@ -522,7 +522,8 @@ int main(int argc, char **argv) { - } else if (Arg == "--host-target") { - OS << Triple::normalize(LLVM_DEFAULT_TARGET_TRIPLE) << '\n'; - } else if (Arg == "--build-mode") { -- OS << build_mode << '\n'; -+ // force Release since we force non-standard Gentoo build mode -+ OS << "Release" << '\n'; - } else if (Arg == "--assertion-mode") { - #if defined(NDEBUG) - OS << "OFF\n"; -@@ -540,7 +541,11 @@ int main(int argc, char **argv) { +@@ -549,7 +550,11 @@ int main(int argc, char **argv) { } else if (Arg == "--obj-root") { OS << ActivePrefix << '\n'; } else if (Arg == "--src-root") { @@ -73,9 +46,9 @@ index c63733f..3162091 100644 + } else { + OS << "/dev/null\n"; + } - } else if (Arg == "--link-shared") { - LinkMode = LinkModeShared; - } else if (Arg == "--link-static") { + } else if (Arg == "--ignore-libllvm") { + LinkDyLib = false; + LinkMode = BuiltSharedLibs ? LinkModeShared : LinkModeAuto; -- -2.9.3 +2.11.0 |