diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2021-09-25 20:21:45 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2021-09-25 20:21:45 +0100 |
commit | c719fdcee603a5a706a45d10cb598762d56a727d (patch) | |
tree | 620cbf137661399a3fb1eff92914204f9a970713 /sys-devel/llvm | |
parent | cc4618c9ba3d974948ebf340b542d8cb01db2f55 (diff) |
gentoo resync : 25.09.2021
Diffstat (limited to 'sys-devel/llvm')
-rw-r--r-- | sys-devel/llvm/Manifest | 11 | ||||
-rw-r--r-- | sys-devel/llvm/llvm-13.0.0.9999.ebuild | 22 | ||||
-rw-r--r-- | sys-devel/llvm/llvm-13.0.0_rc2.ebuild | 22 | ||||
-rw-r--r-- | sys-devel/llvm/llvm-13.0.0_rc3.ebuild | 22 | ||||
-rw-r--r-- | sys-devel/llvm/llvm-13.0.0_rc4.ebuild | 511 | ||||
-rw-r--r-- | sys-devel/llvm/llvm-14.0.0.9999.ebuild | 22 |
6 files changed, 542 insertions, 68 deletions
diff --git a/sys-devel/llvm/Manifest b/sys-devel/llvm/Manifest index 64ac38a38794..320e19d9135d 100644 --- a/sys-devel/llvm/Manifest +++ b/sys-devel/llvm/Manifest @@ -6,17 +6,20 @@ DIST llvm-gentoo-patchset-11.1.0-1.tar.xz 4032 BLAKE2B e69138a422e315b31a3d9c11f DIST llvm-gentoo-patchset-12.0.1.tar.xz 5280 BLAKE2B 963d005bc7b636570be90eb841ac5bcaeb927538cc7de27683167111a17d6496677c7517de2ecfaf14b5d8ac22bad357be490b8a2ed9aba502fd5f447ecc99e9 SHA512 fc7c38e671555751650299c3a8bee44d5c7f26e11b68d5538c507fb7fe9ff2d349bdcd43bce90a448a747f082d523b3849d6bcda5e3ae2e998edcb926d6aa249 DIST llvm-gentoo-patchset-13.0.0-rc2.tar.xz 5556 BLAKE2B e6c7ecfe8f842edc4d4f30a20c66973519182ecb46e21fb20b6c5fcb6d54cdef830fcb120a405b77f1332e3557acbbbbfa99170b20d17f137e0a63b2d0dc1258 SHA512 ddeaf1d07f0ba893ce93e5fe1eff1c0716769a7879fc503c397f4db7becb363f94747f59b6d53c204df73a93954fb0ca5aae6ad544ce55c964c4bf441a410cd2 DIST llvm-gentoo-patchset-13.0.0-rc3.tar.xz 5012 BLAKE2B 5399feeffe73e8fbd099c8058f1cc41e2fcb2feb446acc1394589c0397167786895d328d45ff481fb30605f215774b9e51e332124c0b071e969a2f01c5943c04 SHA512 d4fb2b08e253d9fa89070045282b4309ca9938011bf7f9b5364cc69c5030ff9353abb1624895b4bfeef2cd8e2f8c9b9f93fc8196f98dc0970457bca7787270c9 +DIST llvm-gentoo-patchset-13.0.0-rc4.tar.xz 5016 BLAKE2B 021ba4e67904e4cf4dfdf1ecfc1cd1cc860c2f43db97e04c40ca7d95567f6235a27a2a919083c58b89b269eefa2d751cb9c324bda6518c22e9fc01007936a520 SHA512 dce61179dffafc5992fb0e18314bba2d5fbf2f0470a491bc1ffc036274b65d0a1de741b23e2de32e873250c856a53707e06f8c560bd29f8a54a6ae0c74267f43 DIST llvm-gentoo-patchset-9999-1.tar.xz 4032 BLAKE2B b9413484dafed8ae0c68c2c164b45fd07bb8d5d0898f03abe118fd2120ffcb1fb6c949de9649a97c2e8105f24b9d131a725c67c0a502ca4d4d192c1a0d65f49d SHA512 e64449eeaf756c5bd945109937b84ba4bd8a015222bd792d39cf3947871e87571a4ca57814790e51544cb05ad4c2d1f044e818e4caaac7c2e2a02cb1aa290fcc DIST llvmorg-10.0.1.tar.gz 120880730 BLAKE2B 30f19f56c4d1f6abcda5fec76256219d1e3c8a6ff1a1f152f94bfe362c07884339fe571ff7fe903ed3b3deb150b2fa868c387887a0dea2930dc08b81db71a5b1 SHA512 48078fff9293a87f1a973f3348f79506f04c3da774295f5eb67d74dd2d1aa94f0973f8ced3f4ab9e8339902071f82c603b43d5608ad7227046c4da769c5d2151 DIST llvmorg-11.1.0.tar.gz 122776532 BLAKE2B ca842ff4afff8f44c82b5e7383962a9c45ca1c93b64fa4c6ebcd70a1d3849dbad2b8e4e24fba02d144c6266d7fab3607ebc6999b28c229cb35256cf40f26a985 SHA512 9a8ce022a935eed42fa71a224f2a207122aadcbef58ee855fdb4825f879e7d028e4dcff22c19b9d336db1c8bf63fb84372d44981acf84615f757e54306c92b81 DIST llvmorg-12.0.1.tar.gz 134259748 BLAKE2B f41de787bc73ff2edfda1b22cc8602be6f65f37dd9e4c8888533cfa8c3ccdcf4f108aaab9de23ab0ab987966eb160f2a553a0bdff99461e71ddd5bfcd086090d SHA512 6eb0dc18e2c25935fabfdfc48b0114be0939158dfdef7b85b395fe2e71042672446af0e68750aae003c9847d10d1f63316fe95d3df738d18f249174292b1b9e1 DIST llvmorg-13.0.0-rc2.tar.gz 147267736 BLAKE2B 153bf7320f2aa911112d366ffc79f7110cb04f135c2a8b176c263f0a75eb768206d9bd462893d45504b0e58aa9e127fdcafb02300eab1666e4616aa654d457dd SHA512 a01baf3eaa02f02af42bfcf6dcf24f166351bf1c09601495617c81e41def23210573bad40a344270f40c5deb881d06863536abac2a6481930766a6a56335fb44 DIST llvmorg-13.0.0-rc3.tar.gz 147281901 BLAKE2B 640065a2f32dc48edf084d776cb6b950fae86c2a204999e2eec67f93b57615df40adec19785099b0ef2fe11837c3304794ec3585289a5b5051a557618c63c749 SHA512 1401d5a4d6bb5c930d74b9cfbc8e792872f721aab7d7f0c819e2ba5cf47fb818d160c1f71784fba69827f3c9b7414aa91a585d2b813c1851b4799f9d62cebc46 +DIST llvmorg-13.0.0-rc4.tar.gz 147286367 BLAKE2B a43c54b8bb379b0374f99ae07066d7ba4ae2a83dfdb61390101c736f91dc44aa07a88778551aaaf903033562b2a0a863ea6b27392b700c9cddc74e2c7899cad1 SHA512 8ccaaea21ec4fe3c4b4446d3a7cae36a47ed196f407d341da45824bcefefffd3c412c0c5c27670ceaba1458bc53107273f9d3aec2de261b6b82c6d209b45b14d EBUILD llvm-10.0.1.ebuild 11490 BLAKE2B 40960dd1109655157b04396283d704ea1a0af35ffd09ec9bab2718d62fde888508246ea77a473cd7512c1818b5a3a8d7b72e5786d64faf43bd42ff823b765e22 SHA512 75767e94d55ca1f9f7a769abfc0c916388e69ccd51620c8083f8bb184bf9649d2b9c75efaed46d96f8e0932cb3e6beb71d51a3b1565243218a3efd5144238296 EBUILD llvm-11.1.0.ebuild 12504 BLAKE2B 7f22ab387fab31e11d554667b1b183f5b66203f601096c130642500f877f2af473b31a0cba96da93d9c85d50e2fbafb7f46a0ff6bf2f96a0bd41266ddc04dc8f SHA512 716b8474077279b821140d2defa5f1dd5b2ab7cf09aeb27907410a184a701ecbf99f545622e68d0a81a762c3b5cbc6ff3b30415a331d38dac8fb72f37a3147bf EBUILD llvm-12.0.1.ebuild 12620 BLAKE2B 34f9ebd56f6381d3d88a82d98abc9cbec2c8ec7a35bf2fc297f9d82afb3927d991baecc95c3d76db35d1f47d171ffd6be0b1ac953b1c6605866b94aeeae9c9d3 SHA512 fbe11d194f5c049f1bfbcfb606351282e2cf5c74a58a1980f5b9b663d3d811bc6906e084d557e4169b0c15017e9d4c0c73c842116547e60946d883b91f38aae9 -EBUILD llvm-13.0.0.9999.ebuild 12589 BLAKE2B 44bca6c287c2d804f6701a8ac8a953624e8418d1ead94450b7b8b5f0ff5192bf6c027ca4f290c8a0e6bc96badd50be68e3fa2765f8cc535ddbd2bd8a39530b2d SHA512 b3e11ab52ca7309933d7cb66e3cb5c85c934c5e417e271d3c8c14879a1afc190b7a49f68a5abc2d847f1883a17f85cd3e9ab42b358b530424d4314707063fce9 -EBUILD llvm-13.0.0_rc2.ebuild 12593 BLAKE2B b1a89a4d89292e48f7bfb092c7b560cd8c8ee3d086e00e8ee1897023fbab48f43e81f89d44df263ace43ce71bc928f6357ac8bb75f80e325db169bdecc128e3e SHA512 e6de5707273c49c5141289dd8a08e3142de63c3c4cb6340465c6de41ebc9f46dcbaaa4944c1c2c1b41be21c9b457f2374d2a26a64469c393f5e2df0be9d949fc -EBUILD llvm-13.0.0_rc3.ebuild 12593 BLAKE2B c321c612de12263b2e0b496946df8aeadaae36e604b9b96919258674966f2f25677e6936dab982a787787a6d86f26084ac4dbbf13abe9bb494ce70a573be7f6d SHA512 6e25eae84c9ba152edf7cc24687384163d841126b77c26cef25b1de6e1799469ea120bee5cebdcb3ca291ca19a3803742b03db1237dd239bc3a69969e4f248fe -EBUILD llvm-14.0.0.9999.ebuild 12589 BLAKE2B 44bca6c287c2d804f6701a8ac8a953624e8418d1ead94450b7b8b5f0ff5192bf6c027ca4f290c8a0e6bc96badd50be68e3fa2765f8cc535ddbd2bd8a39530b2d SHA512 b3e11ab52ca7309933d7cb66e3cb5c85c934c5e417e271d3c8c14879a1afc190b7a49f68a5abc2d847f1883a17f85cd3e9ab42b358b530424d4314707063fce9 +EBUILD llvm-13.0.0.9999.ebuild 12097 BLAKE2B 5d514804e1296ab9f37e2da9fe2e1bb48f670f088ed9a472bb91ad42126785c444d6cd30ce172127d0146c3263e3a635570c633b06f90455bef2e3ace27f75a3 SHA512 8b9d9309a92d2b6319e467716725754810acddcc4a49daffe86177f0114687749611281a140eddc6562f06211afad852872abc7904517f816b04f54b9720ffde +EBUILD llvm-13.0.0_rc2.ebuild 12101 BLAKE2B 3eedc6c4b114572bd5afff7e782d45b0494ea61dce46267b56defd2379d427096ffc462989bdf0486a3ea6bcfa412941083140e20c67dfcd79ab1ff9b04a8365 SHA512 e764117a06d6f5627c5873863bdec3138a3cf03f6dc528ab91b01265657104e0e4a601afacdcc5458ea688308d7f254985050a5aa48f0104f92fa8a3048ae508 +EBUILD llvm-13.0.0_rc3.ebuild 12101 BLAKE2B f7afccd0377ffa69fdfd00cfcb554b216e1b5f8a1f143409915a8fdbb7bb70b87aae5bf05860f8ea33da56cca19916ec49884597b056d8524e30a7dc54413c00 SHA512 67ee4262a435781484b716cf667700e86e9fcd505fdb7d7fca960494e2d6cc6a93e43c6f97f808c828aff417c75c5ecd2175ea824451d03e9ab3eda62854ebfd +EBUILD llvm-13.0.0_rc4.ebuild 12100 BLAKE2B 6342babced2c7e2879fdc045e575976902970a8c5a40271a2a7c93041e0d5444c5e9faafccdab66f65b24142a525595864b597519aaacef5b2b8cab8bb37f3ec SHA512 124a9a2f996560063599bccebc84d4598940651a7068c403ca4978161e4014f552278505f16f66fc1b29503da2201d64a1bbf81c083ab6ccd345240903cd324f +EBUILD llvm-14.0.0.9999.ebuild 12097 BLAKE2B 5d514804e1296ab9f37e2da9fe2e1bb48f670f088ed9a472bb91ad42126785c444d6cd30ce172127d0146c3263e3a635570c633b06f90455bef2e3ace27f75a3 SHA512 8b9d9309a92d2b6319e467716725754810acddcc4a49daffe86177f0114687749611281a140eddc6562f06211afad852872abc7904517f816b04f54b9720ffde MISC metadata.xml 2564 BLAKE2B c7b78f9245daf8990548c13cb0d2c773616b6b17713794f3887028a452649bf0b9aad10d6e9366839afec9d4fbd5a3fca923435cd91a738648d1e22e2b47c89c SHA512 57a6324a8b3c0780459fd37750532d28ba8e004885c7ca4b78c91d22e97e168e479a8ebddcf32803f8825a090eac2353ffa57775b95a49c08b821ae502c86218 diff --git a/sys-devel/llvm/llvm-13.0.0.9999.ebuild b/sys-devel/llvm/llvm-13.0.0.9999.ebuild index ebe79aea74c9..84ccd0ebedbb 100644 --- a/sys-devel/llvm/llvm-13.0.0.9999.ebuild +++ b/sys-devel/llvm/llvm-13.0.0.9999.ebuild @@ -10,14 +10,6 @@ inherit cmake llvm.org multilib-minimal pax-utils python-any-r1 \ DESCRIPTION="Low Level Virtual Machine" HOMEPAGE="https://llvm.org/" -# Those are in lib/Targets, without explicit CMakeLists.txt mention -ALL_LLVM_EXPERIMENTAL_TARGETS=( ARC CSKY M68k VE ) -# Keep in sync with CMakeLists.txt -ALL_LLVM_TARGETS=( AArch64 AMDGPU ARM AVR BPF Hexagon Lanai Mips MSP430 - NVPTX PowerPC RISCV Sparc SystemZ WebAssembly X86 XCore - "${ALL_LLVM_EXPERIMENTAL_TARGETS[@]}" ) -ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" ) - # Additional licenses: # 1. OpenBSD regex: Henry Spencer's license ('rc' in Gentoo) + BSD. # 2. xxhash: BSD. @@ -28,8 +20,7 @@ LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA BSD public-domain rc" SLOT="$(ver_cut 1)" KEYWORDS="" IUSE="debug doc exegesis gold libedit +libffi ncurses test xar xml z3 - kernel_Darwin ${ALL_LLVM_TARGETS[*]}" -REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} )" + kernel_Darwin" RESTRICT="!test? ( test )" RDEPEND=" @@ -68,6 +59,7 @@ PDEPEND="sys-devel/llvm-common LLVM_COMPONENTS=( llvm ) LLVM_MANPAGES=build LLVM_PATCHSET=9999-1 +LLVM_USE_TARGETS=provide llvm.org_set_globals python_check_deps() { @@ -92,8 +84,6 @@ check_live_ebuild() { for i in "${all_targets[@]}"; do has "${i}" "${prod_targets[@]}" || exp_targets+=( "${i}" ) done - # reorder - all_targets=( "${prod_targets[@]}" "${exp_targets[@]}" ) if [[ ${exp_targets[*]} != ${ALL_LLVM_EXPERIMENTAL_TARGETS[*]} ]]; then eqawarn "ALL_LLVM_EXPERIMENTAL_TARGETS is outdated!" @@ -102,10 +92,10 @@ check_live_ebuild() { eqawarn fi - if [[ ${all_targets[*]} != ${ALL_LLVM_TARGETS[*]#llvm_targets_} ]]; then - eqawarn "ALL_LLVM_TARGETS is outdated!" - eqawarn " Have: ${ALL_LLVM_TARGETS[*]#llvm_targets_}" - eqawarn "Expected: ${all_targets[*]}" + if [[ ${prod_targets[*]} != ${ALL_LLVM_PRODUCTION_TARGETS[*]} ]]; then + eqawarn "ALL_LLVM_PRODUCTION_TARGETS is outdated!" + eqawarn " Have: ${ALL_LLVM_PRODUCTION_TARGETS[*]}" + eqawarn "Expected: ${prod_targets[*]}" fi } diff --git a/sys-devel/llvm/llvm-13.0.0_rc2.ebuild b/sys-devel/llvm/llvm-13.0.0_rc2.ebuild index cc9415e5e563..31f75d41c825 100644 --- a/sys-devel/llvm/llvm-13.0.0_rc2.ebuild +++ b/sys-devel/llvm/llvm-13.0.0_rc2.ebuild @@ -10,14 +10,6 @@ inherit cmake llvm.org multilib-minimal pax-utils python-any-r1 \ DESCRIPTION="Low Level Virtual Machine" HOMEPAGE="https://llvm.org/" -# Those are in lib/Targets, without explicit CMakeLists.txt mention -ALL_LLVM_EXPERIMENTAL_TARGETS=( ARC CSKY M68k VE ) -# Keep in sync with CMakeLists.txt -ALL_LLVM_TARGETS=( AArch64 AMDGPU ARM AVR BPF Hexagon Lanai Mips MSP430 - NVPTX PowerPC RISCV Sparc SystemZ WebAssembly X86 XCore - "${ALL_LLVM_EXPERIMENTAL_TARGETS[@]}" ) -ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" ) - # Additional licenses: # 1. OpenBSD regex: Henry Spencer's license ('rc' in Gentoo) + BSD. # 2. xxhash: BSD. @@ -28,8 +20,7 @@ LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA BSD public-domain rc" SLOT="$(ver_cut 1)" KEYWORDS="" IUSE="debug doc exegesis gold libedit +libffi ncurses test xar xml z3 - kernel_Darwin ${ALL_LLVM_TARGETS[*]}" -REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} )" + kernel_Darwin" RESTRICT="!test? ( test )" RDEPEND=" @@ -68,6 +59,7 @@ PDEPEND="sys-devel/llvm-common LLVM_COMPONENTS=( llvm ) LLVM_MANPAGES=build LLVM_PATCHSET=13.0.0-rc2 +LLVM_USE_TARGETS=provide llvm.org_set_globals python_check_deps() { @@ -92,8 +84,6 @@ check_live_ebuild() { for i in "${all_targets[@]}"; do has "${i}" "${prod_targets[@]}" || exp_targets+=( "${i}" ) done - # reorder - all_targets=( "${prod_targets[@]}" "${exp_targets[@]}" ) if [[ ${exp_targets[*]} != ${ALL_LLVM_EXPERIMENTAL_TARGETS[*]} ]]; then eqawarn "ALL_LLVM_EXPERIMENTAL_TARGETS is outdated!" @@ -102,10 +92,10 @@ check_live_ebuild() { eqawarn fi - if [[ ${all_targets[*]} != ${ALL_LLVM_TARGETS[*]#llvm_targets_} ]]; then - eqawarn "ALL_LLVM_TARGETS is outdated!" - eqawarn " Have: ${ALL_LLVM_TARGETS[*]#llvm_targets_}" - eqawarn "Expected: ${all_targets[*]}" + if [[ ${prod_targets[*]} != ${ALL_LLVM_PRODUCTION_TARGETS[*]} ]]; then + eqawarn "ALL_LLVM_PRODUCTION_TARGETS is outdated!" + eqawarn " Have: ${ALL_LLVM_PRODUCTION_TARGETS[*]}" + eqawarn "Expected: ${prod_targets[*]}" fi } diff --git a/sys-devel/llvm/llvm-13.0.0_rc3.ebuild b/sys-devel/llvm/llvm-13.0.0_rc3.ebuild index 56d24237427a..6eaee99b46f7 100644 --- a/sys-devel/llvm/llvm-13.0.0_rc3.ebuild +++ b/sys-devel/llvm/llvm-13.0.0_rc3.ebuild @@ -10,14 +10,6 @@ inherit cmake llvm.org multilib-minimal pax-utils python-any-r1 \ DESCRIPTION="Low Level Virtual Machine" HOMEPAGE="https://llvm.org/" -# Those are in lib/Targets, without explicit CMakeLists.txt mention -ALL_LLVM_EXPERIMENTAL_TARGETS=( ARC CSKY M68k VE ) -# Keep in sync with CMakeLists.txt -ALL_LLVM_TARGETS=( AArch64 AMDGPU ARM AVR BPF Hexagon Lanai Mips MSP430 - NVPTX PowerPC RISCV Sparc SystemZ WebAssembly X86 XCore - "${ALL_LLVM_EXPERIMENTAL_TARGETS[@]}" ) -ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" ) - # Additional licenses: # 1. OpenBSD regex: Henry Spencer's license ('rc' in Gentoo) + BSD. # 2. xxhash: BSD. @@ -28,8 +20,7 @@ LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA BSD public-domain rc" SLOT="$(ver_cut 1)" KEYWORDS="" IUSE="debug doc exegesis gold libedit +libffi ncurses test xar xml z3 - kernel_Darwin ${ALL_LLVM_TARGETS[*]}" -REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} )" + kernel_Darwin" RESTRICT="!test? ( test )" RDEPEND=" @@ -68,6 +59,7 @@ PDEPEND="sys-devel/llvm-common LLVM_COMPONENTS=( llvm ) LLVM_MANPAGES=build LLVM_PATCHSET=13.0.0-rc3 +LLVM_USE_TARGETS=provide llvm.org_set_globals python_check_deps() { @@ -92,8 +84,6 @@ check_live_ebuild() { for i in "${all_targets[@]}"; do has "${i}" "${prod_targets[@]}" || exp_targets+=( "${i}" ) done - # reorder - all_targets=( "${prod_targets[@]}" "${exp_targets[@]}" ) if [[ ${exp_targets[*]} != ${ALL_LLVM_EXPERIMENTAL_TARGETS[*]} ]]; then eqawarn "ALL_LLVM_EXPERIMENTAL_TARGETS is outdated!" @@ -102,10 +92,10 @@ check_live_ebuild() { eqawarn fi - if [[ ${all_targets[*]} != ${ALL_LLVM_TARGETS[*]#llvm_targets_} ]]; then - eqawarn "ALL_LLVM_TARGETS is outdated!" - eqawarn " Have: ${ALL_LLVM_TARGETS[*]#llvm_targets_}" - eqawarn "Expected: ${all_targets[*]}" + if [[ ${prod_targets[*]} != ${ALL_LLVM_PRODUCTION_TARGETS[*]} ]]; then + eqawarn "ALL_LLVM_PRODUCTION_TARGETS is outdated!" + eqawarn " Have: ${ALL_LLVM_PRODUCTION_TARGETS[*]}" + eqawarn "Expected: ${prod_targets[*]}" fi } diff --git a/sys-devel/llvm/llvm-13.0.0_rc4.ebuild b/sys-devel/llvm/llvm-13.0.0_rc4.ebuild new file mode 100644 index 000000000000..ee6e126425ca --- /dev/null +++ b/sys-devel/llvm/llvm-13.0.0_rc4.ebuild @@ -0,0 +1,511 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_{8..10} ) +inherit cmake llvm.org multilib-minimal pax-utils python-any-r1 \ + toolchain-funcs + +DESCRIPTION="Low Level Virtual Machine" +HOMEPAGE="https://llvm.org/" + +# Additional licenses: +# 1. OpenBSD regex: Henry Spencer's license ('rc' in Gentoo) + BSD. +# 2. xxhash: BSD. +# 3. MD5 code: public-domain. +# 4. ConvertUTF.h: TODO. + +LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA BSD public-domain rc" +SLOT="$(ver_cut 1)" +KEYWORDS="" +IUSE="debug doc exegesis gold libedit +libffi ncurses test xar xml z3 + kernel_Darwin" +RESTRICT="!test? ( test )" + +RDEPEND=" + sys-libs/zlib:0=[${MULTILIB_USEDEP}] + exegesis? ( dev-libs/libpfm:= ) + gold? ( >=sys-devel/binutils-2.31.1-r4:*[plugins] ) + libedit? ( dev-libs/libedit:0=[${MULTILIB_USEDEP}] ) + libffi? ( >=dev-libs/libffi-3.0.13-r1:0=[${MULTILIB_USEDEP}] ) + ncurses? ( >=sys-libs/ncurses-5.9-r3:0=[${MULTILIB_USEDEP}] ) + xar? ( app-arch/xar ) + xml? ( dev-libs/libxml2:2=[${MULTILIB_USEDEP}] ) + z3? ( >=sci-mathematics/z3-4.7.1:0=[${MULTILIB_USEDEP}] )" +DEPEND="${RDEPEND} + gold? ( sys-libs/binutils-libs )" +BDEPEND=" + dev-lang/perl + >=dev-util/cmake-3.16 + sys-devel/gnuconfig + kernel_Darwin? ( + <sys-libs/libcxx-$(ver_cut 1-3).9999 + >=sys-devel/binutils-apple-5.1 + ) + doc? ( $(python_gen_any_dep ' + dev-python/recommonmark[${PYTHON_USEDEP}] + dev-python/sphinx[${PYTHON_USEDEP}] + ') ) + libffi? ( virtual/pkgconfig ) + ${PYTHON_DEPS}" +# There are no file collisions between these versions but having :0 +# installed means llvm-config there will take precedence. +RDEPEND="${RDEPEND} + !sys-devel/llvm:0" +PDEPEND="sys-devel/llvm-common + gold? ( >=sys-devel/llvmgold-${SLOT} )" + +LLVM_COMPONENTS=( llvm ) +LLVM_MANPAGES=build +LLVM_PATCHSET=${PV/_/-} +LLVM_USE_TARGETS=provide +llvm.org_set_globals + +python_check_deps() { + use doc || return 0 + + has_version -b "dev-python/recommonmark[${PYTHON_USEDEP}]" && + has_version -b "dev-python/sphinx[${PYTHON_USEDEP}]" +} + +check_live_ebuild() { + local prod_targets=( + $(sed -n -e '/set(LLVM_ALL_TARGETS/,/)/p' CMakeLists.txt \ + | tail -n +2 | head -n -1) + ) + local all_targets=( + lib/Target/*/ + ) + all_targets=( "${all_targets[@]#lib/Target/}" ) + all_targets=( "${all_targets[@]%/}" ) + + local exp_targets=() i + for i in "${all_targets[@]}"; do + has "${i}" "${prod_targets[@]}" || exp_targets+=( "${i}" ) + done + + if [[ ${exp_targets[*]} != ${ALL_LLVM_EXPERIMENTAL_TARGETS[*]} ]]; then + eqawarn "ALL_LLVM_EXPERIMENTAL_TARGETS is outdated!" + eqawarn " Have: ${ALL_LLVM_EXPERIMENTAL_TARGETS[*]}" + eqawarn "Expected: ${exp_targets[*]}" + eqawarn + fi + + if [[ ${prod_targets[*]} != ${ALL_LLVM_PRODUCTION_TARGETS[*]} ]]; then + eqawarn "ALL_LLVM_PRODUCTION_TARGETS is outdated!" + eqawarn " Have: ${ALL_LLVM_PRODUCTION_TARGETS[*]}" + eqawarn "Expected: ${prod_targets[*]}" + fi +} + +check_distribution_components() { + if [[ ${CMAKE_MAKEFILE_GENERATOR} == ninja ]]; then + local all_targets=() my_targets=() l + cd "${BUILD_DIR}" || die + + while read -r l; do + if [[ ${l} == install-*-stripped:* ]]; then + l=${l#install-} + l=${l%%-stripped*} + + case ${l} in + # shared libs + LLVM|LLVMgold) + ;; + # TableGen lib + deps + LLVMDemangle|LLVMSupport|LLVMTableGen) + ;; + # static libs + LLVM*) + continue + ;; + # meta-targets + distribution|llvm-libraries) + continue + ;; + # used only w/ USE=doc + docs-llvm-html) + use doc || continue + ;; + esac + + all_targets+=( "${l}" ) + fi + done < <(ninja -t targets all) + + while read -r l; do + my_targets+=( "${l}" ) + done < <(get_distribution_components $"\n") + + local add=() remove=() + for l in "${all_targets[@]}"; do + if ! has "${l}" "${my_targets[@]}"; then + add+=( "${l}" ) + fi + done + for l in "${my_targets[@]}"; do + if ! has "${l}" "${all_targets[@]}"; then + remove+=( "${l}" ) + fi + done + + if [[ ${#add[@]} -gt 0 || ${#remove[@]} -gt 0 ]]; then + eqawarn "get_distribution_components() is outdated!" + eqawarn " Add: ${add[*]}" + eqawarn "Remove: ${remove[*]}" + fi + cd - >/dev/null || die + fi +} + +src_prepare() { + # disable use of SDK on OSX, bug #568758 + sed -i -e 's/xcrun/false/' utils/lit/lit/util.py || die + + # Update config.guess to support more systems + cp "${BROOT}/usr/share/gnuconfig/config.guess" cmake/ || die + + # Verify that the live ebuild is up-to-date + check_live_ebuild + + llvm.org_src_prepare +} + +# Is LLVM being linked against libc++? +is_libcxx_linked() { + local code='#include <ciso646> +#if defined(_LIBCPP_VERSION) + HAVE_LIBCXX +#endif +' + local out=$($(tc-getCXX) ${CXXFLAGS} ${CPPFLAGS} -x c++ -E -P - <<<"${code}") || return 1 + + [[ ${out} == *HAVE_LIBCXX* ]] +} + +get_distribution_components() { + local sep=${1-;} + + local out=( + # shared libs + LLVM + LTO + Remarks + + # tools + llvm-config + + # common stuff + cmake-exports + llvm-headers + + # libraries needed for clang-tblgen + LLVMDemangle + LLVMSupport + LLVMTableGen + ) + + if multilib_is_native_abi; then + out+=( + # utilities + llvm-tblgen + FileCheck + llvm-PerfectShuffle + count + not + yaml-bench + + # tools + bugpoint + dsymutil + llc + lli + lli-child-target + llvm-addr2line + llvm-ar + llvm-as + llvm-bcanalyzer + llvm-bitcode-strip + llvm-c-test + llvm-cat + llvm-cfi-verify + llvm-config + llvm-cov + llvm-cvtres + llvm-cxxdump + llvm-cxxfilt + llvm-cxxmap + llvm-diff + llvm-dis + llvm-dlltool + llvm-dwarfdump + llvm-dwp + llvm-exegesis + llvm-extract + llvm-gsymutil + llvm-ifs + llvm-install-name-tool + llvm-jitlink + llvm-jitlink-executor + llvm-lib + llvm-libtool-darwin + llvm-link + llvm-lipo + llvm-lto + llvm-lto2 + llvm-mc + llvm-mca + llvm-ml + llvm-modextract + llvm-mt + llvm-nm + llvm-objcopy + llvm-objdump + llvm-opt-report + llvm-otool + llvm-pdbutil + llvm-profdata + llvm-profgen + llvm-ranlib + llvm-rc + llvm-readelf + llvm-readobj + llvm-reduce + llvm-rtdyld + llvm-sim + llvm-size + llvm-split + llvm-stress + llvm-strings + llvm-strip + llvm-symbolizer + llvm-tapi-diff + llvm-undname + llvm-windres + llvm-xray + obj2yaml + opt + sancov + sanstats + split-file + verify-uselistorder + yaml2obj + + # python modules + opt-viewer + ) + + if llvm_are_manpages_built; then + out+=( + # manpages + docs-dsymutil-man + docs-llvm-dwarfdump-man + docs-llvm-man + ) + fi + use doc && out+=( + docs-llvm-html + ) + + use gold && out+=( + LLVMgold + ) + fi + + printf "%s${sep}" "${out[@]}" +} + +multilib_src_configure() { + local ffi_cflags ffi_ldflags + if use libffi; then + ffi_cflags=$($(tc-getPKG_CONFIG) --cflags-only-I libffi) + ffi_ldflags=$($(tc-getPKG_CONFIG) --libs-only-L libffi) + fi + + local libdir=$(get_libdir) + local mycmakeargs=( + # disable appending VCS revision to the version to improve + # direct cache hit ratio + -DLLVM_APPEND_VC_REV=OFF + -DCMAKE_INSTALL_PREFIX="${EPREFIX}/usr/lib/llvm/${SLOT}" + -DLLVM_LIBDIR_SUFFIX=${libdir#lib} + + -DBUILD_SHARED_LIBS=OFF + -DLLVM_BUILD_LLVM_DYLIB=ON + -DLLVM_LINK_LLVM_DYLIB=ON + -DLLVM_DISTRIBUTION_COMPONENTS=$(get_distribution_components) + + # cheap hack: LLVM combines both anyway, and the only difference + # is that the former list is explicitly verified at cmake time + -DLLVM_TARGETS_TO_BUILD="" + -DLLVM_EXPERIMENTAL_TARGETS_TO_BUILD="${LLVM_TARGETS// /;}" + -DLLVM_BUILD_TESTS=$(usex test) + + -DLLVM_ENABLE_FFI=$(usex libffi) + -DLLVM_ENABLE_LIBEDIT=$(usex libedit) + -DLLVM_ENABLE_TERMINFO=$(usex ncurses) + -DLLVM_ENABLE_LIBXML2=$(usex xml) + -DLLVM_ENABLE_ASSERTIONS=$(usex debug) + -DLLVM_ENABLE_LIBPFM=$(usex exegesis) + -DLLVM_ENABLE_EH=ON + -DLLVM_ENABLE_RTTI=ON + -DLLVM_ENABLE_Z3_SOLVER=$(usex z3) + + -DLLVM_HOST_TRIPLE="${CHOST}" + + -DFFI_INCLUDE_DIR="${ffi_cflags#-I}" + -DFFI_LIBRARY_DIR="${ffi_ldflags#-L}" + # used only for llvm-objdump tool + -DLLVM_HAVE_LIBXAR=$(multilib_native_usex xar 1 0) + + -DPython3_EXECUTABLE="${PYTHON}" + + # disable OCaml bindings (now in dev-ml/llvm-ocaml) + -DOCAMLFIND=NO + ) + + if is_libcxx_linked; then + # Smart hack: alter version suffix -> SOVERSION when linking + # against libc++. This way we won't end up mixing LLVM libc++ + # libraries with libstdc++ clang, and the other way around. + mycmakeargs+=( + -DLLVM_VERSION_SUFFIX="libcxx" + -DLLVM_ENABLE_LIBCXX=ON + ) + fi + +# Note: go bindings have no CMake rules at the moment +# but let's kill the check in case they are introduced +# if ! multilib_is_native_abi || ! use go; then + mycmakeargs+=( + -DGO_EXECUTABLE=GO_EXECUTABLE-NOTFOUND + ) +# fi + + use test && mycmakeargs+=( + -DLLVM_LIT_ARGS="$(get_lit_flags)" + ) + + if multilib_is_native_abi; then + local build_docs=OFF + if llvm_are_manpages_built; then + build_docs=ON + mycmakeargs+=( + -DCMAKE_INSTALL_MANDIR="${EPREFIX}/usr/lib/llvm/${SLOT}/share/man" + -DLLVM_INSTALL_SPHINX_HTML_DIR="${EPREFIX}/usr/share/doc/${PF}/html" + -DSPHINX_WARNINGS_AS_ERRORS=OFF + ) + fi + + mycmakeargs+=( + -DLLVM_BUILD_DOCS=${build_docs} + -DLLVM_ENABLE_OCAMLDOC=OFF + -DLLVM_ENABLE_SPHINX=${build_docs} + -DLLVM_ENABLE_DOXYGEN=OFF + -DLLVM_INSTALL_UTILS=ON + ) + use gold && mycmakeargs+=( + -DLLVM_BINUTILS_INCDIR="${EPREFIX}"/usr/include + ) + fi + + if tc-is-cross-compiler; then + local tblgen="${EPREFIX}/usr/lib/llvm/${SLOT}/bin/llvm-tblgen" + [[ -x "${tblgen}" ]] \ + || die "${tblgen} not found or usable" + mycmakeargs+=( + -DCMAKE_CROSSCOMPILING=ON + -DLLVM_TABLEGEN="${tblgen}" + ) + fi + + # workaround BMI bug in gcc-7 (fixed in 7.4) + # https://bugs.gentoo.org/649880 + # apply only to x86, https://bugs.gentoo.org/650506 + if tc-is-gcc && [[ ${MULTILIB_ABI_FLAG} == abi_x86* ]] && + [[ $(gcc-major-version) -eq 7 && $(gcc-minor-version) -lt 4 ]] + then + local CFLAGS="${CFLAGS} -mno-bmi" + local CXXFLAGS="${CXXFLAGS} -mno-bmi" + fi + + # LLVM can have very high memory consumption while linking, + # exhausting the limit on 32-bit linker executable + use x86 && local -x LDFLAGS="${LDFLAGS} -Wl,--no-keep-memory" + + # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844 + use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG" + cmake_src_configure + + multilib_is_native_abi && check_distribution_components +} + +multilib_src_compile() { + cmake_build distribution + + pax-mark m "${BUILD_DIR}"/bin/llvm-rtdyld + pax-mark m "${BUILD_DIR}"/bin/lli + pax-mark m "${BUILD_DIR}"/bin/lli-child-target + + if use test; then + pax-mark m "${BUILD_DIR}"/unittests/ExecutionEngine/Orc/OrcJITTests + pax-mark m "${BUILD_DIR}"/unittests/ExecutionEngine/MCJIT/MCJITTests + pax-mark m "${BUILD_DIR}"/unittests/Support/SupportTests + fi +} + +multilib_src_test() { + # respect TMPDIR! + local -x LIT_PRESERVES_TMP=1 + cmake_build check +} + +src_install() { + local MULTILIB_CHOST_TOOLS=( + /usr/lib/llvm/${SLOT}/bin/llvm-config + ) + + local MULTILIB_WRAPPED_HEADERS=( + /usr/include/llvm/Config/llvm-config.h + ) + + local LLVM_LDPATHS=() + multilib-minimal_src_install + + # move wrapped headers back + mv "${ED}"/usr/include "${ED}"/usr/lib/llvm/${SLOT}/include || die +} + +multilib_src_install() { + DESTDIR=${D} cmake_build install-distribution + + # move headers to /usr/include for wrapping + rm -rf "${ED}"/usr/include || die + mv "${ED}"/usr/lib/llvm/${SLOT}/include "${ED}"/usr/include || die + + LLVM_LDPATHS+=( "${EPREFIX}/usr/lib/llvm/${SLOT}/$(get_libdir)" ) +} + +multilib_src_install_all() { + local revord=$(( 9999 - ${SLOT} )) + newenvd - "60llvm-${revord}" <<-_EOF_ + PATH="${EPREFIX}/usr/lib/llvm/${SLOT}/bin" + # we need to duplicate it in ROOTPATH for Portage to respect... + ROOTPATH="${EPREFIX}/usr/lib/llvm/${SLOT}/bin" + MANPATH="${EPREFIX}/usr/lib/llvm/${SLOT}/share/man" + LDPATH="$( IFS=:; echo "${LLVM_LDPATHS[*]}" )" + _EOF_ + + docompress "/usr/lib/llvm/${SLOT}/share/man" + llvm_install_manpages +} + +pkg_postinst() { + elog "You can find additional opt-viewer utility scripts in:" + elog " ${EROOT}/usr/lib/llvm/${SLOT}/share/opt-viewer" + elog "To use these scripts, you will need Python along with the following" + elog "packages:" + elog " dev-python/pygments (for opt-viewer)" + elog " dev-python/pyyaml (for all of them)" +} diff --git a/sys-devel/llvm/llvm-14.0.0.9999.ebuild b/sys-devel/llvm/llvm-14.0.0.9999.ebuild index ebe79aea74c9..84ccd0ebedbb 100644 --- a/sys-devel/llvm/llvm-14.0.0.9999.ebuild +++ b/sys-devel/llvm/llvm-14.0.0.9999.ebuild @@ -10,14 +10,6 @@ inherit cmake llvm.org multilib-minimal pax-utils python-any-r1 \ DESCRIPTION="Low Level Virtual Machine" HOMEPAGE="https://llvm.org/" -# Those are in lib/Targets, without explicit CMakeLists.txt mention -ALL_LLVM_EXPERIMENTAL_TARGETS=( ARC CSKY M68k VE ) -# Keep in sync with CMakeLists.txt -ALL_LLVM_TARGETS=( AArch64 AMDGPU ARM AVR BPF Hexagon Lanai Mips MSP430 - NVPTX PowerPC RISCV Sparc SystemZ WebAssembly X86 XCore - "${ALL_LLVM_EXPERIMENTAL_TARGETS[@]}" ) -ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" ) - # Additional licenses: # 1. OpenBSD regex: Henry Spencer's license ('rc' in Gentoo) + BSD. # 2. xxhash: BSD. @@ -28,8 +20,7 @@ LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA BSD public-domain rc" SLOT="$(ver_cut 1)" KEYWORDS="" IUSE="debug doc exegesis gold libedit +libffi ncurses test xar xml z3 - kernel_Darwin ${ALL_LLVM_TARGETS[*]}" -REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} )" + kernel_Darwin" RESTRICT="!test? ( test )" RDEPEND=" @@ -68,6 +59,7 @@ PDEPEND="sys-devel/llvm-common LLVM_COMPONENTS=( llvm ) LLVM_MANPAGES=build LLVM_PATCHSET=9999-1 +LLVM_USE_TARGETS=provide llvm.org_set_globals python_check_deps() { @@ -92,8 +84,6 @@ check_live_ebuild() { for i in "${all_targets[@]}"; do has "${i}" "${prod_targets[@]}" || exp_targets+=( "${i}" ) done - # reorder - all_targets=( "${prod_targets[@]}" "${exp_targets[@]}" ) if [[ ${exp_targets[*]} != ${ALL_LLVM_EXPERIMENTAL_TARGETS[*]} ]]; then eqawarn "ALL_LLVM_EXPERIMENTAL_TARGETS is outdated!" @@ -102,10 +92,10 @@ check_live_ebuild() { eqawarn fi - if [[ ${all_targets[*]} != ${ALL_LLVM_TARGETS[*]#llvm_targets_} ]]; then - eqawarn "ALL_LLVM_TARGETS is outdated!" - eqawarn " Have: ${ALL_LLVM_TARGETS[*]#llvm_targets_}" - eqawarn "Expected: ${all_targets[*]}" + if [[ ${prod_targets[*]} != ${ALL_LLVM_PRODUCTION_TARGETS[*]} ]]; then + eqawarn "ALL_LLVM_PRODUCTION_TARGETS is outdated!" + eqawarn " Have: ${ALL_LLVM_PRODUCTION_TARGETS[*]}" + eqawarn "Expected: ${prod_targets[*]}" fi } |