From 79599515788b85b18aa655e7b7f8cc05c1bbddd8 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 16 Feb 2019 12:59:29 +0000 Subject: gentoo resync : 16.02.1018 --- sys-libs/compiler-rt-sanitizers/Manifest | 7 +- .../compiler-rt-sanitizers-8.0.0_rc2.ebuild | 171 +++++++++++++++++++++ .../compiler-rt-sanitizers-8.0.9999.ebuild | 3 +- .../compiler-rt-sanitizers-9999.ebuild | 3 +- 4 files changed, 178 insertions(+), 6 deletions(-) create mode 100644 sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-8.0.0_rc2.ebuild (limited to 'sys-libs/compiler-rt-sanitizers') diff --git a/sys-libs/compiler-rt-sanitizers/Manifest b/sys-libs/compiler-rt-sanitizers/Manifest index 3f6c6e6acf08..189b07572fd1 100644 --- a/sys-libs/compiler-rt-sanitizers/Manifest +++ b/sys-libs/compiler-rt-sanitizers/Manifest @@ -5,17 +5,20 @@ DIST compiler-rt-4.0.1.src.tar.xz 1434100 BLAKE2B ca6bf78fc07f387b7244a52ef648b0 DIST compiler-rt-5.0.2.src.tar.xz 1543256 BLAKE2B 09fa84b8f3e9b8627a14387bc6eaa3d6b4588b9c8f1ac5a0114135fd830e3d45922408b237866789eb81bf38defde1186e0f7430a69f825bee12776b7cd9f74e SHA512 605a6d064877a860d6c9097e0220896dfceafed0a2392ad495c97aa347b97899d89f7e21932e29d3274f396615837414a3e730a915fe4f53eaa858ce3642a666 DIST compiler-rt-6.0.1.src.tar.xz 1686820 BLAKE2B 59fa3f6e478bd4d6dfa056c85dcdc4349cbce7cea7fc56519feddc9d66c88c9ca48bad7967432ceb81d754213577f12707035afd827cf630a58627575b73b798 SHA512 69850c1ad92c66977fa217cbfb42a6a3f502fbe3d1a08daa7fc4cfeb617a7736d231f8ad8d93b10b1ae29bd753315d2a2d70f9ff1f4d18a9a7cc81758d91f963 DIST compiler-rt-7.0.1.src.tar.xz 1864520 BLAKE2B 14f72aad4379387f4212fb5efef3456cb5e8a03c7a91f98de2368e9b5ff2d02aeaed05da4fba6978b9e4e8698eb34c9c0c4c2df8d43b8c11e8e9d65079c7fa41 SHA512 b94a2a1fb9a6d587cef59b04b951628747bb35bdbcb67de8825aad402a2ba875916a347eef7a9575ac27264e8372e2d67cd477fe2d750c0ed3ce7d67bbbc7dba +DIST compiler-rt-8.0.0rc2.src.tar.xz 1902996 BLAKE2B e1f0046d130a9214ddf00cdb50e303316b9207eb8df946872992dd28b9fa89505e0c136104d372ea95305c1a9e9ff802cae7781c73bea53ac92378032986689c SHA512 49a34055a27efcee9fca1c0a50fe9061ae09945174a9076f76fce001621a3f8fa177ca0356313087a6d2b949d1d5149714036e89790868b984949721ce646685 DIST compiler-rt-sanitizers-4.0.1-patchset.tar.xz 2384 BLAKE2B 6f9eee711c83570767f0bb634d0f91c18ee7f2af93a478938b8d5b6ce6f2c2fbaadb7bd5c7ee94a14dc1834359a046187db6bc7005b7c2efa539325dc0701ad9 SHA512 72d7357b4c27bbf8fa8b34803ddea905a9f1054e8fc7bf99a4ead9dc00408989ea2709f04be9cf45a27eeb4b9386c89feeb25b53a84f3cac9739196b89813887 DIST compiler-rt-sanitizers-6.0.1-patchset.tar.xz 8820 BLAKE2B d53ca357e060d058c7f20c51e74684f4c032fdf3ccec4c9f227dc7a5757206f331b9eda25a72c5c66faf4c44b2cc63eb439bd21bdd55d37a93918ab428fd7cd4 SHA512 782a34c56134bd061da30c1f598ddb9e90cb34a4e4ef058fa9634f6da372fd8693ff5e6cf98b59700942273240f83052b89ee2736b22f4e19bc8b519fbec8cad DIST llvm-4.0.1.src.tar.xz 21065652 BLAKE2B 6327eed2d1feb108440f22d2581d1ff86c10a10c29793538d8d899c7e2dc83d3f7b147d3fd4bcce2bd2bf57c071b08c624aeafe40a3e7a3914506e7751727e6c SHA512 16adc39b34ddb628f81b171119a8e2a0e9138b25011e803ef0b688e2fbea116fc4953d3a1b61b90a98a75e33619f81566b7cb06a9a2ea4d04ac5e0eb303a2d1d DIST llvm-5.0.2.src.tar.xz 23451868 BLAKE2B b7082be2e4ad557b29b9f6869811f262adcf5c73d552faf91b339bede75cf5eab58afefa12fa779a38be71fe2b8f4ea297c3213ee4e8370cc01972c59249d91c SHA512 3588be5ed969c3f7f6f16f56a12a6af2814d3d3c960d4a36ffebb0446cc75f19220bccee7fc605f9b01f5d5c188a905a046193cc12dec42dd5922048b5c27fe1 DIST llvm-6.0.1.src.tar.xz 25306628 BLAKE2B 60232d4d22f8096b565cc8d81fea0639f24f14e8fc4f66ade69fa15479181f07f655f26dff3fa24bf105762b495da316c5c9352db234bd0af6b9c3fff6d4d881 SHA512 cbbb00eb99cfeb4aff623ee1a5ba075e7b5a76fc00c5f9f539ff28c108598f5708a0369d5bd92683def5a20c2fe60cab7827b42d628dbfcc79b57e0e91b84dd9 DIST llvm-7.0.1.src.tar.xz 28311056 BLAKE2B 737aa6144a415e41a4ff2c8bd5a727d6f14d7b1810c62cbefa5a25fe642c98cddf8a28e35c7e9783373aa3b96f5c0943229e229ad1b43e56e9ed6db0f27ab128 SHA512 ac43a3cb71a53deb55e3693653847cf20bf6f5d9056f224e6956c96d63bc59ebee9404f088eec9cabe65337b4607a905ef931354b373cf64e0004c6905a6b5df +DIST llvm-8.0.0rc2.src.tar.xz 30492444 BLAKE2B e7afd3b66e3eb204e07348f0bc77f0ae03d8e9581de4c94cba7c0b43b53f36ecd891c1272ce43ea6c78999fd404a7db105266a2eaca22975133571e1152961af SHA512 9d93197848e9472cc2fef2477897e4f4d74a79b17a164fd43446b0ffb327e7f484cf64f0c294d9a99707c0b46282eb0d16e6ceb5d2d568f25e4235f70ae3c5e7 EBUILD compiler-rt-sanitizers-4.0.1.ebuild 4942 BLAKE2B 384312216b7ec2d71928b22abbab61da0b6a09eca9c518b10a7be7416e12f53aa7160381eebb3c9ca070f5e432b10f7e248cd3380bd50a278758803c53c7cbfd SHA512 64142c2645ef2402f74ef4ee30ed5776f4629f1d0daa34683d50e3b45ce815682e00cb705a00014af524a25acd93fb41a7075f2402b3e73880823c258b01bb85 EBUILD compiler-rt-sanitizers-5.0.2.ebuild 5259 BLAKE2B d9fd342c98e1c7a9d124cd3149a4325625c8ab604cc9d3cbb01513b6ae2add2adbf246c616219f2fc0691d90aa26f5371e7cda8a18aec95243bd1d6ba7b25379 SHA512 8f82649dded359a5c6132b0b9cf211faefb3840850d71f43332cb8f1c250c830848aee7c5e7b1be2278f103420683b4e51bf493c563dead5a27781756a0c8015 EBUILD compiler-rt-sanitizers-6.0.1.ebuild 5453 BLAKE2B b643f95efc78b4aaa3ab4f05072397003d6e46793a763f91eb79f60c183d89e7265a53f6f96401dc87546bba5b8d21dd38dd0b8bceecdb652702685288465916 SHA512 c9b1dee74f1cbe7d6822589372389c2e3e6f3398211e26d83072dab290541797fa08c52c4c6ac581a59dac52fe5893a27812e5e46e175b9146f2c8348f170458 EBUILD compiler-rt-sanitizers-7.0.1.ebuild 5410 BLAKE2B b93a8907f25f9a6864556787b0e0b86b2fad39c19136e93baa9d73df5b5001f9539c27b5227eb5ae40fd7c34ca343ed45de1c2cd71f1f9753953bff04ced8c5c SHA512 b70f6f3ad6764d9d6244ec51a07a1948864db899213d68947c904161312b4ea450c7eba8f2c1aa3f9b0ab25bb7a1ac3d5650551c37f48abf0bfafc232cc3a7ad EBUILD compiler-rt-sanitizers-7.0.9999.ebuild 5335 BLAKE2B 2c1851ad178efe08bf96f342e1d2b02c269b395fd29a20532e54538060b09b6c9f7dda7a98f02bb50d309b57a69aff29ff06a5051a0aa28b24b40bba80cbf866 SHA512 7f3d61dfc5ac2087d6069d02cdd485367d0c8ec5b5e51384d1b1c6af4668548e5091ec05861569d4bbeb7bee149a5feb8621c8ba6370de5d250c59d37b8b81e5 -EBUILD compiler-rt-sanitizers-8.0.9999.ebuild 5118 BLAKE2B 9849fb97a4f8bf53f8650254fd51948e1e9247a988403246435548c99e6fec1796103b6dabb806973551608c8eab58e5ecba857587454cfd2816b79deeaed162 SHA512 485195703afba4a48ad3fec38542c65ecadbd29d79719be2c287e1de2cedf840d4c8ab67ddc0bde3e8954ecbfb1c35facad32faad222df77ed65e468a02863f5 -EBUILD compiler-rt-sanitizers-9999.ebuild 5093 BLAKE2B 8975ce0628079b44988b4cce3f33c1536fe8c88b8b76b6358b1a3de4056b693caa0b508e9ea0afbfaa57501abb6d5820cfd54ab8d1d11dd8b77f96452fcf50f8 SHA512 b6af187292c659305e04c4bb744a6735e9c5b6a3e9fd1eba5d0ed01a07751a18675bc5ec90e0eaf26af510342aa38a1e0bfb7724ee08bff97a1038f93824217f +EBUILD compiler-rt-sanitizers-8.0.0_rc2.ebuild 5143 BLAKE2B d4b4d83ad23c655d645009ef74907a909c37567049afb8caecf6ee6e825b67750a73d348e6e7d0ff92bccc85b835f17f7cc19690b747dbe2cc1ad608de5f1552 SHA512 8a50d7a9e602493c886da951d2c35be7a2450448753fd792f6e9662814913acb2e4788bbe650bdc878f58d26a158c7b542055dd258edfa77fc9a4b0b7097bf52 +EBUILD compiler-rt-sanitizers-8.0.9999.ebuild 5081 BLAKE2B 69176c9ec0a06b4658811c52614ffe5198d42f831565d1dbdb4c13952a8e54c36537c434c80921779d50d74ef5e43891bf7475d3c18bf7c7b28a619a98cc0ae1 SHA512 61a03679952d056befaad253692635aadb1c8d4253f33d853d2ba85bea956348416eae9b120b545d7adfbedfaeb49d98fb0ddcbfaf68519cb02d2d5e7822c3ef +EBUILD compiler-rt-sanitizers-9999.ebuild 5056 BLAKE2B ca4fe5a4e0c7312350bef6c59516a160e7d09b6a22e78271b4191cd2c333fad9acee63087a24ffaacdd8273d90f27a00c8fa88509c628d86f5dc17c7b33cfbe8 SHA512 052594371fe60aa93b71a848f9b964182fe631e96467958ee6897847f8684ae8d3297b88c05f6122f4d9975dee5ab5397cc5afa8d1158a885f7ce16af7a666a8 MISC metadata.xml 547 BLAKE2B 6f9d8b65c12797fd3d168e9b3948c604265db135bda5493d9f1d8b1d01fd73a79d07e5241afc3a7fa1672827fac23d3d9dc4d7ae42371a0de892a900c8c28269 SHA512 fb73a96b1ffbc7ff2fecfba35c9acd3e54ade0154016ae04423217f5c000eee2b0b821cc626908647551a0aa7b7f462d42d56cde3993ddd52248bc373b117c3e diff --git a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-8.0.0_rc2.ebuild b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-8.0.0_rc2.ebuild new file mode 100644 index 000000000000..d1c8f9787e0c --- /dev/null +++ b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-8.0.0_rc2.ebuild @@ -0,0 +1,171 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +: ${CMAKE_MAKEFILE_GENERATOR:=ninja} +# (needed due to CMAKE_BUILD_TYPE != Gentoo) +CMAKE_MIN_VERSION=3.7.0-r1 +PYTHON_COMPAT=( python2_7 ) + +inherit check-reqs cmake-utils flag-o-matic llvm \ + multiprocessing python-any-r1 + +MY_P=compiler-rt-${PV/_/}.src +LLVM_P=llvm-${PV/_/}.src + +DESCRIPTION="Compiler runtime libraries for clang (sanitizers & xray)" +HOMEPAGE="https://llvm.org/" +SRC_URI="https://prereleases.llvm.org/${PV/_//}/${MY_P}.tar.xz + test? ( https://prereleases.llvm.org/${PV/_//}/${LLVM_P}.tar.xz )" + +LICENSE="|| ( UoI-NCSA MIT )" +SLOT="${PV%_*}" +KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86 ~amd64-fbsd ~amd64-linux ~ppc-macos ~x64-macos ~x86-macos" +IUSE="+clang +libfuzzer +profile +sanitize test +xray elibc_glibc" +# FIXME: libfuzzer does not enable all its necessary dependencies +REQUIRED_USE="libfuzzer? ( || ( sanitize xray ) )" +RESTRICT="!test? ( test ) !clang? ( test )" + +CLANG_SLOT=${SLOT%%.*} +# llvm-6 for new lit options +DEPEND=" + >=sys-devel/llvm-6 + clang? ( sys-devel/clang ) + elibc_glibc? ( net-libs/libtirpc ) + test? ( + !=dev-python/lit-5[\${PYTHON_USEDEP}]") + =sys-devel/clang-${PV%_*}*:${CLANG_SLOT} + sys-libs/compiler-rt:${SLOT} ) + ${PYTHON_DEPS}" + +S=${WORKDIR}/${MY_P} + +# least intrusive of all +CMAKE_BUILD_TYPE=RelWithDebInfo + +check_space() { + if use test; then + local CHECKREQS_DISK_BUILD=11G + check-reqs_pkg_pretend + fi +} + +pkg_pretend() { + check_space +} + +pkg_setup() { + check_space + llvm_pkg_setup + python-any-r1_pkg_setup +} + +src_unpack() { + einfo "Unpacking ${MY_P}.tar.xz ..." + tar -xf "${DISTDIR}/${MY_P}.tar.xz" || die + + if use test; then + einfo "Unpacking parts of ${LLVM_P}.tar.xz ..." + tar -xf "${DISTDIR}/${LLVM_P}.tar.xz" \ + "${LLVM_P}"/utils/unittest || die + mv "${LLVM_P}" llvm || die + fi +} + +src_prepare() { + cmake-utils_src_prepare + + if use test; then + # remove tests that are (still) broken by new glibc + # https://bugs.llvm.org/show_bug.cgi?id=36065 + if use elibc_glibc && has_version '>=sys-libs/glibc-2.25'; then + rm test/lsan/TestCases/Linux/fork_and_leak.cc || die + fi + fi +} + +src_configure() { + # pre-set since we need to pass it to cmake + BUILD_DIR=${WORKDIR}/${P}_build + + if use clang; then + local -x CC=${CHOST}-clang + local -x CXX=${CHOST}-clang++ + strip-unsupported-flags + fi + + local mycmakeargs=( + -DCOMPILER_RT_INSTALL_PATH="${EPREFIX}/usr/lib/clang/${SLOT}" + # use a build dir structure consistent with install + # this makes it possible to easily deploy test-friendly clang + -DCOMPILER_RT_OUTPUT_DIR="${BUILD_DIR}/lib/clang/${SLOT}" + + -DCOMPILER_RT_INCLUDE_TESTS=$(usex test) + # built-ins installed by sys-libs/compiler-rt + -DCOMPILER_RT_BUILD_BUILTINS=OFF + -DCOMPILER_RT_BUILD_LIBFUZZER=$(usex libfuzzer) + -DCOMPILER_RT_BUILD_PROFILE=$(usex profile) + -DCOMPILER_RT_BUILD_SANITIZERS=$(usex sanitize) + -DCOMPILER_RT_BUILD_XRAY=$(usex xray) + ) + if use test; then + mycmakeargs+=( + -DLLVM_MAIN_SRC_DIR="${WORKDIR}/llvm" + -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" + -DLLVM_LIT_ARGS="-vv;-j;${LIT_JOBS:-$(makeopts_jobs "${MAKEOPTS}" "$(get_nproc)")}" + + # they are created during src_test() + -DCOMPILER_RT_TEST_COMPILER="${BUILD_DIR}/lib/llvm/${CLANG_SLOT}/bin/clang" + -DCOMPILER_RT_TEST_CXX_COMPILER="${BUILD_DIR}/lib/llvm/${CLANG_SLOT}/bin/clang++" + ) + + # same flags are passed for build & tests, so we need to strip + # them down to a subset supported by clang + CC=${EPREFIX}/usr/lib/llvm/${CLANG_SLOT}/bin/clang \ + CXX=${EPREFIX}/usr/lib/llvm/${CLANG_SLOT}/bin/clang++ \ + strip-unsupported-flags + fi + + if use prefix && [[ "${CHOST}" == *-darwin* ]] ; then + mycmakeargs+=( + # disable use of SDK for the system itself + -DDARWIN_macosx_CACHED_SYSROOT=/ + ) + fi + + cmake-utils_src_configure + + if use test; then + local sys_dir=( "${EPREFIX}"/usr/lib/clang/${SLOT}/lib/* ) + [[ -e ${sys_dir} ]] || die "Unable to find ${sys_dir}" + [[ ${#sys_dir[@]} -eq 1 ]] || die "Non-deterministic compiler-rt install: ${sys_dir[*]}" + + # copy clang over since resource_dir is located relatively to binary + # therefore, we can put our new libraries in it + mkdir -p "${BUILD_DIR}"/lib/{llvm/${CLANG_SLOT}/{bin,$(get_libdir)},clang/${SLOT}/include} || die + cp "${EPREFIX}"/usr/lib/llvm/${CLANG_SLOT}/bin/clang{,++} \ + "${BUILD_DIR}"/lib/llvm/${CLANG_SLOT}/bin/ || die + cp "${EPREFIX}"/usr/lib/clang/${SLOT}/include/*.h \ + "${BUILD_DIR}"/lib/clang/${SLOT}/include/ || die + cp "${sys_dir}"/*builtins*.a \ + "${BUILD_DIR}/lib/clang/${SLOT}/lib/${sys_dir##*/}/" || die + # we also need LLVMgold.so for gold-based tests + if [[ -f ${EPREFIX}/usr/lib/llvm/${CLANG_SLOT}/$(get_libdir)/LLVMgold.so ]]; then + ln -s "${EPREFIX}"/usr/lib/llvm/${CLANG_SLOT}/$(get_libdir)/LLVMgold.so \ + "${BUILD_DIR}"/lib/llvm/${CLANG_SLOT}/$(get_libdir)/ || die + fi + fi +} + +src_test() { + # respect TMPDIR! + local -x LIT_PRESERVES_TMP=1 + # disable sandbox to have it stop clobbering LD_PRELOAD + local -x SANDBOX_ON=0 + # wipe LD_PRELOAD to make ASAN happy + local -x LD_PRELOAD= + + cmake-utils_src_make check-all +} diff --git a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-8.0.9999.ebuild b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-8.0.9999.ebuild index e2589f02ba5d..0941bfc41077 100644 --- a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-8.0.9999.ebuild +++ b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-8.0.9999.ebuild @@ -82,8 +82,7 @@ src_prepare() { # remove tests that are (still) broken by new glibc # https://bugs.llvm.org/show_bug.cgi?id=36065 if use elibc_glibc && has_version '>=sys-libs/glibc-2.25'; then - rm test/lsan/TestCases/Linux/use_tls_dynamic.cc || die - rm test/msan/dtls_test.c || die + rm test/lsan/TestCases/Linux/fork_and_leak.cc || die fi fi } diff --git a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-9999.ebuild b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-9999.ebuild index 22e6a9b283cb..2247b480c7d9 100644 --- a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-9999.ebuild +++ b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-9999.ebuild @@ -81,8 +81,7 @@ src_prepare() { # remove tests that are (still) broken by new glibc # https://bugs.llvm.org/show_bug.cgi?id=36065 if use elibc_glibc && has_version '>=sys-libs/glibc-2.25'; then - rm test/lsan/TestCases/Linux/use_tls_dynamic.cc || die - rm test/msan/dtls_test.c || die + rm test/lsan/TestCases/Linux/fork_and_leak.cc || die fi fi } -- cgit v1.2.3