From d7ed2b01311f15ba54fe8ea872aab7d59ab2b193 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Fri, 29 Jan 2021 18:03:51 +0000 Subject: gentoo resync : 29.01.2021 --- sys-libs/libcxxabi/Manifest | 13 ++- sys-libs/libcxxabi/libcxxabi-11.0.0.ebuild | 3 +- sys-libs/libcxxabi/libcxxabi-11.0.1.ebuild | 1 + sys-libs/libcxxabi/libcxxabi-11.1.0_rc1.ebuild | 1 + sys-libs/libcxxabi/libcxxabi-11.1.0_rc2.ebuild | 123 ++++++++++++++++++++++++ sys-libs/libcxxabi/libcxxabi-12.0.0.9999.ebuild | 1 + sys-libs/libcxxabi/libcxxabi-12.0.0_rc1.ebuild | 122 +++++++++++++++++++++++ sys-libs/libcxxabi/libcxxabi-13.0.0.9999.ebuild | 122 +++++++++++++++++++++++ 8 files changed, 381 insertions(+), 5 deletions(-) create mode 100644 sys-libs/libcxxabi/libcxxabi-11.1.0_rc2.ebuild create mode 100644 sys-libs/libcxxabi/libcxxabi-12.0.0_rc1.ebuild create mode 100644 sys-libs/libcxxabi/libcxxabi-13.0.0.9999.ebuild (limited to 'sys-libs/libcxxabi') diff --git a/sys-libs/libcxxabi/Manifest b/sys-libs/libcxxabi/Manifest index 194d81e6d19f..24c23575e5ba 100644 --- a/sys-libs/libcxxabi/Manifest +++ b/sys-libs/libcxxabi/Manifest @@ -2,11 +2,16 @@ DIST llvmorg-10.0.1.tar.gz 120880730 BLAKE2B 30f19f56c4d1f6abcda5fec76256219d1e3 DIST llvmorg-11.0.0.tar.gz 122743665 BLAKE2B 3f95570240789fd68ddb747df817f5c6cdc9da40911bbe9ee3531c15ada9165e5002b1c2f778cf8735858485ea05a8754e3d3a5f4b15bdd6cb33d64a14692984 SHA512 b6d38871ccce0e086e27d35e42887618d68e57d8274735c59e3eabc42dee352412489296293f8d5169fe0044936345915ee7da61ebdc64ec10f7737f6ecd90f2 DIST llvmorg-11.0.1.tar.gz 122790338 BLAKE2B 0130996b4a8c4d9f757136fd7fb318068c9bfdc565060dec0d4336480c4ab66c4ae3185a7fdb05f13cf9ee8fd4123b09df938881b75d6e5d3689595114b7e32a SHA512 f5e6ef0b3111aae08a89cd01adb2ff4abfa9ef779c68b9190421d0447efd25c2cc00e5aae9f4764805f5fa31434866043d1510ae7389817e28ae53a5442e2fdf DIST llvmorg-11.1.0-rc1.tar.gz 122793491 BLAKE2B f4777455f5903cffea284eaffd872be6c287c6c1ebbd0c4b5b5473f146d7f5476f3551998a58d3e976ab90cde7b0d05db2b3be97f4e8e2c3474755ff38739268 SHA512 44e281486c44fa1611042ab658b9833a75f9613b7f896863613cfb99de66d13607fb1e9064f42ea3d89ca7951113465a90fd96ca4544262f165f78bd5261f5a8 +DIST llvmorg-11.1.0-rc2.tar.gz 122794772 BLAKE2B ab533f078d9d6c37e27c578866a07896344a0b4cf4ebf6402f4fa490213e017310d1c882bf63e552e99a5b4f6d1d8c01413420713b200bfa6732eff64f3c47a9 SHA512 88d8f1d938f0ba7ec39478d03a35c09a30bea51735276205494265b1061621b3ebcda8ee4211e896783b1b99a377c9fa68046118b0d6cb7fcb7bea1e960f95b7 +DIST llvmorg-12.0.0-rc1.tar.gz 134164708 BLAKE2B d4261ff7d9586b47f4cfda3d2cda4b76534f9e17fbd5cdb8861895b8eb466021962f4608bfcdeb52f8fce78850a994fd5eda0560f7211e5c8d1ac9330a738a36 SHA512 3d07d013d0705bb99f56898cc55d054d0d95aeb53b3c756cfab80b4c9097cc4935bcea89b9efde2e503a899b9fccf0dacc0073c9991c8ea352755c5ec68a757a DIST llvmorg-9.0.1.tar.gz 113193320 BLAKE2B b86e405f2b8e00436045fd409fe19cdde75c797b1192c62a22b5ec75e6b4dc8e874a0f33008dc31562445e4cbe53a992b6f48c684255a6a1ef261e595b8b161f SHA512 fa88beeaae94b6d0cd9b5ba38658d0ffed8004035d7d8a4f95c3d31a709b88b581ae9bd7761333c8e5375c44b8f6be01768b5a3be901163159d7e6c43b71da59 EBUILD libcxxabi-10.0.1.ebuild 3238 BLAKE2B e2bd5189a20b8a2a575d1a660d97e7554527f03e4cb3c836b2f1c715bf42ce37250dcf2067639bb59f2c580fd3aa45f4217577ec41a1f4747a7e8397dde519cd SHA512 c6d03f55af65ca576d380497ff172dd3964e31fbc3fe1a8f49ae0b94364d6bf1819505ec5c4b1167744e0f11126cf22b4a8fbba03fff35017cf3963415a675c2 -EBUILD libcxxabi-11.0.0.ebuild 3522 BLAKE2B ada966b60e05398cbe16699736db9c0d4bdf211390dfd0e99bc427eab8ec4314d59d10718dc224e877812814909a85426228eb1978770fb6fe9181ff3b26ef67 SHA512 828350ea6652c111fb8e6688ad5ec10b5ad84c19a8ab0adfa159c9fab610a683ba0330ca0c217820d499363a179793cef6f60c9fc0493e33aec36187855ba59c -EBUILD libcxxabi-11.0.1.ebuild 3528 BLAKE2B d155848221183c32148fd6b7b19c305b087739d4b84337beee4b87ca7e1fa1da250458fd815f4ce80fc60f773ab4900d591b72ae26ba65203061bbade4f6e8e3 SHA512 001d1713c3b5aded3979b471a6c0ff472f9fa3b1a604016cd0c8a87997dc719395f24d9b096601058d4a6e8ecd83396faba956d9be0124244eff36ce61cdcd76 -EBUILD libcxxabi-11.1.0_rc1.ebuild 3487 BLAKE2B e8b6a1a938603246dfea346e1c1af5e133a24ad6e1efea0af1c72c0eaa4f4be38f1414414522b54ca5a3efbdfb3be271f6a3afd7028bf96b83b18878b484cd4d SHA512 56e9679f17a77de2be7157f3adfc10b7285c04bee68c133e689646a1934f5a4621ff9e25f57a2cc418e72185ab4b3058e952f8bc2fb6e5a3c70a38ade6d55263 -EBUILD libcxxabi-12.0.0.9999.ebuild 3470 BLAKE2B 9670b706f063c2e9a12fef3a08d7ee766932d5455e7bf48bac3abcce6dc94ad0a22c79422a3b9bde2b89fde19efa89907418ac65271435368ea152e67281193d SHA512 9131d72aacf8240a1bb2a34d04a6357d88b14dcbb52abacf8a69cf32834fa27d5939687555e4104884f136bd6613374176bf41ffa80b84530da65fc7c7db1e72 +EBUILD libcxxabi-11.0.0.ebuild 3558 BLAKE2B d3d3b5f068087713013696e970a2223f39f073ad5515c4bba146c0fabd33faf83b47526beaba07133d014acebd8f727dffd683ee5411dd62f0f5225768d79e38 SHA512 7582fc26df2ec026628c6da8722a28d186c32a749a150438899af19b2b7cf9020cd19bc2e16a0f1fbd23fdf519565e0584a95484d2e746c62541f0b7a6e6a12f +EBUILD libcxxabi-11.0.1.ebuild 3564 BLAKE2B 4d4c7e2cb8221a8e32447eba8f0495d6fef72d7855aa024c71fae7124e6f4c4f1b3928e246452603331e143b1b8c8a342b930f2e4580dcd5af4f66072fdc079e SHA512 eea2310dc99a95b739e9019efcf9aae5ac6220ca4d9e24d44ad5a57b93e4b97cb43a9b97843900d85fef5657a624951e36988d40505273f961baa164c8a89021 +EBUILD libcxxabi-11.1.0_rc1.ebuild 3523 BLAKE2B e6740b015db19ec8368fe78ad61ab3b430071d303b0678ff53f7115ec482a55b421947830cdc0076e5aa12e7188e9519e5005d50f260546ea7ea7f0c6baf5be8 SHA512 04b125a7e808d738b6e61c85c1438b83da594cc2b0ff18511b01a89524ee23aa580aa7e90e770803b8a197de36f9cb8d72a13733da801251cdc97488c36b5440 +EBUILD libcxxabi-11.1.0_rc2.ebuild 3523 BLAKE2B e6740b015db19ec8368fe78ad61ab3b430071d303b0678ff53f7115ec482a55b421947830cdc0076e5aa12e7188e9519e5005d50f260546ea7ea7f0c6baf5be8 SHA512 04b125a7e808d738b6e61c85c1438b83da594cc2b0ff18511b01a89524ee23aa580aa7e90e770803b8a197de36f9cb8d72a13733da801251cdc97488c36b5440 +EBUILD libcxxabi-12.0.0.9999.ebuild 3506 BLAKE2B bed814ee6a95d02d38b0e702bdcc10ae95c119797a483f91028d372f909625917b725f65caa32bc4a17bb0579f1cdef6ec62e63a436735d55e2a77bc12313025 SHA512 04a3ee8029fa69c7ed3fa2e548f43835205a27e304d2b3bc7496b064e3f60ecca68f8a28c45a6bbe75ab3f24f141661457960a69df3f88deb5d0053b15e9e4f9 +EBUILD libcxxabi-12.0.0_rc1.ebuild 3506 BLAKE2B bed814ee6a95d02d38b0e702bdcc10ae95c119797a483f91028d372f909625917b725f65caa32bc4a17bb0579f1cdef6ec62e63a436735d55e2a77bc12313025 SHA512 04a3ee8029fa69c7ed3fa2e548f43835205a27e304d2b3bc7496b064e3f60ecca68f8a28c45a6bbe75ab3f24f141661457960a69df3f88deb5d0053b15e9e4f9 +EBUILD libcxxabi-13.0.0.9999.ebuild 3506 BLAKE2B bed814ee6a95d02d38b0e702bdcc10ae95c119797a483f91028d372f909625917b725f65caa32bc4a17bb0579f1cdef6ec62e63a436735d55e2a77bc12313025 SHA512 04a3ee8029fa69c7ed3fa2e548f43835205a27e304d2b3bc7496b064e3f60ecca68f8a28c45a6bbe75ab3f24f141661457960a69df3f88deb5d0053b15e9e4f9 EBUILD libcxxabi-9.0.1.ebuild 3390 BLAKE2B 708b1327f629ad4445fde37d53dea7807c433a2e3154f56f3fed4ba9eb698f3bb3e67055820521c58d8a31dc26abf28c293d709f97b4496ab420d788ab532c12 SHA512 18ab388b271756a5eb6dd1650d6a9f05a392b4e2cb48df92359c0e9ac763ecc4672343b4b51184f13c0636fe130e4a5972d8937866d34f1efec4b1addce1f81a MISC metadata.xml 350 BLAKE2B 67b70b8d7292327882a845b76667ce24fee728cd84f27ed7e329bc7963631cba4c28bafce5e6a5fefb4ba1df5c7fd572b3b0d7a2b31ef649496f2f991b691bff SHA512 317dd7b59a711dd0461b5369f7e31ea196882b018e047e1dbae8077274d06cb68542c8762efb852cce0b8021bedea69c19aa0c124b9414a36cf1a9c00e0b9703 diff --git a/sys-libs/libcxxabi/libcxxabi-11.0.0.ebuild b/sys-libs/libcxxabi/libcxxabi-11.0.0.ebuild index 927f9e62f519..d73929a139fe 100644 --- a/sys-libs/libcxxabi/libcxxabi-11.0.0.ebuild +++ b/sys-libs/libcxxabi/libcxxabi-11.0.0.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2021 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 @@ -79,6 +79,7 @@ multilib_src_configure() { mycmakeargs+=( -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" -DLLVM_LIT_ARGS="$(get_lit_flags);--param=cxx_under_test=${clang_path}" + -DPython3_EXECUTABLE="${PYTHON}" ) fi cmake_src_configure diff --git a/sys-libs/libcxxabi/libcxxabi-11.0.1.ebuild b/sys-libs/libcxxabi/libcxxabi-11.0.1.ebuild index e914a402b7b0..b1fcf31caaa6 100644 --- a/sys-libs/libcxxabi/libcxxabi-11.0.1.ebuild +++ b/sys-libs/libcxxabi/libcxxabi-11.0.1.ebuild @@ -81,6 +81,7 @@ multilib_src_configure() { mycmakeargs+=( -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" -DLLVM_LIT_ARGS="$(get_lit_flags);--param=cxx_under_test=${clang_path}" + -DPython3_EXECUTABLE="${PYTHON}" ) fi cmake_src_configure diff --git a/sys-libs/libcxxabi/libcxxabi-11.1.0_rc1.ebuild b/sys-libs/libcxxabi/libcxxabi-11.1.0_rc1.ebuild index c814ad881df9..248121b9aa41 100644 --- a/sys-libs/libcxxabi/libcxxabi-11.1.0_rc1.ebuild +++ b/sys-libs/libcxxabi/libcxxabi-11.1.0_rc1.ebuild @@ -81,6 +81,7 @@ multilib_src_configure() { mycmakeargs+=( -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" -DLLVM_LIT_ARGS="$(get_lit_flags);--param=cxx_under_test=${clang_path}" + -DPython3_EXECUTABLE="${PYTHON}" ) fi cmake_src_configure diff --git a/sys-libs/libcxxabi/libcxxabi-11.1.0_rc2.ebuild b/sys-libs/libcxxabi/libcxxabi-11.1.0_rc2.ebuild new file mode 100644 index 000000000000..248121b9aa41 --- /dev/null +++ b/sys-libs/libcxxabi/libcxxabi-11.1.0_rc2.ebuild @@ -0,0 +1,123 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +CMAKE_ECLASS=cmake +PYTHON_COMPAT=( python3_{6..9} ) +inherit cmake-multilib llvm llvm.org python-any-r1 toolchain-funcs + +DESCRIPTION="Low level support for a standard C++ library" +HOMEPAGE="https://libcxxabi.llvm.org/" + +LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" +SLOT="0" +KEYWORDS="" +IUSE="+libunwind +static-libs test elibc_musl" +RESTRICT="!test? ( test )" + +RDEPEND=" + libunwind? ( + || ( + >=sys-libs/libunwind-1.0.1-r1[static-libs?,${MULTILIB_USEDEP}] + >=sys-libs/llvm-libunwind-3.9.0-r1[static-libs?,${MULTILIB_USEDEP}] + ) + )" +# llvm-6 for new lit options +DEPEND="${RDEPEND} + >=sys-devel/llvm-6" +BDEPEND=" + test? ( >=sys-devel/clang-3.9.0 + $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]') + )" + +# libcxx is needed uncondtionally for the headers +LLVM_COMPONENTS=( libcxx{abi,} ) +LLVM_TEST_COMPONENTS=( llvm/cmake ) +llvm.org_set_globals + +python_check_deps() { + has_version "dev-python/lit[${PYTHON_USEDEP}]" +} + +pkg_setup() { + # darwin prefix builds do not have llvm installed yet, so rely on bootstrap-prefix + # to set the appropriate path vars to LLVM instead of using llvm_pkg_setup. + if [[ ${CHOST} != *-darwin* ]] || has_version dev-lang/llvm; then + llvm_pkg_setup + fi + use test && python-any-r1_pkg_setup +} + +multilib_src_configure() { + # link against compiler-rt instead of libgcc if we are using clang with libunwind + local want_compiler_rt=OFF + if use libunwind && tc-is-clang; then + local compiler_rt=$($(tc-getCC) ${CFLAGS} ${CPPFLAGS} \ + ${LDFLAGS} -print-libgcc-file-name) + if [[ ${compiler_rt} == *libclang_rt* ]]; then + want_compiler_rt=ON + fi + fi + + local libdir=$(get_libdir) + local mycmakeargs=( + -DLIBCXXABI_LIBDIR_SUFFIX=${libdir#lib} + -DLIBCXXABI_ENABLE_SHARED=ON + -DLIBCXXABI_ENABLE_STATIC=$(usex static-libs) + -DLIBCXXABI_USE_LLVM_UNWINDER=$(usex libunwind) + -DLIBCXXABI_INCLUDE_TESTS=$(usex test) + -DLIBCXXABI_USE_COMPILER_RT=${want_compiler_rt} + + -DLIBCXXABI_LIBCXX_INCLUDES="${WORKDIR}"/libcxx/include + # upstream is omitting standard search path for this + # probably because gcc & clang are bundling their own unwind.h + -DLIBCXXABI_LIBUNWIND_INCLUDES="${EPREFIX}"/usr/include + ) + if use test; then + local clang_path=$(type -P "${CHOST:+${CHOST}-}clang" 2>/dev/null) + [[ -n ${clang_path} ]] || die "Unable to find ${CHOST}-clang for tests" + + mycmakeargs+=( + -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" + -DLLVM_LIT_ARGS="$(get_lit_flags);--param=cxx_under_test=${clang_path}" + -DPython3_EXECUTABLE="${PYTHON}" + ) + fi + cmake_src_configure +} + +build_libcxx() { + local -x LDFLAGS="${LDFLAGS} -L${BUILD_DIR}/$(get_libdir)" + local CMAKE_USE_DIR=${WORKDIR}/libcxx + local BUILD_DIR=${BUILD_DIR}/libcxx + local mycmakeargs=( + -DLIBCXX_LIBDIR_SUFFIX= + -DLIBCXX_ENABLE_SHARED=OFF + -DLIBCXX_ENABLE_STATIC=ON + -DLIBCXX_ENABLE_EXPERIMENTAL_LIBRARY=OFF + -DLIBCXX_CXX_ABI=libcxxabi + -DLIBCXX_CXX_ABI_INCLUDE_PATHS="${S}"/include + -DLIBCXX_ENABLE_ABI_LINKER_SCRIPT=OFF + -DLIBCXX_HAS_MUSL_LIBC=$(usex elibc_musl) + -DLIBCXX_HAS_GCC_S_LIB=OFF + -DLIBCXX_INCLUDE_TESTS=OFF + ) + + cmake_src_configure + cmake_src_compile +} + +multilib_src_test() { + # build a local copy of libc++ for testing to avoid circular dep + build_libcxx + mv "${BUILD_DIR}"/libcxx/lib/libc++* "${BUILD_DIR}/$(get_libdir)/" || die + + local -x LIT_PRESERVES_TMP=1 + cmake_build check-cxxabi +} + +multilib_src_install_all() { + insinto /usr/include/libcxxabi + doins -r include/. +} diff --git a/sys-libs/libcxxabi/libcxxabi-12.0.0.9999.ebuild b/sys-libs/libcxxabi/libcxxabi-12.0.0.9999.ebuild index 640970313365..6a0226a845d1 100644 --- a/sys-libs/libcxxabi/libcxxabi-12.0.0.9999.ebuild +++ b/sys-libs/libcxxabi/libcxxabi-12.0.0.9999.ebuild @@ -80,6 +80,7 @@ multilib_src_configure() { mycmakeargs+=( -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" -DLLVM_LIT_ARGS="$(get_lit_flags);--param=cxx_under_test=${clang_path}" + -DPython3_EXECUTABLE="${PYTHON}" ) fi cmake_src_configure diff --git a/sys-libs/libcxxabi/libcxxabi-12.0.0_rc1.ebuild b/sys-libs/libcxxabi/libcxxabi-12.0.0_rc1.ebuild new file mode 100644 index 000000000000..6a0226a845d1 --- /dev/null +++ b/sys-libs/libcxxabi/libcxxabi-12.0.0_rc1.ebuild @@ -0,0 +1,122 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +CMAKE_ECLASS=cmake +PYTHON_COMPAT=( python3_{6..9} ) +inherit cmake-multilib llvm llvm.org python-any-r1 toolchain-funcs + +DESCRIPTION="Low level support for a standard C++ library" +HOMEPAGE="https://libcxxabi.llvm.org/" + +LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" +SLOT="0" +KEYWORDS="" +IUSE="+libunwind +static-libs test elibc_musl" +RESTRICT="!test? ( test )" + +RDEPEND=" + libunwind? ( + || ( + >=sys-libs/libunwind-1.0.1-r1[static-libs?,${MULTILIB_USEDEP}] + >=sys-libs/llvm-libunwind-3.9.0-r1[static-libs?,${MULTILIB_USEDEP}] + ) + )" +# llvm-6 for new lit options +DEPEND="${RDEPEND} + >=sys-devel/llvm-6" +BDEPEND=" + test? ( >=sys-devel/clang-3.9.0 + $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]') + )" + +# libcxx is needed uncondtionally for the headers +LLVM_COMPONENTS=( libcxx{abi,} llvm/cmake/modules ) +llvm.org_set_globals + +python_check_deps() { + has_version "dev-python/lit[${PYTHON_USEDEP}]" +} + +pkg_setup() { + # darwin prefix builds do not have llvm installed yet, so rely on bootstrap-prefix + # to set the appropriate path vars to LLVM instead of using llvm_pkg_setup. + if [[ ${CHOST} != *-darwin* ]] || has_version dev-lang/llvm; then + llvm_pkg_setup + fi + use test && python-any-r1_pkg_setup +} + +multilib_src_configure() { + # link against compiler-rt instead of libgcc if we are using clang with libunwind + local want_compiler_rt=OFF + if use libunwind && tc-is-clang; then + local compiler_rt=$($(tc-getCC) ${CFLAGS} ${CPPFLAGS} \ + ${LDFLAGS} -print-libgcc-file-name) + if [[ ${compiler_rt} == *libclang_rt* ]]; then + want_compiler_rt=ON + fi + fi + + local libdir=$(get_libdir) + local mycmakeargs=( + -DLIBCXXABI_LIBDIR_SUFFIX=${libdir#lib} + -DLIBCXXABI_ENABLE_SHARED=ON + -DLIBCXXABI_ENABLE_STATIC=$(usex static-libs) + -DLIBCXXABI_USE_LLVM_UNWINDER=$(usex libunwind) + -DLIBCXXABI_INCLUDE_TESTS=$(usex test) + -DLIBCXXABI_USE_COMPILER_RT=${want_compiler_rt} + + -DLIBCXXABI_LIBCXX_INCLUDES="${WORKDIR}"/libcxx/include + # upstream is omitting standard search path for this + # probably because gcc & clang are bundling their own unwind.h + -DLIBCXXABI_LIBUNWIND_INCLUDES="${EPREFIX}"/usr/include + ) + if use test; then + local clang_path=$(type -P "${CHOST:+${CHOST}-}clang" 2>/dev/null) + [[ -n ${clang_path} ]] || die "Unable to find ${CHOST}-clang for tests" + + mycmakeargs+=( + -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" + -DLLVM_LIT_ARGS="$(get_lit_flags);--param=cxx_under_test=${clang_path}" + -DPython3_EXECUTABLE="${PYTHON}" + ) + fi + cmake_src_configure +} + +build_libcxx() { + local -x LDFLAGS="${LDFLAGS} -L${BUILD_DIR}/$(get_libdir)" + local CMAKE_USE_DIR=${WORKDIR}/libcxx + local BUILD_DIR=${BUILD_DIR}/libcxx + local mycmakeargs=( + -DLIBCXX_LIBDIR_SUFFIX= + -DLIBCXX_ENABLE_SHARED=OFF + -DLIBCXX_ENABLE_STATIC=ON + -DLIBCXX_ENABLE_EXPERIMENTAL_LIBRARY=OFF + -DLIBCXX_CXX_ABI=libcxxabi + -DLIBCXX_CXX_ABI_INCLUDE_PATHS="${S}"/include + -DLIBCXX_ENABLE_ABI_LINKER_SCRIPT=OFF + -DLIBCXX_HAS_MUSL_LIBC=$(usex elibc_musl) + -DLIBCXX_HAS_GCC_S_LIB=OFF + -DLIBCXX_INCLUDE_TESTS=OFF + ) + + cmake_src_configure + cmake_src_compile +} + +multilib_src_test() { + # build a local copy of libc++ for testing to avoid circular dep + build_libcxx + mv "${BUILD_DIR}"/libcxx/lib/libc++* "${BUILD_DIR}/$(get_libdir)/" || die + + local -x LIT_PRESERVES_TMP=1 + cmake_build check-cxxabi +} + +multilib_src_install_all() { + insinto /usr/include/libcxxabi + doins -r include/. +} diff --git a/sys-libs/libcxxabi/libcxxabi-13.0.0.9999.ebuild b/sys-libs/libcxxabi/libcxxabi-13.0.0.9999.ebuild new file mode 100644 index 000000000000..6a0226a845d1 --- /dev/null +++ b/sys-libs/libcxxabi/libcxxabi-13.0.0.9999.ebuild @@ -0,0 +1,122 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +CMAKE_ECLASS=cmake +PYTHON_COMPAT=( python3_{6..9} ) +inherit cmake-multilib llvm llvm.org python-any-r1 toolchain-funcs + +DESCRIPTION="Low level support for a standard C++ library" +HOMEPAGE="https://libcxxabi.llvm.org/" + +LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" +SLOT="0" +KEYWORDS="" +IUSE="+libunwind +static-libs test elibc_musl" +RESTRICT="!test? ( test )" + +RDEPEND=" + libunwind? ( + || ( + >=sys-libs/libunwind-1.0.1-r1[static-libs?,${MULTILIB_USEDEP}] + >=sys-libs/llvm-libunwind-3.9.0-r1[static-libs?,${MULTILIB_USEDEP}] + ) + )" +# llvm-6 for new lit options +DEPEND="${RDEPEND} + >=sys-devel/llvm-6" +BDEPEND=" + test? ( >=sys-devel/clang-3.9.0 + $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]') + )" + +# libcxx is needed uncondtionally for the headers +LLVM_COMPONENTS=( libcxx{abi,} llvm/cmake/modules ) +llvm.org_set_globals + +python_check_deps() { + has_version "dev-python/lit[${PYTHON_USEDEP}]" +} + +pkg_setup() { + # darwin prefix builds do not have llvm installed yet, so rely on bootstrap-prefix + # to set the appropriate path vars to LLVM instead of using llvm_pkg_setup. + if [[ ${CHOST} != *-darwin* ]] || has_version dev-lang/llvm; then + llvm_pkg_setup + fi + use test && python-any-r1_pkg_setup +} + +multilib_src_configure() { + # link against compiler-rt instead of libgcc if we are using clang with libunwind + local want_compiler_rt=OFF + if use libunwind && tc-is-clang; then + local compiler_rt=$($(tc-getCC) ${CFLAGS} ${CPPFLAGS} \ + ${LDFLAGS} -print-libgcc-file-name) + if [[ ${compiler_rt} == *libclang_rt* ]]; then + want_compiler_rt=ON + fi + fi + + local libdir=$(get_libdir) + local mycmakeargs=( + -DLIBCXXABI_LIBDIR_SUFFIX=${libdir#lib} + -DLIBCXXABI_ENABLE_SHARED=ON + -DLIBCXXABI_ENABLE_STATIC=$(usex static-libs) + -DLIBCXXABI_USE_LLVM_UNWINDER=$(usex libunwind) + -DLIBCXXABI_INCLUDE_TESTS=$(usex test) + -DLIBCXXABI_USE_COMPILER_RT=${want_compiler_rt} + + -DLIBCXXABI_LIBCXX_INCLUDES="${WORKDIR}"/libcxx/include + # upstream is omitting standard search path for this + # probably because gcc & clang are bundling their own unwind.h + -DLIBCXXABI_LIBUNWIND_INCLUDES="${EPREFIX}"/usr/include + ) + if use test; then + local clang_path=$(type -P "${CHOST:+${CHOST}-}clang" 2>/dev/null) + [[ -n ${clang_path} ]] || die "Unable to find ${CHOST}-clang for tests" + + mycmakeargs+=( + -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" + -DLLVM_LIT_ARGS="$(get_lit_flags);--param=cxx_under_test=${clang_path}" + -DPython3_EXECUTABLE="${PYTHON}" + ) + fi + cmake_src_configure +} + +build_libcxx() { + local -x LDFLAGS="${LDFLAGS} -L${BUILD_DIR}/$(get_libdir)" + local CMAKE_USE_DIR=${WORKDIR}/libcxx + local BUILD_DIR=${BUILD_DIR}/libcxx + local mycmakeargs=( + -DLIBCXX_LIBDIR_SUFFIX= + -DLIBCXX_ENABLE_SHARED=OFF + -DLIBCXX_ENABLE_STATIC=ON + -DLIBCXX_ENABLE_EXPERIMENTAL_LIBRARY=OFF + -DLIBCXX_CXX_ABI=libcxxabi + -DLIBCXX_CXX_ABI_INCLUDE_PATHS="${S}"/include + -DLIBCXX_ENABLE_ABI_LINKER_SCRIPT=OFF + -DLIBCXX_HAS_MUSL_LIBC=$(usex elibc_musl) + -DLIBCXX_HAS_GCC_S_LIB=OFF + -DLIBCXX_INCLUDE_TESTS=OFF + ) + + cmake_src_configure + cmake_src_compile +} + +multilib_src_test() { + # build a local copy of libc++ for testing to avoid circular dep + build_libcxx + mv "${BUILD_DIR}"/libcxx/lib/libc++* "${BUILD_DIR}/$(get_libdir)/" || die + + local -x LIT_PRESERVES_TMP=1 + cmake_build check-cxxabi +} + +multilib_src_install_all() { + insinto /usr/include/libcxxabi + doins -r include/. +} -- cgit v1.2.3