[PATCH] D45529: [CMake] Set the default ABI version for Fuchsia in CMake as well
Petr Hosek via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Apr 12 14:17:44 PDT 2018
phosek updated this revision to Diff 142261.
phosek marked an inline comment as done.
phosek added a comment.
I had something similar in https://reviews.llvm.org/D45304 but Eric suggested removing it. What I haven't realized is that this value is also used to set the SOVERSION so it's indeed needed.
Repository:
rCXX libc++
https://reviews.llvm.org/D45529
Files:
libcxx/CMakeLists.txt
Index: libcxx/CMakeLists.txt
===================================================================
--- libcxx/CMakeLists.txt
+++ libcxx/CMakeLists.txt
@@ -97,7 +97,12 @@
cmake_dependent_option(LIBCXX_INSTALL_EXPERIMENTAL_LIBRARY
"Install libc++experimental.a" ON
"LIBCXX_ENABLE_EXPERIMENTAL_LIBRARY;LIBCXX_INSTALL_LIBRARY" OFF)
-set(LIBCXX_ABI_VERSION 1 CACHE STRING "ABI version of libc++.")
+if (FUCHSIA)
+ set(DEFAULT_ABI_VERSION 2)
+else()
+ set(DEFAULT_ABI_VERSION 1)
+endif()
+set(LIBCXX_ABI_VERSION ${DEFAULT_ABI_VERSION} CACHE STRING "ABI version of libc++.")
option(LIBCXX_ABI_UNSTABLE "Unstable ABI of libc++." OFF)
option(LIBCXX_ABI_FORCE_ITANIUM "Ignore auto-detection and force use of the Itanium ABI.")
option(LIBCXX_ABI_FORCE_MICROSOFT "Ignore auto-detection and force use of the Microsoft ABI.")
@@ -619,7 +624,7 @@
endif()
# Configuration file flags =====================================================
-if (NOT LIBCXX_ABI_VERSION EQUAL "1")
+if (NOT LIBCXX_ABI_VERSION EQUAL DEFAULT_ABI_VERSION)
config_define(${LIBCXX_ABI_VERSION} _LIBCPP_ABI_VERSION)
endif()
config_define_if(LIBCXX_ABI_UNSTABLE _LIBCPP_ABI_UNSTABLE)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D45529.142261.patch
Type: text/x-patch
Size: 1170 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180412/03f18399/attachment.bin>
More information about the cfe-commits
mailing list