summaryrefslogtreecommitdiff
path: root/sys-devel/clang
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2019-06-02 21:45:28 +0100
committerV3n3RiX <venerix@redcorelinux.org>2019-06-02 21:45:28 +0100
commit2018227e9344edb9da15fc6a4a8298086cc2aa77 (patch)
treec18e1c09e605e94e2a1e93345ad25746cc9e14b9 /sys-devel/clang
parent6f8038813c460b4f0572d5ef595cdfa94af3a94d (diff)
gentoo resync : 02.06.2019
Diffstat (limited to 'sys-devel/clang')
-rw-r--r--sys-devel/clang/Manifest9
-rw-r--r--sys-devel/clang/clang-4.0.1.ebuild299
-rw-r--r--sys-devel/clang/files/4.0.1/0001-Frontend-Correct-values-of-ATOMIC_-_LOCK_FREE-to-mat.patch87
-rw-r--r--sys-devel/clang/files/4.0.1/0007-cmake-Support-stand-alone-Sphinx-doxygen-doc-build.patch64
-rw-r--r--sys-devel/clang/files/4.0.1/extra/0001-test-Fix-test-dependencies-when-using-installed-tool.patch48
-rw-r--r--sys-devel/clang/files/4.0.1/extra/0002-test-Fix-clang-library-dir-in-LD_LIBRARY_PATH-For-st.patch83
6 files changed, 0 insertions, 590 deletions
diff --git a/sys-devel/clang/Manifest b/sys-devel/clang/Manifest
index 4ab9c7881caa..ba1daaece28a 100644
--- a/sys-devel/clang/Manifest
+++ b/sys-devel/clang/Manifest
@@ -1,24 +1,17 @@
-AUX 4.0.1/0001-Frontend-Correct-values-of-ATOMIC_-_LOCK_FREE-to-mat.patch 4083 BLAKE2B aab48f1ed38bc7711363e86f9ff4f768bb4328eaa3e557c753f3b012ae13c08ffffafbb21645eb1d8a2f2d171362b28e2c41790eef8469c40d9be9c408307930 SHA512 2154b896d9a0ea50cec17c778ea62da525fc054fc24b0f59bebbad8c66ab17a0d607d87a3d0faa801770e74b8fc4bf3ede4103b6e344b7cc915d0dab16bbd31f
-AUX 4.0.1/0007-cmake-Support-stand-alone-Sphinx-doxygen-doc-build.patch 2214 BLAKE2B 6c1860f2ba0586d8b8b9b3d055f57ccda1037e100789a2a9e5bfb84a2b21e6ec088ef43314790b773c8d56ba5716944a0e7e34f0972992bdf5a3ec9573b77c71 SHA512 211203f373a882672a712b742b1e4562103fda0a0ac86d602576c105a07af335006da325817ec0ee1f21158a67d0246c7c7ea1d6b3d78abae543f8e69814f885
-AUX 4.0.1/extra/0001-test-Fix-test-dependencies-when-using-installed-tool.patch 1527 BLAKE2B 12692e8eb21a341ceb206f94e24a2585b7080adc2b7dcd6098f78654010dcebdaaccb180ee63b38ed49d2d3b5da34d3fb8e1147eb3515278c9d50ace4c982f96 SHA512 10e3f8a2b5fb1c16f38347f77bba3b171d9f6044c1f96c73368c9df2448cbad0c4a0147f1e1ec10b127ef5eb5a3187c4b56030ac4444269aad97e5ec3dac5f2b
-AUX 4.0.1/extra/0002-test-Fix-clang-library-dir-in-LD_LIBRARY_PATH-For-st.patch 3411 BLAKE2B a47f686dffa3e710435291670b8be7b99ea89d86092230f9acce328d24efa7ee43a5023b8deb482a497c1b54eec02c89291e4f10ad2c60382cc4ebe7c913981e SHA512 1ebfe7a6d06dd2991923cd1142c5c5b09ba2d06a3c7e0cbcb5b0f1d34aee57bf585941c0dd44ab331e9427828e5c63ea7475d673ccd3ec8617b99c59c56229a0
AUX 5.0.2/0001-Driver-Use-arch-type-to-find-compiler-rt-libraries-o.patch 6888 BLAKE2B e6d9907b05f99fb21008e7533f348348a3fe81249e6bcd0c473b82ba2dbb3651f7c27ba8c84053eb9c5832de1df4de7632971fc48d47aa9fff673f76e5688263 SHA512 6d1f35f39c15b11ce631477eefcca7ade90cb08e5992839273f97c339ef6bf0deecf9625fdacbad6e8cc61e4fd213e0e1c582c407ac051d99545962e310344fe
AUX 5.0.2/0002-test-Fix-clang-test-for-FreeBSD-and-NetBSD.patch 2846 BLAKE2B a5d3081767621f774b4c873611506a6ab9518acbab48839e142dc920b2059ac32258ffa0d9c04a6d8450d355680e98a62b406ac876785f9241ee4111f472b86d SHA512 c714adfa4bb62f89be07216a0e2601ba9729791228a42020d5069e821c629077df4581f82236c3dfb5dbcfb54ff124e7b4f1241512a03ae8e3f7ac40b27acd7d
AUX 5.0.2/extra/0001-Assume-the-shared-library-path-variable-is-LD_LIBRAR.patch 1376 BLAKE2B baa36d2b05118859ffc5af12e9b5a8ed0dac3c262736ef2bab5f89049267dca5a94e134b078c06f09cafcc678fb8adefcf84f940806b594777a1f05a1e216a80 SHA512 f4e31053c03429528fc193a4550784b21d60fa0487700c1f416952c5d92b71988ca481b53c00f95f0c8c39f5f30e9ddd5cc6bee5334294fd3e4df24b8a450e69
AUX 6.0.1/0002-test-Fix-Cross-DSO-CFI-Android-sanitizer-test-for-rt.patch 1256 BLAKE2B e71f32b08defa1ba59b574e9314e272107638676f1b1469a448efced144c680ffde4d76e34fa3fa5786859bf6e04050bd23150d7c0b98f8849f5d9355eacb646 SHA512 260096c1c7e6ba6f35537873cb6ba83f2271cb50446c50f6f1a5c88138c23508df16c99cac8664b5be0d56f2e0fe288f51a27424ff0b56c317d7a7e07562e0fc
AUX 6.0.1/darwin_prefix-include-paths.patch 690 BLAKE2B cfb96eb259fb7d557d215be08ea3babcae6dc1353171fad7f297f787d476d28768c7c1bbe6efc7404ea638f1dc6b4b36e1c17e141faf82be623bbd96d5e09118 SHA512 5f8ecabaf43853964bffeb3953b205bea7e8928fd53637d01842723ac8344e19cc639f6f06c199f2be88b73e60b6eab1987bc5ee7dfeaea5e710eacab90f3533
AUX 7.0.1/0001-clangd-Fix-detecting-atomics-in-stand-alone-builds.patch 1244 BLAKE2B 0a5f0b4af299ae49b13eac0e6ff06ce84264baf05bc09437b481830d4cfafab68ec2a3adf5814fcd8efbe91770e2dda0ce5fa5e10fcefc10d6fbe2c17ca067b6 SHA512 cec3d531b7d6121f7fc5da731d7d89d03a7d1a38e32abd5d7812790ffa62e6d3b9f18084983702203502905d447ad89bd4e2a7f3ca51ee7d696ebe623b035ac6
-DIST cfe-4.0.1.src.tar.xz 10933628 BLAKE2B bc1bb8875e83ccecd446a48cfa41f5c98a09d6ad24ff439a983f629711b4513b9c4bee4070f8df13b6b2a52d673b0706733a4c151ce5021a0233147debff14ac SHA512 936c9e1626b27e63a4fb11f3c0cb998eeaf9a520ad6e2bcd67cb4352e59e7781ecc700df79794f3fd70473d90b7e2ba418a39038eb0146b68e843f0705c1f964
DIST cfe-5.0.2.src.tar.xz 11459216 BLAKE2B 80d9b2ab70b00c0dfd5c5386a44e0c15d8252e6175c9da55a0519c4f9b8192e32e215110d7d3808225786e2c7f906f2dfbe11dd09bdf21574e99709ae237ed0b SHA512 9931afceb5569ad6caec85d506180c810f7fea94af8c997143b0a37cbf413fcea0d92520478610627eeee1efb65fde684066ace0dfcbbf7b61ecd709d22dd0b1
DIST cfe-6.0.1.src.tar.xz 11905772 BLAKE2B abb60e9f9827d1d8a24f0aaf8a1d1e32979293cc401258d230f93290e633645747fd0344af189ac7081b06be2cada503364e1e432b37110ade4b3578e40c7605 SHA512 f64ba9290059f6e36fee41c8f32bf483609d31c291fcd2f77d41fecfdf3c8233a5e23b93a1c73fed03683823bd6e72757ed993dd32527de3d5f2b7a64bb031b9
DIST cfe-7.1.0.src.tar.xz 12487872 BLAKE2B ca6ec9e45b94823de1dabf9e68f0c97cdd40b5d2a5e5e15d4b2393f6d7fbdee72a541b957cc22ce4cb726d8ee7190228320941d5713aeb59695673b9e9070ceb SHA512 1cd0b80f32aa4de1118c0c676ba96b1fc78b7ff929b01b6589dfe9b4669e599ac8cfb8f5a0abcd3487594193a7dec06b29530ec3fc03042c20a160f0477a79fd
DIST cfe-8.0.0.src.tar.xz 12868468 BLAKE2B 3cb96c95c4d9713feb7011e4f1ca24be3e7f6c9b458f6cd9e6905f99737312ca44cb701ed5871e47dd583145e5898d53a65c4cda6456af3d4ca31b670ed84409 SHA512 98e540222719716985e5d8439116e47469cb01201ea91d1da7e46cb6633da099688d9352c3b65e5c5f660cbbae353b3d79bb803fc66b3be663f2b04b1feed1c3
-DIST clang-tools-extra-4.0.1.src.tar.xz 581788 BLAKE2B 52ca89eda6fe1e0fbbdc46e17f4067f03a9a9440dcdcc98811651087d0c9ab24dfe3eefb0b80a32ec41abe0766cb3e47031de61c4cff02b7d0e08c8fd03e3faa SHA512 ea26d926f428e62e76cf8a073e63ffe05645f6592e05d7717d5c257908870ae9217727d3e1578227b14eda5937085872463f1a8e99970256179c68b8a92e69e0
DIST clang-tools-extra-5.0.2.src.tar.xz 646272 BLAKE2B 8a15a0c3ed9e8c31706d744017aa8be52616037790075c2314c3a613c9e1aa86b0b980c4e3bd9a775b234440f17436392196b41f1691ab25a33b432a25affb68 SHA512 241d85652e7c3ad5d77754ad9a694bddab3c14098067da4119223007c5a4a765d1cd7e7c7dba91666ccd5506f8703c82c9ee487f28249a00c2c4edbd0d1f2640
DIST clang-tools-extra-6.0.1.src.tar.xz 757256 BLAKE2B 1d91d7459a34e7251007af91db1803ee6d04f1ef3e0fcf134a7e0d1d3456b094a80339ee60db3f0bdd12961f3a05caee7edfc5c6b9c48d49cd55a5dc3c102c3a SHA512 cf29d117b6dabcb7a8e5f6dab5016ce5a5c8f475679001a43fd5c935f2c368f37cdef50aae2080a1e4524f647f6d83458d4a5dec5b45d03fb374f463caf7c3f5
DIST clang-tools-extra-7.1.0.src.tar.xz 901328 BLAKE2B 20865cf188cf08e4eae969d1083d9d69f57159c3dceb71e3e00a3f4dd96814b99e25fe633eb46801923d64cc9f884da24a417c21af71f0b3535bda0cce7d73da SHA512 8c22136324808b42601915e8163e06a90db078693f9e12369050bca6bab8cb971efaddcda82c5abf08e67ba7a5be1ac32e1bef0aff29a1b433e80eca8eba3e7b
DIST clang-tools-extra-8.0.0.src.tar.xz 1996156 BLAKE2B 26c839669ce4cf531a56e8527c9d507ce458861c00aaf563fa5e58cfa2fa3897d820643746802198c8e77c9e46fc8f4b833fc3746b32d8adc0d4a09dbe3ace7c SHA512 434e4cb7b76f89b0a0af25f05f32f2f2e8edb9e9f14547be845df75f5032c1d9dbf475be408bb989c476ec667c10af54a15d40e42559b05e52d24c5fd416b517
-DIST llvm-4.0.1.src.tar.xz 21065652 BLAKE2B 6327eed2d1feb108440f22d2581d1ff86c10a10c29793538d8d899c7e2dc83d3f7b147d3fd4bcce2bd2bf57c071b08c624aeafe40a3e7a3914506e7751727e6c SHA512 16adc39b34ddb628f81b171119a8e2a0e9138b25011e803ef0b688e2fbea116fc4953d3a1b61b90a98a75e33619f81566b7cb06a9a2ea4d04ac5e0eb303a2d1d
DIST llvm-5.0.2-manpages.tar.bz2 93977 BLAKE2B 8c5e8899e0df9d6037fb7d5c373de6492ccdc9fd2c26cc7dfbd8fb2b9e68418ca8fdf42cdc303c361e649cc6939bf5229cbad017bdccbd5d791e92752328252f SHA512 568615bce5a75d42e4b6d592557472d366d49a99f8e81be10ae679804f1fe674c7fd0bbdac09af44fc67ee5aa34c4ed2153c2767c536ac8e45dd15c811c92dcb
DIST llvm-5.0.2.src.tar.xz 23451868 BLAKE2B b7082be2e4ad557b29b9f6869811f262adcf5c73d552faf91b339bede75cf5eab58afefa12fa779a38be71fe2b8f4ea297c3213ee4e8370cc01972c59249d91c SHA512 3588be5ed969c3f7f6f16f56a12a6af2814d3d3c960d4a36ffebb0446cc75f19220bccee7fc605f9b01f5d5c188a905a046193cc12dec42dd5922048b5c27fe1
DIST llvm-6.0.1-manpages.tar.bz2 102656 BLAKE2B 9088ca0bdda69f63354e61b7495df54505d5db2504bc61860a7260343722ec8cdd5e937d0843263a5bf5077b9cf386c337fa127039b996bab10d2ca5c2caeb59 SHA512 c468e97a2d5610aee9e72cb795e4e65375a079d733550f05380230fb44ba0ed67d407ad06e2340b66f13d19c06583b657e8d01fcdca2146ae43964cea309e0b3
@@ -27,8 +20,6 @@ DIST llvm-7.1.0-manpages.tar.bz2 120786 BLAKE2B b52a7afe7c5c170894e910ef2c651a5f
DIST llvm-7.1.0.src.tar.xz 28313784 BLAKE2B b78d9a7fc5ef6e352e77d339e5c4eef5ccedf67c05e7abd949e72619aa8a5ed65e7e5e2008354be8e7916d75581719b99f34227838fcc86c5d0080913c2fb22c SHA512 a7dbd5693d1f2dae6b6e52893a100f9349cbfcfb25c5fdcad46364acbff0dbd3573f8fbc026c68eb9fd56335198aa94b866cc3dd7ea0cbd2cbfb5f8fe3444a7a
DIST llvm-8.0.0-manpages.tar.bz2 140542 BLAKE2B e6c58865ace0b8848ffe825e931a639daa5b22099317b3263acf8df4b8d5e1e97ed54a85b9241e6874b112c67114bda5617c3014c3bc1430c179bdf389e77269 SHA512 198f5bde8c610aa7953b325fc29c2bebe5c3d81469af6273975ed32cd739a9936813fca7399acc49809c322cf73fbdaa77a834f889bd78fe4672024965ea47fb
DIST llvm-8.0.0.src.tar.xz 30503732 BLAKE2B d89bdeb0ec7d885e49cfe5ae025da84f00502d409710c0807a3cdd58dbd47c50cf6a635593569483150f7f2ecb0de0310bd6785cb7625219bf9f6224a0d68e1c SHA512 1602343b451b964f5d8c2d6b0654d89384c80d45883498c5f0e2f4196168dd4a1ed2a4dadb752076020243df42ffe46cb31d82ffc145d8e5874163cbb9686a1f
-DIST llvm-manpages-4.0.1.tar.bz2 87981 BLAKE2B 79ffd254ee5c6e09159c954913ef820f74107d4fcea5e3ed82592dc36af8fdfbf1e850547ba8bfc20aa9a5ecdd26c50329e6a6d558ae3aa5475a930789ce3e01 SHA512 d5b3213567c25db58ef364d272314a79c311a80fc21d98c09a5540af45a8190a38f489228663fe9a9b63bf0f2b952c460c4196a8fc8d6f221619f6e7ed2fc415
-EBUILD clang-4.0.1.ebuild 9614 BLAKE2B ef0c63cfe38db99be4b9236d04eba4107092869e6c4dcc64e5a4cddf2d7931652607fce6292a8158ea9ff545ffb0296bca3670fd386e132c05239384190bbde9 SHA512 77045fdf3606b88c4f7f3021399c34b61876e80be7fa84ccb3a464e8caa19fcdbc896eb4f2d08d4f9f39dd7bdb03b9557135a710a00b92714ac2b29d6ba8e2d5
EBUILD clang-5.0.2.ebuild 10452 BLAKE2B 2f0af78f8cdaf88e643bccc474ff186db268307373cfe5130c09c2f07753c5eaa92220ab4f117ae1396ae5ff7cb13fb42765bcc44f7e0aa3decd1c7ce1c93dd2 SHA512 3dc65b62475430748da620f6dcd83943b5de88a28d666b321f107439a8cec88694285c6cf2cd90e0cca78b8f75d3c7af98ca70099500dfd1a59685aadb4fc630
EBUILD clang-6.0.1.ebuild 10272 BLAKE2B 7f179071a60dad773c4fedd95aae8c7529e84f891f6001808576bf6523baebe92eee713522c03accdcbeff76afc0c0a1329e159eef2cd307a2ff4ba6b598edc1 SHA512 508dc2b7c6758f63e931f83ec851ccf6e07433719e4e8dcb1f366c736bd22cb4fc19723dc2f05f7ff90f1828fc41a71d808d4f7f8332625134294516dc52ce79
EBUILD clang-7.1.0.ebuild 10355 BLAKE2B 6f698e87585d2ca5ec9f204022f13dbc9a44a91f78ddfb38e7981af84a19d619b9185124d627b6c00951e323393c864c12f32d60b465f635f1e70ec1f36a441f SHA512 e298008b3eaaf5efb51a04a6322adcbb6e7d16d8b4dba7d5c1ccd0e13ac2c9798b362c9be19087aa1b52a8cdb3ff291c91ed88d1cc7e8195312ee6da17d3e304
diff --git a/sys-devel/clang/clang-4.0.1.ebuild b/sys-devel/clang/clang-4.0.1.ebuild
deleted file mode 100644
index 469a613db91a..000000000000
--- a/sys-devel/clang/clang-4.0.1.ebuild
+++ /dev/null
@@ -1,299 +0,0 @@
-# Copyright 1999-2018 Gentoo Foundation
-# 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 cmake-utils flag-o-matic llvm multilib-minimal \
- python-single-r1 toolchain-funcs pax-utils versionator
-
-DESCRIPTION="C language family frontend for LLVM"
-HOMEPAGE="https://llvm.org/"
-SRC_URI="https://releases.llvm.org/${PV/_//}/cfe-${PV/_/}.src.tar.xz
- https://releases.llvm.org/${PV/_//}/clang-tools-extra-${PV/_/}.src.tar.xz
- !doc? ( https://dev.gentoo.org/~mgorny/dist/llvm/llvm-manpages-${PV}.tar.bz2 )
- test? ( https://releases.llvm.org/${PV/_//}/llvm-${PV/_/}.src.tar.xz )"
-
-# Keep in sync with sys-devel/llvm
-ALL_LLVM_TARGETS=( AArch64 AMDGPU ARM BPF Hexagon Lanai Mips MSP430
- NVPTX PowerPC RISCV Sparc SystemZ X86 XCore )
-ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" )
-LLVM_TARGET_USEDEPS=${ALL_LLVM_TARGETS[@]/%/?}
-
-LICENSE="UoI-NCSA"
-SLOT="$(get_major_version)"
-KEYWORDS="amd64 ~arm64 x86"
-IUSE="debug default-compiler-rt default-libcxx doc +static-analyzer
- test xml elibc_musl kernel_FreeBSD ${ALL_LLVM_TARGETS[*]}"
-
-RDEPEND="
- ~sys-devel/llvm-${PV}:${SLOT}=[debug=,${LLVM_TARGET_USEDEPS// /,},${MULTILIB_USEDEP}]
- static-analyzer? ( dev-lang/perl:* )
- xml? ( dev-libs/libxml2:2=[${MULTILIB_USEDEP}] )
- ${PYTHON_DEPS}"
-# configparser-3.2 breaks the build (3.3 or none at all are fine)
-DEPEND="${RDEPEND}
- doc? ( dev-python/sphinx )
- xml? ( virtual/pkgconfig )
- !!<dev-python/configparser-3.3.0.2
- ${PYTHON_DEPS}"
-RDEPEND="${RDEPEND}
- !<sys-devel/llvm-4.0.0_rc:0
- !sys-devel/clang:0"
-PDEPEND="
- ~sys-devel/clang-runtime-${PV}
- default-compiler-rt? ( =sys-libs/compiler-rt-${PV%_*}* )
- default-libcxx? ( >=sys-libs/libcxx-${PV} )"
-
-REQUIRED_USE="${PYTHON_REQUIRED_USE}
- || ( ${ALL_LLVM_TARGETS[*]} )"
-
-# We need extra level of indirection for CLANG_RESOURCE_DIR
-S=${WORKDIR}/x/y/cfe-${PV/_/}.src
-
-# least intrusive of all
-CMAKE_BUILD_TYPE=RelWithDebInfo
-
-# Multilib notes:
-# 1. ABI_* flags control ABIs libclang* is built for only.
-# 2. clang is always capable of compiling code for all ABIs for enabled
-# target. However, you will need appropriate crt* files (installed
-# e.g. by sys-devel/gcc and sys-libs/glibc).
-# 3. ${CHOST}-clang wrappers are always installed for all ABIs included
-# in the current profile (i.e. alike supported by sys-devel/gcc).
-#
-# Therefore: use sys-devel/clang[${MULTILIB_USEDEP}] only if you need
-# multilib clang* libraries (not runtime, not wrappers).
-
-pkg_setup() {
- LLVM_MAX_SLOT=${SLOT} llvm_pkg_setup
- python-single-r1_pkg_setup
-}
-
-src_unpack() {
- # create extra parent dirs for CLANG_RESOURCE_DIR
- mkdir -p x/y || die
- cd x/y || die
-
- default
-
- mv clang-tools-extra-*.src "${S}"/tools/extra || die
- if use test; then
- mv llvm-*.src "${WORKDIR}"/llvm || die
- fi
-}
-
-src_prepare() {
- # fix finding compiler-rt libs
- eapply "${FILESDIR}"/5.0.2/0001-Driver-Use-arch-type-to-find-compiler-rt-libraries-o.patch
-
- # fix stand-alone doc build
- eapply "${FILESDIR}"/4.0.1/0007-cmake-Support-stand-alone-Sphinx-doxygen-doc-build.patch
-
- # fix value of ATOMIC_*_LOCK_FREE
- # (backport, temporary reverted upstream because of FreeBSD issues)
- eapply "${FILESDIR}"/4.0.1/0001-Frontend-Correct-values-of-ATOMIC_-_LOCK_FREE-to-mat.patch
-
- cd tools/extra || die
- # fix stand-alone test build for extra tools
- eapply "${FILESDIR}"/4.0.1/extra/0001-test-Fix-test-dependencies-when-using-installed-tool.patch
- eapply "${FILESDIR}"/4.0.1/extra/0002-test-Fix-clang-library-dir-in-LD_LIBRARY_PATH-For-st.patch
- cd - >/dev/null || die
-
- # User patches
- cmake-utils_src_prepare
-}
-
-multilib_src_configure() {
- local llvm_version=$(llvm-config --version) || die
- local clang_version=$(get_version_component_range 1-3 "${llvm_version}")
-
- local mycmakeargs=(
- # ensure that the correct llvm-config is used
- -DLLVM_CONFIG="$(type -P "${CHOST}-llvm-config")"
- -DCMAKE_INSTALL_PREFIX="${EPREFIX}/usr/lib/llvm/${SLOT}"
- -DCMAKE_INSTALL_MANDIR="${EPREFIX}/usr/lib/llvm/${SLOT}/share/man"
- # relative to bindir
- -DCLANG_RESOURCE_DIR="../../../../lib/clang/${clang_version}"
-
- -DBUILD_SHARED_LIBS=ON
- -DLLVM_TARGETS_TO_BUILD="${LLVM_TARGETS// /;}"
- -DLLVM_BUILD_TESTS=$(usex test)
-
- # these are not propagated reliably, so redefine them
- -DLLVM_ENABLE_EH=ON
- -DLLVM_ENABLE_RTTI=ON
-
- -DCMAKE_DISABLE_FIND_PACKAGE_LibXml2=$(usex !xml)
- # libgomp support fails to find headers without explicit -I
- # furthermore, it provides only syntax checking
- -DCLANG_DEFAULT_OPENMP_RUNTIME=libomp
-
- # override default stdlib and rtlib
- -DCLANG_DEFAULT_CXX_STDLIB=$(usex default-libcxx libc++ "")
- -DCLANG_DEFAULT_RTLIB=$(usex default-compiler-rt compiler-rt "")
-
- -DCLANG_ENABLE_ARCMT=$(usex static-analyzer)
- -DCLANG_ENABLE_STATIC_ANALYZER=$(usex static-analyzer)
- )
- use test && mycmakeargs+=(
- -DLLVM_MAIN_SRC_DIR="${WORKDIR}/llvm"
- )
-
- if multilib_is_native_abi; then
- mycmakeargs+=(
- -DLLVM_BUILD_DOCS=$(usex doc)
- -DLLVM_ENABLE_SPHINX=$(usex doc)
- -DLLVM_ENABLE_DOXYGEN=OFF
-
- # workaround pthread
- -DPTHREAD_LIB=-pthread
- )
- use doc && mycmakeargs+=(
- -DCLANG_INSTALL_SPHINX_HTML_DIR="${EPREFIX}/usr/share/doc/${PF}/html"
- -DCLANG-TOOLS_INSTALL_SPHINX_HTML_DIR="${EPREFIX}/usr/share/doc/${PF}/tools-extra"
- -DSPHINX_WARNINGS_AS_ERRORS=OFF
- )
- else
- mycmakeargs+=(
- -DLLVM_TOOL_CLANG_TOOLS_EXTRA_BUILD=OFF
- )
- fi
-
- if [[ -n ${EPREFIX} ]]; then
- mycmakeargs+=(
- -DGCC_INSTALL_PREFIX="${EPREFIX}/usr"
- )
- fi
-
- if tc-is-cross-compiler; then
- [[ -x "/usr/bin/clang-tblgen" ]] \
- || die "/usr/bin/clang-tblgen not found or usable"
- mycmakeargs+=(
- -DCMAKE_CROSSCOMPILING=ON
- -DCLANG_TABLEGEN=/usr/bin/clang-tblgen
- )
- fi
-
- # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844
- use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG"
- cmake-utils_src_configure
-}
-
-multilib_src_compile() {
- cmake-utils_src_compile
-
- # provide a symlink for tests
- if [[ ! -L ${WORKDIR}/lib/clang ]]; then
- mkdir -p "${WORKDIR}"/lib || die
- ln -s "${BUILD_DIR}/$(get_libdir)/clang" "${WORKDIR}"/lib/clang || die
- fi
-}
-
-multilib_src_test() {
- # respect TMPDIR!
- local -x LIT_PRESERVES_TMP=1
- cmake-utils_src_make check-clang
- # clang-tidy requires [static-analyzer] and tests are not split
- # correctly, so they are all disabled when static-analyzer is off
- if multilib_is_native_abi && use static-analyzer; then
- cmake-utils_src_make check-clang-tools
- fi
-}
-
-src_install() {
- MULTILIB_WRAPPED_HEADERS=(
- /usr/include/clang/Config/config.h
- )
-
- multilib-minimal_src_install
-
- # Move runtime headers to /usr/lib/clang, where they belong
- mv "${ED%/}"/usr/include/clangrt "${ED%/}"/usr/lib/clang || die
- # move (remaining) wrapped headers back
- mv "${ED%/}"/usr/include "${ED%/}"/usr/lib/llvm/${SLOT}/include || die
-
- # Apply CHOST and version suffix to clang tools
- # note: we use two version components here (vs 3 in runtime path)
- local llvm_version=$(llvm-config --version) || die
- local clang_version=$(get_version_component_range 1-2 "${llvm_version}")
- local clang_full_version=$(get_version_component_range 1-3 "${llvm_version}")
- local clang_tools=( clang clang++ clang-cl clang-cpp )
- local abi i
-
- # cmake gives us:
- # - clang-X.Y
- # - clang -> clang-X.Y
- # - clang++, clang-cl, clang-cpp -> clang
- # we want to have:
- # - clang-X.Y
- # - clang++-X.Y, clang-cl-X.Y, clang-cpp-X.Y -> clang-X.Y
- # - clang, clang++, clang-cl, clang-cpp -> clang*-X.Y
- # also in CHOST variant
- for i in "${clang_tools[@]:1}"; do
- rm "${ED%/}/usr/lib/llvm/${SLOT}/bin/${i}" || die
- dosym "clang-${clang_version}" "/usr/lib/llvm/${SLOT}/bin/${i}-${clang_version}"
- dosym "${i}-${clang_version}" "/usr/lib/llvm/${SLOT}/bin/${i}"
- done
-
- # now create target symlinks for all supported ABIs
- for abi in $(get_all_abis); do
- local abi_chost=$(get_abi_CHOST "${abi}")
- for i in "${clang_tools[@]}"; do
- dosym "${i}-${clang_version}" \
- "/usr/lib/llvm/${SLOT}/bin/${abi_chost}-${i}-${clang_version}"
- dosym "${abi_chost}-${i}-${clang_version}" \
- "/usr/lib/llvm/${SLOT}/bin/${abi_chost}-${i}"
- done
- done
-
- # Remove unnecessary headers on FreeBSD, bug #417171
- if use kernel_FreeBSD; then
- rm "${ED}"usr/lib/clang/${clang_full_version}/include/{std,float,iso,limits,tgmath,varargs}*.h || die
- fi
-}
-
-multilib_src_install() {
- cmake-utils_src_install
-
- # move headers to /usr/include for wrapping & ABI mismatch checks
- # (also drop the version suffix from runtime headers)
- rm -rf "${ED%/}"/usr/include || die
- mv "${ED%/}"/usr/lib/llvm/${SLOT}/include "${ED%/}"/usr/include || die
- mv "${ED%/}"/usr/lib/llvm/${SLOT}/$(get_libdir)/clang "${ED%/}"/usr/include/clangrt || die
-}
-
-multilib_src_install_all() {
- python_fix_shebang "${ED}"
- if use static-analyzer; then
- python_optimize "${ED}"usr/lib/llvm/${SLOT}/share/scan-view
- fi
-
- # install pre-generated manpages
- if ! use doc; then
- insinto "/usr/lib/llvm/${SLOT}/share/man/man1"
- doins "${WORKDIR}/x/y/llvm-manpages-${PV}/clang"/*.1
- fi
-
- docompress "/usr/lib/llvm/${SLOT}/share/man"
- # match 'html' non-compression
- use doc && docompress -x "/usr/share/doc/${PF}/tools-extra"
- # +x for some reason; TODO: investigate
- use static-analyzer && fperms a-x "/usr/lib/llvm/${SLOT}/share/man/man1/scan-build.1"
-}
-
-pkg_postinst() {
- if [[ ${ROOT} == / && -f ${EPREFIX}/usr/share/eselect/modules/compiler-shadow.eselect ]] ; then
- eselect compiler-shadow update all
- fi
-}
-
-pkg_postrm() {
- if [[ ${ROOT} == / && -f ${EPREFIX}/usr/share/eselect/modules/compiler-shadow.eselect ]] ; then
- eselect compiler-shadow clean all
- fi
-}
diff --git a/sys-devel/clang/files/4.0.1/0001-Frontend-Correct-values-of-ATOMIC_-_LOCK_FREE-to-mat.patch b/sys-devel/clang/files/4.0.1/0001-Frontend-Correct-values-of-ATOMIC_-_LOCK_FREE-to-mat.patch
deleted file mode 100644
index f52d445eb05b..000000000000
--- a/sys-devel/clang/files/4.0.1/0001-Frontend-Correct-values-of-ATOMIC_-_LOCK_FREE-to-mat.patch
+++ /dev/null
@@ -1,87 +0,0 @@
-From f1ea62e93cba334828c427146cc2ca7718a9ffb3 Mon Sep 17 00:00:00 2001
-From: Michal Gorny <mgorny@gentoo.org>
-Date: Mon, 9 Jan 2017 20:54:20 +0000
-Subject: [PATCH] [Frontend] Correct values of ATOMIC_*_LOCK_FREE to match
- builtin
-
-Correct the logic used to set ATOMIC_*_LOCK_FREE preprocessor macros not
-to rely on the ABI alignment of types. Instead, just assume all those
-types are aligned correctly by default since clang uses safe alignment
-for _Atomic types even if the underlying types are aligned to a lower
-boundary by default.
-
-For example, the 'long long' and 'double' types on x86 are aligned to
-32-bit boundary by default. However, '_Atomic long long' and '_Atomic
-double' are aligned to 64-bit boundary, therefore satisfying
-the requirements of lock-free atomic operations.
-
-This fixes PR #19355 by correcting the value of
-__GCC_ATOMIC_LLONG_LOCK_FREE on x86, and therefore also fixing
-the assumption made in libc++ tests. This also fixes PR #30581 by
-applying a consistent logic between the functions used to implement
-both interfaces.
-
-Differential Revision: https://reviews.llvm.org/D28213
-
-git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@291477 91177308-0d34-0410-b5e6-96231b3b80d8
----
- lib/Frontend/InitPreprocessor.cpp | 10 ++++------
- test/Sema/atomic-ops.c | 4 ----
- 2 files changed, 4 insertions(+), 10 deletions(-)
-
-diff --git a/lib/Frontend/InitPreprocessor.cpp b/lib/Frontend/InitPreprocessor.cpp
-index 17603ada11..4502c92499 100644
---- a/lib/Frontend/InitPreprocessor.cpp
-+++ b/lib/Frontend/InitPreprocessor.cpp
-@@ -286,12 +286,12 @@ static void DefineFastIntType(unsigned TypeWidth, bool IsSigned,
-
- /// Get the value the ATOMIC_*_LOCK_FREE macro should have for a type with
- /// the specified properties.
--static const char *getLockFreeValue(unsigned TypeWidth, unsigned TypeAlign,
-- unsigned InlineWidth) {
-+static const char *getLockFreeValue(unsigned TypeWidth, unsigned InlineWidth) {
- // Fully-aligned, power-of-2 sizes no larger than the inline
- // width will be inlined as lock-free operations.
-- if (TypeWidth == TypeAlign && (TypeWidth & (TypeWidth - 1)) == 0 &&
-- TypeWidth <= InlineWidth)
-+ // Note: we do not need to check alignment since _Atomic(T) is always
-+ // appropriately-aligned in clang.
-+ if ((TypeWidth & (TypeWidth - 1)) == 0 && TypeWidth <= InlineWidth)
- return "2"; // "always lock free"
- // We cannot be certain what operations the lib calls might be
- // able to implement as lock-free on future processors.
-@@ -881,7 +881,6 @@ static void InitializePredefinedMacros(const TargetInfo &TI,
- #define DEFINE_LOCK_FREE_MACRO(TYPE, Type) \
- Builder.defineMacro("__GCC_ATOMIC_" #TYPE "_LOCK_FREE", \
- getLockFreeValue(TI.get##Type##Width(), \
-- TI.get##Type##Align(), \
- InlineWidthBits));
- DEFINE_LOCK_FREE_MACRO(BOOL, Bool);
- DEFINE_LOCK_FREE_MACRO(CHAR, Char);
-@@ -894,7 +893,6 @@ static void InitializePredefinedMacros(const TargetInfo &TI,
- DEFINE_LOCK_FREE_MACRO(LLONG, LongLong);
- Builder.defineMacro("__GCC_ATOMIC_POINTER_LOCK_FREE",
- getLockFreeValue(TI.getPointerWidth(0),
-- TI.getPointerAlign(0),
- InlineWidthBits));
- #undef DEFINE_LOCK_FREE_MACRO
- }
-diff --git a/test/Sema/atomic-ops.c b/test/Sema/atomic-ops.c
-index 8ebf3eaed4..d3ebdf67db 100644
---- a/test/Sema/atomic-ops.c
-+++ b/test/Sema/atomic-ops.c
-@@ -14,11 +14,7 @@ _Static_assert(__GCC_ATOMIC_WCHAR_T_LOCK_FREE == 2, "");
- _Static_assert(__GCC_ATOMIC_SHORT_LOCK_FREE == 2, "");
- _Static_assert(__GCC_ATOMIC_INT_LOCK_FREE == 2, "");
- _Static_assert(__GCC_ATOMIC_LONG_LOCK_FREE == 2, "");
--#ifdef __i386__
--_Static_assert(__GCC_ATOMIC_LLONG_LOCK_FREE == 1, "");
--#else
- _Static_assert(__GCC_ATOMIC_LLONG_LOCK_FREE == 2, "");
--#endif
- _Static_assert(__GCC_ATOMIC_POINTER_LOCK_FREE == 2, "");
-
- _Static_assert(__c11_atomic_is_lock_free(1), "");
---
-2.12.0
-
diff --git a/sys-devel/clang/files/4.0.1/0007-cmake-Support-stand-alone-Sphinx-doxygen-doc-build.patch b/sys-devel/clang/files/4.0.1/0007-cmake-Support-stand-alone-Sphinx-doxygen-doc-build.patch
deleted file mode 100644
index 0ecd5bc0e8c1..000000000000
--- a/sys-devel/clang/files/4.0.1/0007-cmake-Support-stand-alone-Sphinx-doxygen-doc-build.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-From 8dd12df445c9a35f7b1c0202eb7c74b954b0980d Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org>
-Date: Sun, 21 Aug 2016 23:31:55 +0200
-Subject: [PATCH 7/7] cmake: Support stand-alone Sphinx & doxygen doc build
-
-Copy the necessary options and configuration checks from LLVM to clang,
-to support stand-alone documentation builds.
-
-Patch: https://reviews.llvm.org/D23758
----
- CMakeLists.txt | 37 +++++++++++++++++++++++++++++++++++++
- 1 file changed, 37 insertions(+)
-
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 8ed8c10..3f34d8c 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -162,6 +162,43 @@ Please install Python or specify the PYTHON_EXECUTABLE CMake variable.")
- endif()
- endif()
-
-+ option (LLVM_BUILD_DOCS "Build the llvm documentation." OFF)
-+ option (LLVM_INCLUDE_DOCS "Generate build targets for llvm documentation." ON)
-+ option (LLVM_ENABLE_DOXYGEN "Use doxygen to generate llvm API documentation." OFF)
-+ option (LLVM_ENABLE_SPHINX "Use Sphinx to generate llvm documentation." OFF)
-+
-+ if (LLVM_ENABLE_DOXYGEN)
-+ message(STATUS "Doxygen enabled.")
-+ find_package(Doxygen REQUIRED)
-+
-+ if (DOXYGEN_FOUND)
-+ # If we find doxygen and we want to enable doxygen by default create a
-+ # global aggregate doxygen target for generating llvm and any/all
-+ # subprojects doxygen documentation.
-+ if (LLVM_BUILD_DOCS)
-+ add_custom_target(doxygen ALL)
-+ endif()
-+
-+ option(LLVM_DOXYGEN_EXTERNAL_SEARCH "Enable doxygen external search." OFF)
-+ if (LLVM_DOXYGEN_EXTERNAL_SEARCH)
-+ set(LLVM_DOXYGEN_SEARCHENGINE_URL "" CACHE STRING "URL to use for external search.")
-+ set(LLVM_DOXYGEN_SEARCH_MAPPINGS "" CACHE STRING "Doxygen Search Mappings")
-+ endif()
-+ endif()
-+ else()
-+ message(STATUS "Doxygen disabled.")
-+ endif()
-+
-+ if (LLVM_ENABLE_SPHINX)
-+ message(STATUS "Sphinx enabled.")
-+ find_package(Sphinx REQUIRED)
-+ if (LLVM_BUILD_DOCS)
-+ add_custom_target(sphinx ALL)
-+ endif()
-+ else()
-+ message(STATUS "Sphinx disabled.")
-+ endif()
-+
- set( CLANG_BUILT_STANDALONE 1 )
- set(BACKEND_PACKAGE_STRING "LLVM ${LLVM_PACKAGE_VERSION}")
- else()
---
-2.9.3
-
diff --git a/sys-devel/clang/files/4.0.1/extra/0001-test-Fix-test-dependencies-when-using-installed-tool.patch b/sys-devel/clang/files/4.0.1/extra/0001-test-Fix-test-dependencies-when-using-installed-tool.patch
deleted file mode 100644
index 3779bc620314..000000000000
--- a/sys-devel/clang/files/4.0.1/extra/0001-test-Fix-test-dependencies-when-using-installed-tool.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From f1355920fbe819c5b1f5a870fc76cffcdd6328f0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org>
-Date: Fri, 10 Feb 2017 22:44:53 +0100
-Subject: [PATCH 1/2] [test] Fix test dependencies when using installed tools
-
-Use the LLVM_UTILS_PROVIDED variable to determine whether test tool
-dependencies should be exposed for clang-tools-extra tests. If clang is
-being built stand-alone and LLVM test tools (FileCheck, count and not)
-are installed, the top-level CMakeLists.txt of clang sets this variable
-to indicate that they will not be built as a part of this build,
-and therefore no dependencies should be emitted for them. This fixes
-the dependency errors when building clang stand-alone with tests
-enabled.
----
- test/CMakeLists.txt | 10 +++++++---
- 1 file changed, 7 insertions(+), 3 deletions(-)
-
-diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
-index a852ef60..c26bd5c4 100644
---- a/test/CMakeLists.txt
-+++ b/test/CMakeLists.txt
-@@ -31,9 +31,6 @@ if(CLANG_TOOLS_TEST_USE_VG)
- endif()
-
- set(CLANG_TOOLS_TEST_DEPS
-- # Base line deps.
-- FileCheck count not
--
- # clang-tidy tests require it.
- clang-headers
-
-@@ -58,6 +55,13 @@ set(CLANG_TOOLS_TEST_DEPS
- ExtraToolsUnitTests
- )
-
-+if(NOT LLVM_UTILS_PROVIDED)
-+ list(APPEND CLANG_TOOLS_TEST_DEPS
-+ # Base line deps.
-+ FileCheck count not
-+ )
-+endif()
-+
- add_lit_testsuite(check-clang-tools "Running the Clang extra tools' regression tests"
- ${CMAKE_CURRENT_BINARY_DIR}
- DEPENDS ${CLANG_TOOLS_TEST_DEPS}
---
-2.12.0
-
diff --git a/sys-devel/clang/files/4.0.1/extra/0002-test-Fix-clang-library-dir-in-LD_LIBRARY_PATH-For-st.patch b/sys-devel/clang/files/4.0.1/extra/0002-test-Fix-clang-library-dir-in-LD_LIBRARY_PATH-For-st.patch
deleted file mode 100644
index 22f6d5685f33..000000000000
--- a/sys-devel/clang/files/4.0.1/extra/0002-test-Fix-clang-library-dir-in-LD_LIBRARY_PATH-For-st.patch
+++ /dev/null
@@ -1,83 +0,0 @@
-From f3ff810e81c35133f6a7e463d860bcd4ca30be84 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org>
-Date: Sun, 19 Feb 2017 12:13:04 +0100
-Subject: [PATCH 2/2] [test] Fix clang library dir in LD_LIBRARY_PATH For
- stand-alone build
-
-Prepend the clang library directory (determined using SHLIBDIR, alike
-in clang) to the LD_LIBRARY_PATH to ensure that just-built clang
-libraries will be used instead of a previous installed version.
-
-When a stand-alone build is performed, LLVM_LIBS_DIR contains the path
-to installed LLVM library directory. The same directory frequently
-contains a previously installed version of clang. SHLIBDIR, on the other
-hand, is always the build-tree directory, and therefore contains
-the freshly built clang libraries.
-
-In a non-stand-alone build, both paths will be the same and therefore
-including them both will not cause any issues.
----
- test/Unit/lit.cfg | 9 ++++++---
- test/lit.cfg | 5 ++++-
- test/lit.site.cfg.in | 1 +
- 3 files changed, 11 insertions(+), 4 deletions(-)
-
-diff --git a/test/Unit/lit.cfg b/test/Unit/lit.cfg
-index ff70123c..3a1da187 100644
---- a/test/Unit/lit.cfg
-+++ b/test/Unit/lit.cfg
-@@ -41,14 +41,17 @@ elif platform.system() == 'Windows':
- shlibpath_var = 'PATH'
-
- # Point the dynamic loader at dynamic libraries in 'lib'.
-+shlibdir = getattr(config, 'shlibdir', None)
-+if not shlibdir:
-+ lit_config.fatal('No shlibdir set!')
- llvm_libs_dir = getattr(config, 'llvm_libs_dir', None)
- if not llvm_libs_dir:
- lit_config.fatal('No LLVM libs dir set!')
--shlibpath = os.path.pathsep.join((llvm_libs_dir,
-+shlibpath = os.path.pathsep.join((shlibdir, llvm_libs_dir,
- config.environment.get(shlibpath_var,'')))
-
- # Win32 seeks DLLs along %PATH%.
--if sys.platform in ['win32', 'cygwin'] and os.path.isdir(config.shlibdir):
-- shlibpath = os.path.pathsep.join((config.shlibdir, shlibpath))
-+if sys.platform in ['win32', 'cygwin'] and os.path.isdir(shlibdir):
-+ shlibpath = os.path.pathsep.join((shlibdir, shlibpath))
-
- config.environment[shlibpath_var] = shlibpath
-diff --git a/test/lit.cfg b/test/lit.cfg
-index bb592936..0e7de849 100644
---- a/test/lit.cfg
-+++ b/test/lit.cfg
-@@ -99,10 +99,13 @@ if clang_tools_binary_dir is not None:
- clang_tools_dir, llvm_tools_dir, config.environment['PATH']))
- config.environment['PATH'] = path
-
-+ clang_libs_dir = getattr(config, 'clang_libs_dir', None)
-+ if not clang_libs_dir:
-+ lit_config.fatal('No Clang libs dir set!')
- llvm_libs_dir = getattr(config, 'llvm_libs_dir', None)
- if not llvm_libs_dir:
- lit_config.fatal('No LLVM libs dir set!')
-- path = os.path.pathsep.join((llvm_libs_dir,
-+ path = os.path.pathsep.join((clang_libs_dir, llvm_libs_dir,
- config.environment.get('LD_LIBRARY_PATH','')))
- config.environment['LD_LIBRARY_PATH'] = path
-
-diff --git a/test/lit.site.cfg.in b/test/lit.site.cfg.in
-index dfd0164c..f310b59a 100644
---- a/test/lit.site.cfg.in
-+++ b/test/lit.site.cfg.in
-@@ -7,6 +7,7 @@ config.llvm_libs_dir = "@LLVM_LIBS_DIR@"
- config.lit_tools_dir = "@LLVM_LIT_TOOLS_DIR@"
- config.clang_tools_binary_dir = "@CLANG_TOOLS_BINARY_DIR@"
- config.clang_tools_dir = "@CLANG_TOOLS_DIR@"
-+config.clang_libs_dir = "@SHLIBDIR@"
- config.python_executable = "@PYTHON_EXECUTABLE@"
- config.target_triple = "@TARGET_TRIPLE@"
-
---
-2.12.0
-