diff options
Diffstat (limited to 'llvm-runtimes')
-rw-r--r-- | llvm-runtimes/Manifest.gz | bin | 1394 -> 1390 bytes | |||
-rw-r--r-- | llvm-runtimes/compiler-rt-sanitizers/Manifest | 2 | ||||
-rw-r--r-- | llvm-runtimes/compiler-rt-sanitizers/compiler-rt-sanitizers-20.0.0_pre20241215.ebuild | 222 | ||||
-rw-r--r-- | llvm-runtimes/compiler-rt/Manifest | 2 | ||||
-rw-r--r-- | llvm-runtimes/compiler-rt/compiler-rt-20.0.0_pre20241215.ebuild | 175 | ||||
-rw-r--r-- | llvm-runtimes/libcxx/Manifest | 2 | ||||
-rw-r--r-- | llvm-runtimes/libcxx/libcxx-20.0.0_pre20241215.ebuild | 208 | ||||
-rw-r--r-- | llvm-runtimes/libcxxabi/Manifest | 2 | ||||
-rw-r--r-- | llvm-runtimes/libcxxabi/libcxxabi-20.0.0_pre20241215.ebuild | 109 | ||||
-rw-r--r-- | llvm-runtimes/libunwind/Manifest | 2 | ||||
-rw-r--r-- | llvm-runtimes/libunwind/libunwind-20.0.0_pre20241215.ebuild | 128 | ||||
-rw-r--r-- | llvm-runtimes/offload/Manifest | 2 | ||||
-rw-r--r-- | llvm-runtimes/offload/offload-20.0.0_pre20241215.ebuild | 147 | ||||
-rw-r--r-- | llvm-runtimes/openmp/Manifest | 2 | ||||
-rw-r--r-- | llvm-runtimes/openmp/openmp-20.0.0_pre20241215.ebuild | 88 |
15 files changed, 1091 insertions, 0 deletions
diff --git a/llvm-runtimes/Manifest.gz b/llvm-runtimes/Manifest.gz Binary files differindex 7823ed5b47e5..5cb3243e6875 100644 --- a/llvm-runtimes/Manifest.gz +++ b/llvm-runtimes/Manifest.gz diff --git a/llvm-runtimes/compiler-rt-sanitizers/Manifest b/llvm-runtimes/compiler-rt-sanitizers/Manifest index bf1f5bd210d1..5a6c1a897255 100644 --- a/llvm-runtimes/compiler-rt-sanitizers/Manifest +++ b/llvm-runtimes/compiler-rt-sanitizers/Manifest @@ -15,6 +15,7 @@ DIST llvm-project-19.1.4.src.tar.xz.sig 438 BLAKE2B b0925bdb761046d69779e0b035e2 DIST llvm-project-19.1.5.src.tar.xz 141243716 BLAKE2B 228fc66ab688abfc16f31b2cd83163b81ef61604ace21eab69a1776f0dc88cbe8fa831162205849e5be3975a214136399572b4ad1b908986e37b2d38a1a7fa5d SHA512 648854e9c91fdcc5c677ce3800e046f2060b998a45cf9f7eebe02898431b3924f9348b6fc366102cd4fdda72dcb8f32076f98aa69927e0e20b3f1007fba10b22 DIST llvm-project-19.1.5.src.tar.xz.sig 438 BLAKE2B 1d40a5c5405f99ef86e3360f9ea153afd1ae4001697210fd799a988113e8a3cef39e2c4794edd9332f384d8490f4ce2ab6bee6d98f794f84775807f833b81c0a SHA512 a438c86ce882eb1ac3e50842937068794ed162bb1b7ded68a2fe3ec2ab4f57cc38aee667cfb46afe6da22eef7ed1cb65820a473f63bd5a0dc6aad41df7bfad54 DIST llvm-project-32f7f0010bca99ee4bd917f57272733fb2bf3bd9.tar.gz 223983502 BLAKE2B fd3e6b0b795abc42568ef98fa774d927029c18838a5d0f34eaa66c37976444a63f2fc5d883f3bf3a98533f51e387936f1c659230f31c757d26153425696a16cd SHA512 65a345ad5b77c627008f759947e5e9f28a62c8992d7146113e0446e5849feaf9088c15c8b22ca0824af5b927d6a417f5326258b489fb8ccea78ec9e0e0fe8fba +DIST llvm-project-49a5ad8e5714fd404210279303acc97b495d66d0.tar.gz 224456065 BLAKE2B 0077b9d37c479ac6190cc4b897cc35d6f1f3e6a772cd0620bcb1006afc19377e9968e38fb9d9adffe316e85290c9045deecbf9bf62b440c55968634b442edb31 SHA512 45d779eb27c230f656fda47c85127381cab8c8f7f75d77411c6960269f8aad5fa3c99c024a98ab8a349da1c88ad9d892cc82f91a6f344b791b281449031ae49a EBUILD compiler-rt-sanitizers-15.0.7-r1.ebuild 6678 BLAKE2B 0261091e2c7a6a60e60811f0a04313689bedb56fccd645e595cacb0c85b7457007743d4f8be92e04c452031a0c2a314745ffee612ca724b796347a7b82d0253a SHA512 daf41b0aa6faf374b4d1cbb34234c5d0c3344aad72f80b50082eddd0e31f746451f44bb3bfc3f3a185ea139db846fac750d99d712b7e7f010a3b14c8e62b2060 EBUILD compiler-rt-sanitizers-16.0.6-r1.ebuild 6665 BLAKE2B 3f465a8716096f3476f1bd46f3dfa959800e1ea0d46a062f02de600b9160043320c2edb02caa91f52ec18fca1d93bef2054395411962aea83f045b0cde4d9b57 SHA512 184805f8bdcf0fa8adc6196f26143d90b983cc61dc6f8ab23bc699dd6dd109cc07531ca87d4fae7d259cb8922bea14b37ae35237da9a824b0e62e960eac13476 EBUILD compiler-rt-sanitizers-17.0.6-r1.ebuild 6497 BLAKE2B 008f61ca9c82bba3d992d674e11c45e77a9a29859cdb415fdb1c225d1618b120196f6289921cdf248ea74079df5725fa2abea32db6a62343fece726e4cd0a3af SHA512 9fbc422279104ccc25c5aed7506b9a7c36358e36cd1829a2635c8ad830fe14ea82c80a60f1fec7939ee0e722c238c665e0fd73b29b4bd9a69f4524c6a964f055 @@ -23,4 +24,5 @@ EBUILD compiler-rt-sanitizers-19.1.4.ebuild 6484 BLAKE2B b39cf4225885bbc39e55fc7 EBUILD compiler-rt-sanitizers-19.1.5.ebuild 6489 BLAKE2B 7f11f8e09cc8a00b90d17c72fc57054230f41bd61b37f028b5fc51c6c1c2e9b9084a881cfbf360ff44ff29801f5b6abc9eccde24e6c3e33f21d8f528898f9af1 SHA512 16e9498c97a4cf3bb262584dba89d351ad1a720a5be99bdc818129d61f77004cc8fe00fca825e2e67b19f038fdac3578b299712bcda59f0e72c5f58755d7a99f EBUILD compiler-rt-sanitizers-20.0.0.9999.ebuild 6404 BLAKE2B 288357f4570b77f6a3b0015014008b6124bd0d802f70a5ab4b01a7975c92737b7db89c5138bc27ed3e4cfd74f6a7a35d5dfc8ce0c6e05d522870cde2c0f1c5a8 SHA512 7c0be45c4ea2e612cd6332ed542462f8fe88823f44890b8201ed7f5d5cde286ababa3897f0778cfc82916a5be42eeb5e3b7b578201c5920d7d9977d6dec13d17 EBUILD compiler-rt-sanitizers-20.0.0_pre20241207.ebuild 6404 BLAKE2B 288357f4570b77f6a3b0015014008b6124bd0d802f70a5ab4b01a7975c92737b7db89c5138bc27ed3e4cfd74f6a7a35d5dfc8ce0c6e05d522870cde2c0f1c5a8 SHA512 7c0be45c4ea2e612cd6332ed542462f8fe88823f44890b8201ed7f5d5cde286ababa3897f0778cfc82916a5be42eeb5e3b7b578201c5920d7d9977d6dec13d17 +EBUILD compiler-rt-sanitizers-20.0.0_pre20241215.ebuild 6404 BLAKE2B 288357f4570b77f6a3b0015014008b6124bd0d802f70a5ab4b01a7975c92737b7db89c5138bc27ed3e4cfd74f6a7a35d5dfc8ce0c6e05d522870cde2c0f1c5a8 SHA512 7c0be45c4ea2e612cd6332ed542462f8fe88823f44890b8201ed7f5d5cde286ababa3897f0778cfc82916a5be42eeb5e3b7b578201c5920d7d9977d6dec13d17 MISC metadata.xml 1599 BLAKE2B 2db46fca9bbf85a6cdb70d9bc99a8e1bdc60c065b3e5f44ce31fb6cc08cc6da9037eb3155b1e73975b5e1bbb448be6b2164413f2234e89a4bc191c4562dd9342 SHA512 10bb564b181a9ce38680a05f854e58a3a726b052200d735c3959a0a42af97a47e0a5df60fbec374c7265e0eac16e1247ed0862aeab138b9dc035db8da52fb4ce diff --git a/llvm-runtimes/compiler-rt-sanitizers/compiler-rt-sanitizers-20.0.0_pre20241215.ebuild b/llvm-runtimes/compiler-rt-sanitizers/compiler-rt-sanitizers-20.0.0_pre20241215.ebuild new file mode 100644 index 000000000000..cea1ae243486 --- /dev/null +++ b/llvm-runtimes/compiler-rt-sanitizers/compiler-rt-sanitizers-20.0.0_pre20241215.ebuild @@ -0,0 +1,222 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..13} ) +inherit check-reqs cmake flag-o-matic llvm.org llvm-utils python-any-r1 + +DESCRIPTION="Compiler runtime libraries for clang (sanitizers & xray)" +HOMEPAGE="https://llvm.org/" + +LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" +SLOT="${LLVM_MAJOR}" +IUSE="+abi_x86_32 abi_x86_64 +clang +debug test" +# base targets +IUSE+=" +ctx-profile +libfuzzer +memprof +orc +profile +xray" +# sanitizer targets, keep in sync with config-ix.cmake +# NB: ubsan, scudo deliberately match two entries +SANITIZER_FLAGS=( + asan dfsan lsan msan hwasan tsan ubsan safestack cfi scudo + shadowcallstack gwp-asan nsan rtsan +) +IUSE+=" ${SANITIZER_FLAGS[@]/#/+}" +REQUIRED_USE=" + || ( ${SANITIZER_FLAGS[*]} libfuzzer orc profile xray ) + test? ( + cfi? ( ubsan ) + gwp-asan? ( scudo ) + ) +" +RESTRICT=" + !clang? ( test ) + !test? ( test ) +" + +DEPEND=" + llvm-core/llvm:${LLVM_MAJOR} + virtual/libcrypt[abi_x86_32(-)?,abi_x86_64(-)?] +" +BDEPEND=" + clang? ( + llvm-core/clang:${LLVM_MAJOR} + llvm-runtimes/compiler-rt:${LLVM_MAJOR} + ) + elibc_glibc? ( net-libs/libtirpc ) + test? ( + $(python_gen_any_dep ">=dev-python/lit-15[\${PYTHON_USEDEP}]") + =llvm-core/clang-${LLVM_VERSION}*:${LLVM_MAJOR} + ) + !test? ( + ${PYTHON_DEPS} + ) +" + +LLVM_COMPONENTS=( compiler-rt cmake llvm/cmake ) +LLVM_TEST_COMPONENTS=( + llvm/include/llvm/ProfileData llvm/lib/Testing/Support third-party +) +llvm.org_set_globals + +python_check_deps() { + use test || return 0 + python_has_version ">=dev-python/lit-15[${PYTHON_USEDEP}]" +} + +check_space() { + if use test; then + local CHECKREQS_DISK_BUILD=11G + check-reqs_pkg_pretend + fi +} + +pkg_pretend() { + check_space +} + +pkg_setup() { + check_space + python-any-r1_pkg_setup +} + +src_prepare() { + sed -i -e 's:-Werror::' lib/tsan/go/buildgo.sh || die + + local flag + for flag in "${SANITIZER_FLAGS[@]}"; do + if ! use "${flag}"; then + local cmake_flag=${flag/-/_} + sed -i -e "/COMPILER_RT_HAS_${cmake_flag^^}/s:TRUE:FALSE:" \ + cmake/config-ix.cmake || die + fi + done + + # TODO: fix these tests to be skipped upstream + if use asan && ! use profile; then + rm test/asan/TestCases/asan_and_llvm_coverage_test.cpp || die + fi + if use ubsan && ! use cfi; then + > test/cfi/CMakeLists.txt || die + fi + # hangs, sigh + rm test/tsan/getline_nohang.cpp || die + + llvm.org_src_prepare +} + +src_configure() { + llvm_prepend_path "${LLVM_MAJOR}" + + # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844 + use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG" + + # pre-set since we need to pass it to cmake + BUILD_DIR=${WORKDIR}/compiler-rt_build + + if use clang; then + local -x CC=${CHOST}-clang + local -x CXX=${CHOST}-clang++ + strip-unsupported-flags + fi + + local flag want_sanitizer=OFF + for flag in "${SANITIZER_FLAGS[@]}"; do + if use "${flag}"; then + want_sanitizer=ON + break + fi + done + + local mycmakeargs=( + -DCOMPILER_RT_INSTALL_PATH="${EPREFIX}/usr/lib/clang/${LLVM_MAJOR}" + # 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/${LLVM_MAJOR}" + + -DCOMPILER_RT_INCLUDE_TESTS=$(usex test) + # builtins & crt installed by llvm-runtimes/compiler-rt + -DCOMPILER_RT_BUILD_BUILTINS=OFF + -DCOMPILER_RT_BUILD_CRT=OFF + -DCOMPILER_RT_BUILD_CTX_PROFILE=$(usex ctx-profile) + -DCOMPILER_RT_BUILD_LIBFUZZER=$(usex libfuzzer) + -DCOMPILER_RT_BUILD_MEMPROF=$(usex memprof) + -DCOMPILER_RT_BUILD_ORC=$(usex orc) + -DCOMPILER_RT_BUILD_PROFILE=$(usex profile) + -DCOMPILER_RT_BUILD_SANITIZERS="${want_sanitizer}" + -DCOMPILER_RT_BUILD_XRAY=$(usex xray) + + -DPython3_EXECUTABLE="${PYTHON}" + ) + + if use amd64; then + mycmakeargs+=( + -DCAN_TARGET_i386=$(usex abi_x86_32) + -DCAN_TARGET_x86_64=$(usex abi_x86_64) + ) + fi + + if use test; then + mycmakeargs+=( + -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" + -DLLVM_LIT_ARGS="$(get_lit_flags)" + + # they are created during src_test() + -DCOMPILER_RT_TEST_COMPILER="${BUILD_DIR}/lib/llvm/${LLVM_MAJOR}/bin/clang" + -DCOMPILER_RT_TEST_CXX_COMPILER="${BUILD_DIR}/lib/llvm/${LLVM_MAJOR}/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/${LLVM_MAJOR}/bin/clang \ + CXX=${EPREFIX}/usr/lib/llvm/${LLVM_MAJOR}/bin/clang++ \ + strip-unsupported-flags + fi + + if use prefix && [[ "${CHOST}" == *-darwin* ]] ; then + mycmakeargs+=( + # setting -isysroot is disabled with compiler-rt-prefix-paths.patch + # this allows adding arm64 support using SDK in EPREFIX + -DDARWIN_macosx_CACHED_SYSROOT="${EPREFIX}/MacOSX.sdk" + # Set version based on the SDK in EPREFIX + # This disables i386 for SDK >= 10.15 + # Will error if has_use tsan and SDK < 10.12 + -DDARWIN_macosx_OVERRIDE_SDK_VERSION="$(realpath ${EPREFIX}/MacOSX.sdk | sed -e 's/.*MacOSX\(.*\)\.sdk/\1/')" + # Use our libtool instead of looking it up with xcrun + -DCMAKE_LIBTOOL="${EPREFIX}/usr/bin/${CHOST}-libtool" + ) + fi + + cmake_src_configure + + if use test; then + local sys_dir=( "${EPREFIX}"/usr/lib/clang/${LLVM_MAJOR}/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/${LLVM_MAJOR}/{bin,$(get_libdir)},clang/${LLVM_MAJOR}/include} || die + cp "${EPREFIX}"/usr/lib/llvm/${LLVM_MAJOR}/bin/clang{,++} \ + "${BUILD_DIR}"/lib/llvm/${LLVM_MAJOR}/bin/ || die + cp "${EPREFIX}"/usr/lib/clang/${LLVM_MAJOR}/include/*.h \ + "${BUILD_DIR}"/lib/clang/${LLVM_MAJOR}/include/ || die + cp "${sys_dir}"/*builtins*.a \ + "${BUILD_DIR}/lib/clang/${LLVM_MAJOR}/lib/${sys_dir##*/}/" || die + # we also need LLVMgold.so for gold-based tests + if [[ -f ${EPREFIX}/usr/lib/llvm/${LLVM_MAJOR}/$(get_libdir)/LLVMgold.so ]]; then + ln -s "${EPREFIX}"/usr/lib/llvm/${LLVM_MAJOR}/$(get_libdir)/LLVMgold.so \ + "${BUILD_DIR}"/lib/llvm/${LLVM_MAJOR}/$(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_build check-all +} diff --git a/llvm-runtimes/compiler-rt/Manifest b/llvm-runtimes/compiler-rt/Manifest index 8b41858bb213..b3fa60afdd73 100644 --- a/llvm-runtimes/compiler-rt/Manifest +++ b/llvm-runtimes/compiler-rt/Manifest @@ -14,6 +14,7 @@ DIST llvm-project-19.1.4.src.tar.xz.sig 438 BLAKE2B b0925bdb761046d69779e0b035e2 DIST llvm-project-19.1.5.src.tar.xz 141243716 BLAKE2B 228fc66ab688abfc16f31b2cd83163b81ef61604ace21eab69a1776f0dc88cbe8fa831162205849e5be3975a214136399572b4ad1b908986e37b2d38a1a7fa5d SHA512 648854e9c91fdcc5c677ce3800e046f2060b998a45cf9f7eebe02898431b3924f9348b6fc366102cd4fdda72dcb8f32076f98aa69927e0e20b3f1007fba10b22 DIST llvm-project-19.1.5.src.tar.xz.sig 438 BLAKE2B 1d40a5c5405f99ef86e3360f9ea153afd1ae4001697210fd799a988113e8a3cef39e2c4794edd9332f384d8490f4ce2ab6bee6d98f794f84775807f833b81c0a SHA512 a438c86ce882eb1ac3e50842937068794ed162bb1b7ded68a2fe3ec2ab4f57cc38aee667cfb46afe6da22eef7ed1cb65820a473f63bd5a0dc6aad41df7bfad54 DIST llvm-project-32f7f0010bca99ee4bd917f57272733fb2bf3bd9.tar.gz 223983502 BLAKE2B fd3e6b0b795abc42568ef98fa774d927029c18838a5d0f34eaa66c37976444a63f2fc5d883f3bf3a98533f51e387936f1c659230f31c757d26153425696a16cd SHA512 65a345ad5b77c627008f759947e5e9f28a62c8992d7146113e0446e5849feaf9088c15c8b22ca0824af5b927d6a417f5326258b489fb8ccea78ec9e0e0fe8fba +DIST llvm-project-49a5ad8e5714fd404210279303acc97b495d66d0.tar.gz 224456065 BLAKE2B 0077b9d37c479ac6190cc4b897cc35d6f1f3e6a772cd0620bcb1006afc19377e9968e38fb9d9adffe316e85290c9045deecbf9bf62b440c55968634b442edb31 SHA512 45d779eb27c230f656fda47c85127381cab8c8f7f75d77411c6960269f8aad5fa3c99c024a98ab8a349da1c88ad9d892cc82f91a6f344b791b281449031ae49a EBUILD compiler-rt-15.0.7-r1.ebuild 4252 BLAKE2B 39ed1e06453690d129552fcca79b7df77345d0a4f21d477521cd7638f492450abc7fed895471709dc3acc7f7944a2df9d89668c47bf48c6f5e9d9ab27440eea0 SHA512 9fe7a91466b8903d68009d39ce13282f2e661211f4b70bc2830119018bccf3f15c894488734451054f15e64cd258e9f517d5aa01432d5ba253f58660f4f79899 EBUILD compiler-rt-15.0.7-r2.ebuild 4380 BLAKE2B b60b82c22641657d9bc56d1dca2d357757b1512f4f738f5f1c3f31456328350a778951e18ae756d375227f1e6bfff77ce2a8932a0064884b2d2854de0e31b60c SHA512 803c77378d9fc5b40c5ef65b55e9b3fd311bb9ba6473edefe4ffc88bcc6f79fbca656a63fcfd89a8c425b72c0e0683963ae4ff6399720ebdd6f260ccb3b6891e EBUILD compiler-rt-16.0.6-r5.ebuild 5235 BLAKE2B 900d4aa376cdab2444290f20036abc8ff6f71da93ba84b48e3b6a5edc16737fafc92dc9b114b100718ae8599e2754810c6502ce1fbd9061163eeddc3b02fb836 SHA512 5ad35070fdbf7623d1990bb0c53d72e9dce27e57466429785cec41079f26db73220e26e9281625ae9288d4033e863a8e5e6e73110cbf3e2d3e70ef1deb30574a @@ -26,4 +27,5 @@ EBUILD compiler-rt-19.1.4.ebuild 5204 BLAKE2B ab807058256aa80374f77c5a0141f5a0dc EBUILD compiler-rt-19.1.5.ebuild 5209 BLAKE2B 8d754cd636d4550b5b98c070ea72f99f4da7e357c24ef58ea60c1b0553fb452657c95a8eabf3147a6fc8c41f8befd87c25bdbabce9b870d58ca7dc9dff09b807 SHA512 8964c49d1cefc0c8bbab17d569090084958b5910ef579b1538dfe2d9507d5d0fcebd02c6bdaad14e27a5e222acafa1eaa2cd3572aebd9db65e477d6032149d05 EBUILD compiler-rt-20.0.0.9999.ebuild 5100 BLAKE2B c96f7e85cfe30d5e899bf251631a997c3e9c995184f74a8e797872a6c8444c4859e6e6b2897f903b3254f3eba335cf12b512f841407dad2d4a5f33b0a9903883 SHA512 811365cf104075f395953e02e03f70e32b26b6106037d7115cf4ceed50370d63f48239c186c359aa3c5a2ee1bd0fa2fb9466bfb0277014fa2a3f4417649f07ba EBUILD compiler-rt-20.0.0_pre20241207.ebuild 5100 BLAKE2B c96f7e85cfe30d5e899bf251631a997c3e9c995184f74a8e797872a6c8444c4859e6e6b2897f903b3254f3eba335cf12b512f841407dad2d4a5f33b0a9903883 SHA512 811365cf104075f395953e02e03f70e32b26b6106037d7115cf4ceed50370d63f48239c186c359aa3c5a2ee1bd0fa2fb9466bfb0277014fa2a3f4417649f07ba +EBUILD compiler-rt-20.0.0_pre20241215.ebuild 5100 BLAKE2B c96f7e85cfe30d5e899bf251631a997c3e9c995184f74a8e797872a6c8444c4859e6e6b2897f903b3254f3eba335cf12b512f841407dad2d4a5f33b0a9903883 SHA512 811365cf104075f395953e02e03f70e32b26b6106037d7115cf4ceed50370d63f48239c186c359aa3c5a2ee1bd0fa2fb9466bfb0277014fa2a3f4417649f07ba MISC metadata.xml 610 BLAKE2B 2fd2530da10ecae7d8b54b448d0e0ec082b8082e3b5da8ab47dc79058724b368d5f900b1de18e14fe2c2b95257c69d0aceb9bd83b8b6873f65935302461ac263 SHA512 d50a05439376fa985ab1579a592cc6f544552e177132dc8773f172b827dec49ab3f8bcd77d89c25d4f2a1b99492897045b16a75ceb2d14cc76187140c33ccc45 diff --git a/llvm-runtimes/compiler-rt/compiler-rt-20.0.0_pre20241215.ebuild b/llvm-runtimes/compiler-rt/compiler-rt-20.0.0_pre20241215.ebuild new file mode 100644 index 000000000000..7971b744756d --- /dev/null +++ b/llvm-runtimes/compiler-rt/compiler-rt-20.0.0_pre20241215.ebuild @@ -0,0 +1,175 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..13} ) +inherit cmake crossdev flag-o-matic llvm.org llvm-utils python-any-r1 +inherit toolchain-funcs + +DESCRIPTION="Compiler runtime library for clang (built-in part)" +HOMEPAGE="https://llvm.org/" + +LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" +SLOT="${LLVM_MAJOR}" +IUSE="+abi_x86_32 abi_x86_64 +atomic-builtins +clang +debug test" +REQUIRED_USE="atomic-builtins? ( clang )" +RESTRICT="!test? ( test ) !clang? ( test )" + +DEPEND=" + llvm-core/llvm:${LLVM_MAJOR} +" +BDEPEND=" + clang? ( llvm-core/clang:${LLVM_MAJOR} ) + test? ( + $(python_gen_any_dep ">=dev-python/lit-15[\${PYTHON_USEDEP}]") + =llvm-core/clang-${LLVM_VERSION}*:${LLVM_MAJOR} + ) + !test? ( + ${PYTHON_DEPS} + ) +" + +LLVM_COMPONENTS=( compiler-rt cmake llvm/cmake ) +LLVM_TEST_COMPONENTS=( llvm/include/llvm/TargetParser ) +llvm.org_set_globals + +python_check_deps() { + use test || return 0 + python_has_version ">=dev-python/lit-15[${PYTHON_USEDEP}]" +} + +pkg_pretend() { + if ! use clang && ! tc-is-clang; then + ewarn "Building using a compiler other than clang may result in broken atomics" + ewarn "library. Enable USE=clang unless you have a very good reason not to." + fi +} + +pkg_setup() { + if target_is_not_host || tc-is-cross-compiler ; then + # strips vars like CFLAGS="-march=x86_64-v3" for non-x86 architectures + CHOST=${CTARGET} strip-unsupported-flags + # overrides host docs otherwise + DOCS=() + fi + python-any-r1_pkg_setup +} + +test_compiler() { + target_is_not_host && return + $(tc-getCC) ${CFLAGS} ${LDFLAGS} "${@}" -o /dev/null -x c - \ + <<<'int main() { return 0; }' &>/dev/null +} + +src_configure() { + llvm_prepend_path "${LLVM_MAJOR}" + + # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844 + use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG" + + # pre-set since we need to pass it to cmake + BUILD_DIR=${WORKDIR}/${P}_build + + if use clang && ! is_crosspkg; then + # Only do this conditionally to allow overriding with + # e.g. CC=clang-13 in case of breakage + if ! tc-is-clang ; then + local -x CC=${CHOST}-clang + local -x CXX=${CHOST}-clang++ + fi + + strip-unsupported-flags + fi + + if ! is_crosspkg && ! test_compiler ; then + local nolib_flags=( -nodefaultlibs -lc ) + + if test_compiler "${nolib_flags[@]}"; then + local -x LDFLAGS="${LDFLAGS} ${nolib_flags[*]}" + ewarn "${CC} seems to lack runtime, trying with ${nolib_flags[*]}" + elif test_compiler "${nolib_flags[@]}" -nostartfiles; then + # Avoiding -nostartfiles earlier on for bug #862540, + # and set available entry symbol for bug #862798. + nolib_flags+=( -nostartfiles -e main ) + + local -x LDFLAGS="${LDFLAGS} ${nolib_flags[*]}" + ewarn "${CC} seems to lack runtime, trying with ${nolib_flags[*]}" + fi + fi + + local mycmakeargs=( + -DCOMPILER_RT_INSTALL_PATH="${EPREFIX}/usr/lib/clang/${LLVM_MAJOR}" + + -DCOMPILER_RT_EXCLUDE_ATOMIC_BUILTIN=$(usex !atomic-builtins) + -DCOMPILER_RT_INCLUDE_TESTS=$(usex test) + -DCOMPILER_RT_BUILD_CTX_PROFILE=OFF + -DCOMPILER_RT_BUILD_LIBFUZZER=OFF + -DCOMPILER_RT_BUILD_MEMPROF=OFF + -DCOMPILER_RT_BUILD_ORC=OFF + -DCOMPILER_RT_BUILD_PROFILE=OFF + -DCOMPILER_RT_BUILD_SANITIZERS=OFF + -DCOMPILER_RT_BUILD_XRAY=OFF + + -DPython3_EXECUTABLE="${PYTHON}" + ) + + if use amd64 && ! target_is_not_host; then + mycmakeargs+=( + -DCAN_TARGET_i386=$(usex abi_x86_32) + -DCAN_TARGET_x86_64=$(usex abi_x86_64) + ) + fi + + if is_crosspkg; then + # Needed to target built libc headers + export CFLAGS="${CFLAGS} -isystem /usr/${CTARGET}/usr/include" + mycmakeargs+=( + # Without this, the compiler will compile a test program + # and fail due to no builtins. + -DCMAKE_C_COMPILER_WORKS=1 + -DCMAKE_CXX_COMPILER_WORKS=1 + + # Without this, compiler-rt install location is not unique + # to target triples, only to architecture. + # Needed if you want to target multiple libcs for one arch. + -DLLVM_ENABLE_PER_TARGET_RUNTIME_DIR=ON + + -DCMAKE_ASM_COMPILER_TARGET="${CTARGET}" + -DCMAKE_C_COMPILER_TARGET="${CTARGET}" + -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON + ) + fi + + if use prefix && [[ "${CHOST}" == *-darwin* ]] ; then + mycmakeargs+=( + # setting -isysroot is disabled with compiler-rt-prefix-paths.patch + # this allows adding arm64 support using SDK in EPREFIX + -DDARWIN_macosx_CACHED_SYSROOT="${EPREFIX}/MacOSX.sdk" + # Set version based on the SDK in EPREFIX. + # This disables i386 for SDK >= 10.15 + -DDARWIN_macosx_OVERRIDE_SDK_VERSION="$(realpath ${EPREFIX}/MacOSX.sdk | sed -e 's/.*MacOSX\(.*\)\.sdk/\1/')" + # Use our libtool instead of looking it up with xcrun + -DCMAKE_LIBTOOL="${EPREFIX}/usr/bin/${CHOST}-libtool" + ) + fi + + if use test; then + mycmakeargs+=( + -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" + -DLLVM_LIT_ARGS="$(get_lit_flags)" + + -DCOMPILER_RT_TEST_COMPILER="${EPREFIX}/usr/lib/llvm/${LLVM_MAJOR}/bin/clang" + -DCOMPILER_RT_TEST_CXX_COMPILER="${EPREFIX}/usr/lib/llvm/${LLVM_MAJOR}/bin/clang++" + ) + fi + + cmake_src_configure +} + +src_test() { + # respect TMPDIR! + local -x LIT_PRESERVES_TMP=1 + + cmake_build check-builtins +} diff --git a/llvm-runtimes/libcxx/Manifest b/llvm-runtimes/libcxx/Manifest index bb521067c738..241a97826893 100644 --- a/llvm-runtimes/libcxx/Manifest +++ b/llvm-runtimes/libcxx/Manifest @@ -13,6 +13,7 @@ DIST llvm-project-19.1.4.src.tar.xz.sig 438 BLAKE2B b0925bdb761046d69779e0b035e2 DIST llvm-project-19.1.5.src.tar.xz 141243716 BLAKE2B 228fc66ab688abfc16f31b2cd83163b81ef61604ace21eab69a1776f0dc88cbe8fa831162205849e5be3975a214136399572b4ad1b908986e37b2d38a1a7fa5d SHA512 648854e9c91fdcc5c677ce3800e046f2060b998a45cf9f7eebe02898431b3924f9348b6fc366102cd4fdda72dcb8f32076f98aa69927e0e20b3f1007fba10b22 DIST llvm-project-19.1.5.src.tar.xz.sig 438 BLAKE2B 1d40a5c5405f99ef86e3360f9ea153afd1ae4001697210fd799a988113e8a3cef39e2c4794edd9332f384d8490f4ce2ab6bee6d98f794f84775807f833b81c0a SHA512 a438c86ce882eb1ac3e50842937068794ed162bb1b7ded68a2fe3ec2ab4f57cc38aee667cfb46afe6da22eef7ed1cb65820a473f63bd5a0dc6aad41df7bfad54 DIST llvm-project-32f7f0010bca99ee4bd917f57272733fb2bf3bd9.tar.gz 223983502 BLAKE2B fd3e6b0b795abc42568ef98fa774d927029c18838a5d0f34eaa66c37976444a63f2fc5d883f3bf3a98533f51e387936f1c659230f31c757d26153425696a16cd SHA512 65a345ad5b77c627008f759947e5e9f28a62c8992d7146113e0446e5849feaf9088c15c8b22ca0824af5b927d6a417f5326258b489fb8ccea78ec9e0e0fe8fba +DIST llvm-project-49a5ad8e5714fd404210279303acc97b495d66d0.tar.gz 224456065 BLAKE2B 0077b9d37c479ac6190cc4b897cc35d6f1f3e6a772cd0620bcb1006afc19377e9968e38fb9d9adffe316e85290c9045deecbf9bf62b440c55968634b442edb31 SHA512 45d779eb27c230f656fda47c85127381cab8c8f7f75d77411c6960269f8aad5fa3c99c024a98ab8a349da1c88ad9d892cc82f91a6f344b791b281449031ae49a EBUILD libcxx-15.0.7-r1.ebuild 5288 BLAKE2B 5c619de6d028fbce7abc50adec16c5c825ef39d7d7477b09aa02150e089b963928a54dcb5a9b7f02ddfa7827e1cccea35cfef7640561214bc16d0b81ea0d8e72 SHA512 410ae6f3ece045192cd6eb589c06f11a5b71d3e6fcfe882793d6a910ea0fa10ce5904874c7488280c5383b36954189255799a745be7aa98cfd27af6338dcfd66 EBUILD libcxx-16.0.6.ebuild 5305 BLAKE2B 0a625868cac2747c0cae6cd722d238ad6f9ec80a4cfbaa1e927990975f6f40a509af4e227baa0b7c562123fc04f7059a6fe71f19061727cf68b22c789741e470 SHA512 f337115153389372c38d2fece3642f707fd0516b913626cb71b111850e853a4dafdcad98e852de01fb62e99044e197958319ef1179ffa248805eb1f27efc09ae EBUILD libcxx-17.0.6.ebuild 5285 BLAKE2B b435edac66c052e8d26b3d55dce6027d876c33b3c14c20198f96c2264e4eee06da924b158beaeab6a4013f0f5dcfb8bec70ef507e022c14f320c60995f613c87 SHA512 e9b50cad8732ef95ae36f212d1eeafe6e266a7f65f31f6d436f3e04dabaa4753989f787c4b2d4e35524f817090becacacf95619bbaaf2731762fec078e3d3693 @@ -21,4 +22,5 @@ EBUILD libcxx-19.1.4.ebuild 5181 BLAKE2B 6a1dd56caaa53fd38d9ee3d10baf655f391470a EBUILD libcxx-19.1.5.ebuild 5186 BLAKE2B 932ffaac4d36b23bcf60f83601a1d4d969c828d3ca6bb53fcc930aa912d2264bb6d052c6da6343c2e894e697754d6fb7b04d3256b6b48888008d5e14927441e5 SHA512 a0f9ed34330ea4057e21ec663e30cf0e98efbeb09c6993f8316789dc47750dc3d5d29b147c09aebdb38f057c3ff727938c1a5b36ecedd9048a7371e272a408a6 EBUILD libcxx-20.0.0.9999.ebuild 5363 BLAKE2B 5b31c35a16136e3d0459d5c3d2a0c2bf7fb1e20527442c0492b4731eff382d5f0e3f49eff8b561e39f0a86122762c481002fd64d1dcb415126d49759a4b0798c SHA512 f3c0c44fe38d292a2cddf1b901d40bee9fdb41627fa395d107a04ac55be04c86b2389e18c33cdab649eaa8db30f78c998da159393599fdf7b517984c332088f6 EBUILD libcxx-20.0.0_pre20241207.ebuild 5363 BLAKE2B 5b31c35a16136e3d0459d5c3d2a0c2bf7fb1e20527442c0492b4731eff382d5f0e3f49eff8b561e39f0a86122762c481002fd64d1dcb415126d49759a4b0798c SHA512 f3c0c44fe38d292a2cddf1b901d40bee9fdb41627fa395d107a04ac55be04c86b2389e18c33cdab649eaa8db30f78c998da159393599fdf7b517984c332088f6 +EBUILD libcxx-20.0.0_pre20241215.ebuild 5363 BLAKE2B 5b31c35a16136e3d0459d5c3d2a0c2bf7fb1e20527442c0492b4731eff382d5f0e3f49eff8b561e39f0a86122762c481002fd64d1dcb415126d49759a4b0798c SHA512 f3c0c44fe38d292a2cddf1b901d40bee9fdb41627fa395d107a04ac55be04c86b2389e18c33cdab649eaa8db30f78c998da159393599fdf7b517984c332088f6 MISC metadata.xml 603 BLAKE2B ed0b70336793f05ecd2c3412ccc5d25800d7aab1ed5a10223c1b181858174f87c3f87be6785cb6323b3c6413e88787d1d28347965255cd214a8ff2f0ac534de9 SHA512 34bfa522496f4c220a44f09d76562680d1a0465ee10ece62f2e96a383f70e7284549e60cbbba52c8dee37f743ee17b11777008d59f169d31555edce2261cf063 diff --git a/llvm-runtimes/libcxx/libcxx-20.0.0_pre20241215.ebuild b/llvm-runtimes/libcxx/libcxx-20.0.0_pre20241215.ebuild new file mode 100644 index 000000000000..9c07b6d01774 --- /dev/null +++ b/llvm-runtimes/libcxx/libcxx-20.0.0_pre20241215.ebuild @@ -0,0 +1,208 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..13} ) +inherit cmake-multilib flag-o-matic llvm.org llvm-utils python-any-r1 +inherit toolchain-funcs + +DESCRIPTION="New implementation of the C++ standard library, targeting C++11" +HOMEPAGE="https://libcxx.llvm.org/" + +LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" +SLOT="0" +IUSE="+clang +libcxxabi +static-libs test" +REQUIRED_USE="test? ( clang )" +RESTRICT="!test? ( test )" + +RDEPEND=" + libcxxabi? ( + ~llvm-runtimes/libcxxabi-${PV}[static-libs?,${MULTILIB_USEDEP}] + ) + !libcxxabi? ( >=sys-devel/gcc-4.7:=[cxx] ) +" +DEPEND=" + ${RDEPEND} + llvm-core/llvm:${LLVM_MAJOR} +" +BDEPEND=" + clang? ( + llvm-core/clang:${LLVM_MAJOR} + ) + !test? ( + ${PYTHON_DEPS} + ) + test? ( + dev-debug/gdb[python] + $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]') + ) +" + +LLVM_COMPONENTS=( + runtimes libcxx{,abi} libc llvm/{cmake,utils/llvm-lit} cmake +) +llvm.org_set_globals + +python_check_deps() { + use test || return 0 + python_has_version "dev-python/lit[${PYTHON_USEDEP}]" +} + +pkg_setup() { + python-any-r1_pkg_setup + + if ! use libcxxabi && ! tc-is-gcc ; then + eerror "To build ${PN} against libsupc++, you have to use gcc. Other" + eerror "compilers are not supported. Please set CC=gcc and CXX=g++" + eerror "and try again." + die + fi +} + +test_compiler() { + $(tc-getCXX) ${CXXFLAGS} ${LDFLAGS} "${@}" -o /dev/null -x c++ - \ + <<<'int main() { return 0; }' &>/dev/null +} + +src_configure() { + llvm_prepend_path "${LLVM_MAJOR}" + + # note: we need to do this before multilib kicks in since it will + # alter the CHOST + local cxxabi cxxabi_incs + if use libcxxabi; then + cxxabi=system-libcxxabi + cxxabi_incs="${EPREFIX}/usr/include/c++/v1" + else + local gcc_inc="${EPREFIX}/usr/lib/gcc/${CHOST}/$(gcc-fullversion)/include/g++-v$(gcc-major-version)" + cxxabi=libsupc++ + cxxabi_incs="${gcc_inc};${gcc_inc}/${CHOST}" + fi + + multilib-minimal_src_configure +} + +multilib_src_configure() { + if use clang; then + local -x CC=${CHOST}-clang + local -x CXX=${CHOST}-clang++ + strip-unsupported-flags + fi + + # link to compiler-rt + local use_compiler_rt=OFF + [[ $(tc-get-c-rtlib) == compiler-rt ]] && use_compiler_rt=ON + + # bootstrap: cmake is unhappy if compiler can't link to stdlib + local nolib_flags=( -nodefaultlibs -lc ) + if ! test_compiler; then + if test_compiler "${nolib_flags[@]}"; then + local -x LDFLAGS="${LDFLAGS} ${nolib_flags[*]}" + ewarn "${CXX} seems to lack runtime, trying with ${nolib_flags[*]}" + fi + fi + + local libdir=$(get_libdir) + local mycmakeargs=( + -DCMAKE_CXX_COMPILER_TARGET="${CHOST}" + -DPython3_EXECUTABLE="${PYTHON}" + -DLLVM_ENABLE_RUNTIMES=libcxx + -DLLVM_INCLUDE_TESTS=OFF + -DLLVM_LIBDIR_SUFFIX=${libdir#lib} + + -DLIBCXX_ENABLE_SHARED=ON + -DLIBCXX_ENABLE_STATIC=$(usex static-libs) + -DLIBCXX_CXX_ABI=${cxxabi} + -DLIBCXX_CXX_ABI_INCLUDE_PATHS=${cxxabi_incs} + # we're using our own mechanism for generating linker scripts + -DLIBCXX_ENABLE_ABI_LINKER_SCRIPT=OFF + -DLIBCXX_HAS_MUSL_LIBC=$(usex elibc_musl) + -DLIBCXX_INCLUDE_BENCHMARKS=OFF + -DLIBCXX_INCLUDE_TESTS=$(usex test) + -DLIBCXX_INSTALL_MODULES=ON + -DLIBCXX_USE_COMPILER_RT=${use_compiler_rt} + # this is broken with standalone builds, and also meaningless + -DLIBCXXABI_USE_LLVM_UNWINDER=OFF + ) + + if use test; then + mycmakeargs+=( + -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" + -DLLVM_LIT_ARGS="$(get_lit_flags)" + -DPython3_EXECUTABLE="${PYTHON}" + ) + fi + cmake_src_configure +} + +multilib_src_compile() { + cmake_src_compile + if [[ ${CHOST} != *-darwin* ]] ; then + gen_shared_ldscript + use static-libs && gen_static_ldscript + fi +} + +multilib_src_test() { + local -x LIT_PRESERVES_TMP=1 + cmake_build install-cxx-test-suite-prefix + cp "${BUILD_DIR}"/{lib,libcxx/test-suite-install/$(get_libdir)}/libc++_shared.so || die + if use static-libs; then + cp "${BUILD_DIR}"/{lib,libcxx/test-suite-install/$(get_libdir)}/libc++_static.a || die + fi + cmake_build check-cxx +} + +multilib_src_install() { + cmake_src_install + # since we've replaced libc++.{a,so} with ldscripts, now we have to + # install the extra symlinks + if [[ ${CHOST} != *-darwin* ]] ; then + dolib.so lib/libc++_shared.so + use static-libs && dolib.a lib/libc++_static.a + fi +} + +# Usage: deps +gen_ldscript() { + local output_format + output_format=$($(tc-getCC) ${CFLAGS} ${LDFLAGS} -Wl,--verbose 2>&1 | sed -n 's/^OUTPUT_FORMAT("\([^"]*\)",.*/\1/p') + [[ -n ${output_format} ]] && output_format="OUTPUT_FORMAT ( ${output_format} )" + + cat <<-END_LDSCRIPT +/* GNU ld script + Include missing dependencies +*/ +${output_format} +GROUP ( $@ ) +END_LDSCRIPT +} + +gen_static_ldscript() { + # Move it first. + mv lib/libc++{,_static}.a || die + # Generate libc++.a ldscript for inclusion of its dependencies so that + # clang++ -stdlib=libc++ -static works out of the box. + local deps=( + libc++_static.a + $(usex libcxxabi libc++abi.a libsupc++.a) + ) + # On Linux/glibc it does not link without libpthread or libdl. It is + # fine on FreeBSD. + use elibc_glibc && deps+=( libpthread.a libdl.a ) + + gen_ldscript "${deps[*]}" > lib/libc++.a || die +} + +gen_shared_ldscript() { + # Move it first. + mv lib/libc++{,_shared}.so || die + local deps=( + libc++_shared.so + # libsupc++ doesn't have a shared version + $(usex libcxxabi libc++abi.so libsupc++.a) + ) + + gen_ldscript "${deps[*]}" > lib/libc++.so || die +} diff --git a/llvm-runtimes/libcxxabi/Manifest b/llvm-runtimes/libcxxabi/Manifest index 81ef27aedf26..ed75c2783341 100644 --- a/llvm-runtimes/libcxxabi/Manifest +++ b/llvm-runtimes/libcxxabi/Manifest @@ -11,6 +11,7 @@ DIST llvm-project-19.1.4.src.tar.xz.sig 438 BLAKE2B b0925bdb761046d69779e0b035e2 DIST llvm-project-19.1.5.src.tar.xz 141243716 BLAKE2B 228fc66ab688abfc16f31b2cd83163b81ef61604ace21eab69a1776f0dc88cbe8fa831162205849e5be3975a214136399572b4ad1b908986e37b2d38a1a7fa5d SHA512 648854e9c91fdcc5c677ce3800e046f2060b998a45cf9f7eebe02898431b3924f9348b6fc366102cd4fdda72dcb8f32076f98aa69927e0e20b3f1007fba10b22 DIST llvm-project-19.1.5.src.tar.xz.sig 438 BLAKE2B 1d40a5c5405f99ef86e3360f9ea153afd1ae4001697210fd799a988113e8a3cef39e2c4794edd9332f384d8490f4ce2ab6bee6d98f794f84775807f833b81c0a SHA512 a438c86ce882eb1ac3e50842937068794ed162bb1b7ded68a2fe3ec2ab4f57cc38aee667cfb46afe6da22eef7ed1cb65820a473f63bd5a0dc6aad41df7bfad54 DIST llvm-project-32f7f0010bca99ee4bd917f57272733fb2bf3bd9.tar.gz 223983502 BLAKE2B fd3e6b0b795abc42568ef98fa774d927029c18838a5d0f34eaa66c37976444a63f2fc5d883f3bf3a98533f51e387936f1c659230f31c757d26153425696a16cd SHA512 65a345ad5b77c627008f759947e5e9f28a62c8992d7146113e0446e5849feaf9088c15c8b22ca0824af5b927d6a417f5326258b489fb8ccea78ec9e0e0fe8fba +DIST llvm-project-49a5ad8e5714fd404210279303acc97b495d66d0.tar.gz 224456065 BLAKE2B 0077b9d37c479ac6190cc4b897cc35d6f1f3e6a772cd0620bcb1006afc19377e9968e38fb9d9adffe316e85290c9045deecbf9bf62b440c55968634b442edb31 SHA512 45d779eb27c230f656fda47c85127381cab8c8f7f75d77411c6960269f8aad5fa3c99c024a98ab8a349da1c88ad9d892cc82f91a6f344b791b281449031ae49a EBUILD libcxxabi-15.0.7.ebuild 2917 BLAKE2B af1df60659fa913046b3a1102b6368af08de3cefb7b457dbbc64fdd748a26a3ad0d291ec761b1b3caed1763545dadb5e41a7c5a514f7c79ed69abd95035409d9 SHA512 3ec9832e0fd0dedb813c0e8d64851af3009fd260d7b1f875b6658a65518f354afdede9de8b3c60fa16af441f26dc72b233c7666d481510cda9eeb8c241a253e0 EBUILD libcxxabi-16.0.6.ebuild 2937 BLAKE2B 001f82d6a06914ec59b28d1ba9d4696ab8f4a72ad14ca4bacaabef90c9feb0f17655435c62cbcc18169b43e0f212c21cee6defa975029cb57f4f38123339ae97 SHA512 85a6f852d3ec5594e2124a01ab1aa40fda558f810be45e51c12d886aaf6d79cf51fbd82436bb811a78ccb778ad27cadf7cdc6acb77fb84f2258d079a1fb9cb58 EBUILD libcxxabi-17.0.6.ebuild 2937 BLAKE2B 001f82d6a06914ec59b28d1ba9d4696ab8f4a72ad14ca4bacaabef90c9feb0f17655435c62cbcc18169b43e0f212c21cee6defa975029cb57f4f38123339ae97 SHA512 85a6f852d3ec5594e2124a01ab1aa40fda558f810be45e51c12d886aaf6d79cf51fbd82436bb811a78ccb778ad27cadf7cdc6acb77fb84f2258d079a1fb9cb58 @@ -19,4 +20,5 @@ EBUILD libcxxabi-19.1.4.ebuild 2764 BLAKE2B 2d77ecebc56a9d81fd90fa9e923c0dae7caf EBUILD libcxxabi-19.1.5.ebuild 2769 BLAKE2B 9bbc70e057a776273d2d20ae20b0d46d56e7ea7adc6f1ce2a6f2357ed94911a8474b65a9b7842788c02090c7aff2f195e278437d0ff4d04b139ef54a17a0808d SHA512 bd1d127e9ab6f5c2e556a6b129674671462701390d46ead9d95c71b0f973fd380d1aa883d860bf754d0c698c8123896127696f9bd4525e042f4465c2ba40f449 EBUILD libcxxabi-20.0.0.9999.ebuild 2668 BLAKE2B 9ffadc339e9408cc9ad1a4994745ffc86f162b9ed7995e384aa77ac3da9abd25034179886b5e206b2487c65ee9a0451a682ca55b6ba7cd7f30154043cef82c38 SHA512 013bf53798a8c0b60aeae1766b89f5a8947af767c85b8bcddd5a5c004e5ea1b439466becf50fb69bd207807b83910a2cf21d64c4a528ea799043b8b684199cf2 EBUILD libcxxabi-20.0.0_pre20241207.ebuild 2668 BLAKE2B 9ffadc339e9408cc9ad1a4994745ffc86f162b9ed7995e384aa77ac3da9abd25034179886b5e206b2487c65ee9a0451a682ca55b6ba7cd7f30154043cef82c38 SHA512 013bf53798a8c0b60aeae1766b89f5a8947af767c85b8bcddd5a5c004e5ea1b439466becf50fb69bd207807b83910a2cf21d64c4a528ea799043b8b684199cf2 +EBUILD libcxxabi-20.0.0_pre20241215.ebuild 2668 BLAKE2B 9ffadc339e9408cc9ad1a4994745ffc86f162b9ed7995e384aa77ac3da9abd25034179886b5e206b2487c65ee9a0451a682ca55b6ba7cd7f30154043cef82c38 SHA512 013bf53798a8c0b60aeae1766b89f5a8947af767c85b8bcddd5a5c004e5ea1b439466becf50fb69bd207807b83910a2cf21d64c4a528ea799043b8b684199cf2 MISC metadata.xml 438 BLAKE2B 0a830a06a53a6cdaf138ad7620fe366fae05c1c1451267d6a58caf7da5ce8f5a26d302fab53b9460920074ab5a65991d3bd24fde087809e8dc12188dd94c7676 SHA512 d53e13c497569636fb453a159c5ca5ddfabf8e5debd5f92e5149c52d54c876753842ab73293d6d08e2d9b279363b4f0c743eed3a5027a61246c6b60496be8e87 diff --git a/llvm-runtimes/libcxxabi/libcxxabi-20.0.0_pre20241215.ebuild b/llvm-runtimes/libcxxabi/libcxxabi-20.0.0_pre20241215.ebuild new file mode 100644 index 000000000000..d2226d289eb3 --- /dev/null +++ b/llvm-runtimes/libcxxabi/libcxxabi-20.0.0_pre20241215.ebuild @@ -0,0 +1,109 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..13} ) +inherit cmake-multilib flag-o-matic llvm.org llvm-utils python-any-r1 +inherit 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" +IUSE="+clang +static-libs test" +REQUIRED_USE="test? ( clang )" +RESTRICT="!test? ( test )" + +# in 15.x, cxxabi.h is moving from libcxx to libcxxabi +RDEPEND+=" + !<llvm-runtimes/libcxx-15 +" +DEPEND=" + ${RDEPEND} + llvm-core/llvm:${LLVM_MAJOR} +" +BDEPEND=" + clang? ( + llvm-core/clang:${LLVM_MAJOR} + ) + !test? ( + ${PYTHON_DEPS} + ) + test? ( + $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]') + ) +" + +LLVM_COMPONENTS=( runtimes libcxx{abi,} llvm/cmake cmake ) +LLVM_TEST_COMPONENTS=( libc llvm/utils/llvm-lit ) +llvm.org_set_globals + +python_check_deps() { + use test || return 0 + python_has_version "dev-python/lit[${PYTHON_USEDEP}]" +} + +multilib_src_configure() { + llvm_prepend_path "${LLVM_MAJOR}" + + if use clang; then + local -x CC=${CHOST}-clang + local -x CXX=${CHOST}-clang++ + strip-unsupported-flags + fi + + # link to compiler-rt + local use_compiler_rt=OFF + [[ $(tc-get-c-rtlib) == compiler-rt ]] && use_compiler_rt=ON + + local libdir=$(get_libdir) + local mycmakeargs=( + -DCMAKE_CXX_COMPILER_TARGET="${CHOST}" + -DPython3_EXECUTABLE="${PYTHON}" + -DLLVM_ENABLE_RUNTIMES="libcxxabi;libcxx" + -DLLVM_INCLUDE_TESTS=OFF + -DLLVM_LIBDIR_SUFFIX=${libdir#lib} + -DLIBCXXABI_ENABLE_SHARED=ON + -DLIBCXXABI_ENABLE_STATIC=$(usex static-libs) + -DLIBCXXABI_INCLUDE_TESTS=$(usex test) + -DLIBCXXABI_USE_COMPILER_RT=${use_compiler_rt} + + # upstream is omitting standard search path for this + # probably because gcc & clang are bundling their own unwind.h + -DLIBCXXABI_LIBUNWIND_INCLUDES="${EPREFIX}"/usr/include + # this is broken with standalone builds, and also meaningless + -DLIBCXXABI_USE_LLVM_UNWINDER=OFF + + -DLIBCXX_ENABLE_SHARED=ON + -DLIBCXX_ENABLE_STATIC=OFF + -DLIBCXX_CXX_ABI=libcxxabi + -DLIBCXX_ENABLE_ABI_LINKER_SCRIPT=OFF + -DLIBCXX_HAS_MUSL_LIBC=$(usex elibc_musl) + -DLIBCXX_HAS_GCC_S_LIB=OFF + -DLIBCXX_INCLUDE_BENCHMARKS=OFF + -DLIBCXX_INCLUDE_TESTS=OFF + ) + if use test; then + mycmakeargs+=( + -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" + -DLLVM_LIT_ARGS="$(get_lit_flags)" + -DPython3_EXECUTABLE="${PYTHON}" + ) + fi + cmake_src_configure +} + +multilib_src_compile() { + cmake_build cxxabi +} + +multilib_src_test() { + local -x LIT_PRESERVES_TMP=1 + cmake_build check-cxxabi +} + +multilib_src_install() { + DESTDIR="${D}" cmake_build install-cxxabi +} diff --git a/llvm-runtimes/libunwind/Manifest b/llvm-runtimes/libunwind/Manifest index e3c30a327d95..70577e7d4d55 100644 --- a/llvm-runtimes/libunwind/Manifest +++ b/llvm-runtimes/libunwind/Manifest @@ -11,6 +11,7 @@ DIST llvm-project-19.1.4.src.tar.xz.sig 438 BLAKE2B b0925bdb761046d69779e0b035e2 DIST llvm-project-19.1.5.src.tar.xz 141243716 BLAKE2B 228fc66ab688abfc16f31b2cd83163b81ef61604ace21eab69a1776f0dc88cbe8fa831162205849e5be3975a214136399572b4ad1b908986e37b2d38a1a7fa5d SHA512 648854e9c91fdcc5c677ce3800e046f2060b998a45cf9f7eebe02898431b3924f9348b6fc366102cd4fdda72dcb8f32076f98aa69927e0e20b3f1007fba10b22 DIST llvm-project-19.1.5.src.tar.xz.sig 438 BLAKE2B 1d40a5c5405f99ef86e3360f9ea153afd1ae4001697210fd799a988113e8a3cef39e2c4794edd9332f384d8490f4ce2ab6bee6d98f794f84775807f833b81c0a SHA512 a438c86ce882eb1ac3e50842937068794ed162bb1b7ded68a2fe3ec2ab4f57cc38aee667cfb46afe6da22eef7ed1cb65820a473f63bd5a0dc6aad41df7bfad54 DIST llvm-project-32f7f0010bca99ee4bd917f57272733fb2bf3bd9.tar.gz 223983502 BLAKE2B fd3e6b0b795abc42568ef98fa774d927029c18838a5d0f34eaa66c37976444a63f2fc5d883f3bf3a98533f51e387936f1c659230f31c757d26153425696a16cd SHA512 65a345ad5b77c627008f759947e5e9f28a62c8992d7146113e0446e5849feaf9088c15c8b22ca0824af5b927d6a417f5326258b489fb8ccea78ec9e0e0fe8fba +DIST llvm-project-49a5ad8e5714fd404210279303acc97b495d66d0.tar.gz 224456065 BLAKE2B 0077b9d37c479ac6190cc4b897cc35d6f1f3e6a772cd0620bcb1006afc19377e9968e38fb9d9adffe316e85290c9045deecbf9bf62b440c55968634b442edb31 SHA512 45d779eb27c230f656fda47c85127381cab8c8f7f75d77411c6960269f8aad5fa3c99c024a98ab8a349da1c88ad9d892cc82f91a6f344b791b281449031ae49a EBUILD libunwind-15.0.7.ebuild 3033 BLAKE2B 6e08d31003b5fc913e2110be4fe5a66bb91a89d48b26e570576cb804d6dbc23ea94b5b34ab9aea9c6ad9aacb5420b7a52ab8d6832b57ee24f02b98daae835166 SHA512 e156a322ae7f657ba3634ae07c6332e06ea033deb9235de8f36595dba1823c67fe1bb035f99de51f454e8c036239ea4835fd25719d199231c635ce4fd71dff16 EBUILD libunwind-16.0.6-r1.ebuild 3440 BLAKE2B 046d1ad89188255e9d0622620b58e0255af6476ce7c23ab3053bb31cde58c6908fcf6558c237b18010d68d324a8bfc04860e80ad405ed17e934045f51053a603 SHA512 ebcc9d5bef24e5b4ede57b37b8c3e5bd4071801e5852562153db3f07fd16dc75ccef7e25b1f61082b3938f711bdafc981f970fbe054fa52a76e87ab0157c155c EBUILD libunwind-17.0.6.ebuild 3440 BLAKE2B 046d1ad89188255e9d0622620b58e0255af6476ce7c23ab3053bb31cde58c6908fcf6558c237b18010d68d324a8bfc04860e80ad405ed17e934045f51053a603 SHA512 ebcc9d5bef24e5b4ede57b37b8c3e5bd4071801e5852562153db3f07fd16dc75ccef7e25b1f61082b3938f711bdafc981f970fbe054fa52a76e87ab0157c155c @@ -19,4 +20,5 @@ EBUILD libunwind-19.1.4.ebuild 3407 BLAKE2B 3c1a8dcdb1c6c7e1bcc9103ede0994537dc9 EBUILD libunwind-19.1.5.ebuild 3413 BLAKE2B c164a16a0468fb8d33bbc4040a39c343e9799c5642afd88408c5c5e079cbf56654c3648f5591002d60f49533df3a879a0e18f8c2f74449f0fadf8eb0142a22b6 SHA512 b022e18a49c90a3041109df0f7547a044830907742afaef0fb35c4d4285a79a34e800f926dd11e86e03d3b94e62bcf7c9f88f41e44574bb95ab7c60564224911 EBUILD libunwind-20.0.0.9999.ebuild 3321 BLAKE2B f3fda113e68697815263dd9a53b6ac13a5573fee3f06a6b90e880902a5c099b560a39b2063db67e4ef8a8032231fc00b3ff5b07ec142b32f13481a5e16a8aabc SHA512 a13eab7ce217afbe629fd5324e9e450603bc59321f51c8b02082e28cf7b8ac918d43a1bd60b3db990a59b34f434dfd0e53ba3054b9baff3aa27670df8083f0b4 EBUILD libunwind-20.0.0_pre20241207.ebuild 3321 BLAKE2B f3fda113e68697815263dd9a53b6ac13a5573fee3f06a6b90e880902a5c099b560a39b2063db67e4ef8a8032231fc00b3ff5b07ec142b32f13481a5e16a8aabc SHA512 a13eab7ce217afbe629fd5324e9e450603bc59321f51c8b02082e28cf7b8ac918d43a1bd60b3db990a59b34f434dfd0e53ba3054b9baff3aa27670df8083f0b4 +EBUILD libunwind-20.0.0_pre20241215.ebuild 3321 BLAKE2B f3fda113e68697815263dd9a53b6ac13a5573fee3f06a6b90e880902a5c099b560a39b2063db67e4ef8a8032231fc00b3ff5b07ec142b32f13481a5e16a8aabc SHA512 a13eab7ce217afbe629fd5324e9e450603bc59321f51c8b02082e28cf7b8ac918d43a1bd60b3db990a59b34f434dfd0e53ba3054b9baff3aa27670df8083f0b4 MISC metadata.xml 438 BLAKE2B 2a36fbbc59e137056029c62aef6d167d9c82531c2582d7bad5cb13cc36e5c4c9518ffe8c56d06bbcfd97ad22eda71a8b776f3984195f53d06cf45659b438dc00 SHA512 4f18b054072d00e5440faa31a59f9ef587d035b5f25e30913f0b1449debee967fa794fae2548e87db3fb2177ce853ab075e1f11f3cc763f5d7fdf06147108845 diff --git a/llvm-runtimes/libunwind/libunwind-20.0.0_pre20241215.ebuild b/llvm-runtimes/libunwind/libunwind-20.0.0_pre20241215.ebuild new file mode 100644 index 000000000000..6d8a5629bb47 --- /dev/null +++ b/llvm-runtimes/libunwind/libunwind-20.0.0_pre20241215.ebuild @@ -0,0 +1,128 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..13} ) +inherit cmake-multilib flag-o-matic llvm.org llvm-utils python-any-r1 +inherit toolchain-funcs + +DESCRIPTION="C++ runtime stack unwinder from LLVM" +HOMEPAGE="https://llvm.org/docs/ExceptionHandling.html" + +LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" +SLOT="0" +IUSE="+clang +debug static-libs test" +REQUIRED_USE="test? ( clang )" +RESTRICT="!test? ( test )" + +RDEPEND=" + !sys-libs/libunwind +" +DEPEND=" + llvm-core/llvm:${LLVM_MAJOR} +" +BDEPEND=" + clang? ( + llvm-core/clang:${LLVM_MAJOR} + ) + !test? ( + ${PYTHON_DEPS} + ) + test? ( + $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]') + ) +" + +LLVM_COMPONENTS=( runtimes libunwind libcxx llvm/cmake cmake ) +LLVM_TEST_COMPONENTS=( libc libcxxabi llvm/utils/llvm-lit ) +llvm.org_set_globals + +python_check_deps() { + use test || return 0 + python_has_version "dev-python/lit[${PYTHON_USEDEP}]" +} + +multilib_src_configure() { + llvm_prepend_path "${LLVM_MAJOR}" + + local libdir=$(get_libdir) + + # https://github.com/llvm/llvm-project/issues/56825 + # also separately bug #863917 + filter-lto + + if use clang; then + local -x CC=${CHOST}-clang + local -x CXX=${CHOST}-clang++ + strip-unsupported-flags + fi + + # link to compiler-rt + # https://github.com/gentoo/gentoo/pull/21516 + local use_compiler_rt=OFF + [[ $(tc-get-c-rtlib) == compiler-rt ]] && use_compiler_rt=ON + + # Respect upstream build type assumptions (bug #910436) where they do: + # -DLIBUNWIND_ENABLE_ASSERTIONS=ON => + # -DCMAKE_BUILD_TYPE=DEBUG => -UNDEBUG + # -DCMAKE_BUILD_TYPE!=debug => -DNDEBUG + # -DLIBUNWIND_ENABLE_ASSERTIONS=OFF => + # -UNDEBUG + # See also https://github.com/llvm/llvm-project/issues/86#issuecomment-1649668826. + use debug || append-cppflags -DNDEBUG + + local mycmakeargs=( + -DCMAKE_CXX_COMPILER_TARGET="${CHOST}" + -DPython3_EXECUTABLE="${PYTHON}" + -DLLVM_ENABLE_RUNTIMES="libunwind" + -DLLVM_LIBDIR_SUFFIX=${libdir#lib} + -DLLVM_INCLUDE_TESTS=OFF + -DLIBUNWIND_ENABLE_ASSERTIONS=$(usex debug) + -DLIBUNWIND_ENABLE_STATIC=$(usex static-libs) + -DLIBUNWIND_INCLUDE_TESTS=$(usex test) + -DLIBUNWIND_INSTALL_HEADERS=ON + + # support non-native unwinding; given it's small enough, + # enable it unconditionally + -DLIBUNWIND_ENABLE_CROSS_UNWINDING=ON + + # avoid dependency on libgcc_s if compiler-rt is used + -DLIBUNWIND_USE_COMPILER_RT=${use_compiler_rt} + ) + if use test; then + mycmakeargs+=( + -DLLVM_ENABLE_RUNTIMES="libunwind;libcxxabi;libcxx" + -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit" + -DLLVM_LIT_ARGS="$(get_lit_flags)" + -DLIBUNWIND_LIBCXX_PATH="${WORKDIR}/libcxx" + + -DLIBCXXABI_LIBDIR_SUFFIX= + -DLIBCXXABI_ENABLE_SHARED=OFF + -DLIBCXXABI_ENABLE_STATIC=ON + -DLIBCXXABI_USE_LLVM_UNWINDER=ON + -DLIBCXXABI_INCLUDE_TESTS=OFF + + -DLIBCXX_LIBDIR_SUFFIX= + -DLIBCXX_ENABLE_SHARED=OFF + -DLIBCXX_ENABLE_STATIC=ON + -DLIBCXX_CXX_ABI=libcxxabi + -DLIBCXX_ENABLE_ABI_LINKER_SCRIPT=OFF + -DLIBCXX_HAS_MUSL_LIBC=$(usex elibc_musl) + -DLIBCXX_HAS_GCC_S_LIB=OFF + -DLIBCXX_INCLUDE_TESTS=OFF + -DLIBCXX_INCLUDE_BENCHMARKS=OFF + ) + fi + + cmake_src_configure +} + +multilib_src_test() { + local -x LIT_PRESERVES_TMP=1 + cmake_build check-unwind +} + +multilib_src_install() { + DESTDIR=${D} cmake_build install-unwind +} diff --git a/llvm-runtimes/offload/Manifest b/llvm-runtimes/offload/Manifest index ddaf663d0599..9b770d78dd6d 100644 --- a/llvm-runtimes/offload/Manifest +++ b/llvm-runtimes/offload/Manifest @@ -1,4 +1,6 @@ DIST llvm-project-32f7f0010bca99ee4bd917f57272733fb2bf3bd9.tar.gz 223983502 BLAKE2B fd3e6b0b795abc42568ef98fa774d927029c18838a5d0f34eaa66c37976444a63f2fc5d883f3bf3a98533f51e387936f1c659230f31c757d26153425696a16cd SHA512 65a345ad5b77c627008f759947e5e9f28a62c8992d7146113e0446e5849feaf9088c15c8b22ca0824af5b927d6a417f5326258b489fb8ccea78ec9e0e0fe8fba +DIST llvm-project-49a5ad8e5714fd404210279303acc97b495d66d0.tar.gz 224456065 BLAKE2B 0077b9d37c479ac6190cc4b897cc35d6f1f3e6a772cd0620bcb1006afc19377e9968e38fb9d9adffe316e85290c9045deecbf9bf62b440c55968634b442edb31 SHA512 45d779eb27c230f656fda47c85127381cab8c8f7f75d77411c6960269f8aad5fa3c99c024a98ab8a349da1c88ad9d892cc82f91a6f344b791b281449031ae49a EBUILD offload-20.0.0.9999.ebuild 3745 BLAKE2B c83224e4b837481682439d576e42024e2caab14c068943fdb60997f8dd8c305279c2d1b1e3b1953b77f4840a1df723bde7ffba367ca45e1dc896f321610ba2b7 SHA512 78bc62063fa73cfbe02eed2f2491b597e8be1618221b794403f1299dc3e65706b356bdfbaf82d6d88a7044055a423029e85a951d5e3459ce617cf801e1f26f3d EBUILD offload-20.0.0_pre20241207.ebuild 4098 BLAKE2B c51babc0900e4f8640140590a177ae855b6b64a62f9d18b2fe03ef0f576c596f363cd4505c843c9a0a257e2906eedba73bc2c27682bccb00dac08e0d2f641945 SHA512 33a224a18cbc45b9195b0b9729a2b57121bdb1aa297ba3a394306e1edb3794ac805c260c86bbf01662c6cd80dbafb571a578ceaaf4cf6b8b1bb7205ec423bb91 +EBUILD offload-20.0.0_pre20241215.ebuild 3745 BLAKE2B c83224e4b837481682439d576e42024e2caab14c068943fdb60997f8dd8c305279c2d1b1e3b1953b77f4840a1df723bde7ffba367ca45e1dc896f321610ba2b7 SHA512 78bc62063fa73cfbe02eed2f2491b597e8be1618221b794403f1299dc3e65706b356bdfbaf82d6d88a7044055a423029e85a951d5e3459ce617cf801e1f26f3d MISC metadata.xml 379 BLAKE2B 2b4c75d4ec6e126d887b736ea978c4b34683a347252f408c9d1f5f55c6c1bead7b7f9533812806f816538d8abaa00ded4d439dbe626d3f2cf09b78a3674e41bd SHA512 d49054d4b5a1a051d83f1ef397a7925fb36ee3092668d134e6ed5c1218bf5d67a43145b689709677643da070a783ec9f8705b37f15587475829fe185634af1d4 diff --git a/llvm-runtimes/offload/offload-20.0.0_pre20241215.ebuild b/llvm-runtimes/offload/offload-20.0.0_pre20241215.ebuild new file mode 100644 index 000000000000..66a73775d296 --- /dev/null +++ b/llvm-runtimes/offload/offload-20.0.0_pre20241215.ebuild @@ -0,0 +1,147 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..13} ) +inherit cmake flag-o-matic llvm.org python-any-r1 toolchain-funcs + +DESCRIPTION="OpenMP offloading support" +HOMEPAGE="https://openmp.llvm.org" + +LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" +SLOT="0/${LLVM_SOABI}" +IUSE="+debug ompt test llvm_targets_AMDGPU llvm_targets_NVPTX" +RESTRICT="!test? ( test )" + +RDEPEND=" + dev-libs/libffi:= + ~llvm-core/llvm-${PV} + ~llvm-runtimes/openmp-${PV}[ompt?] + llvm_targets_AMDGPU? ( dev-libs/rocr-runtime:= ) +" +DEPEND=" + ${RDEPEND} +" +# tests: +# - dev-python/lit provides the test runner +# - llvm-core/llvm provide test utils (e.g. FileCheck) +# - llvm-core/clang provides the compiler to run tests +BDEPEND=" + dev-lang/perl + virtual/pkgconfig + llvm_targets_AMDGPU? ( llvm-core/clang ) + llvm_targets_NVPTX? ( llvm-core/clang ) + test? ( + $(python_gen_any_dep ' + dev-python/lit[${PYTHON_USEDEP}] + ') + llvm-core/clang + ) +" +# TODO: can it be fixed to compile with gcc? +BDEPEND+=" + llvm-core/clang +" + +LLVM_COMPONENTS=( offload cmake runtimes/cmake libc/shared ) +LLVM_TEST_COMPONENTS=( openmp/cmake ) +llvm.org_set_globals + +pkg_pretend() { + if [[ ${LLVM_ALLOW_GPU_TESTING} ]]; then + ewarn "LLVM_ALLOW_GPU_TESTING set. This package will run tests against your" + ewarn "GPU if it is supported. Note that these tests may be flaky, fail or" + ewarn "hang, or even cause your GPU to crash (requiring a reboot)." + fi +} + +pkg_setup() { + if use test; then + python-any-r1_pkg_setup + fi +} + +src_configure() { + # TODO + local -x CC=${CHOST}-clang + local -x CXX=${CHOST}-clang++ + strip-unsupported-flags + + # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844 + use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG" + + local libdir="$(get_libdir)" + local ffi_cflags=$($(tc-getPKG_CONFIG) --cflags-only-I libffi) + local ffi_ldflags=$($(tc-getPKG_CONFIG) --libs-only-L libffi) + local plugins="host" + local gpus= + local build_devicertl=FALSE + + if has "${CHOST%%-*}" aarch64 powerpc64le x86_64; then + if use llvm_targets_AMDGPU; then + plugins+=";amdgpu" + build_devicertl=TRUE + gpus+="amdgpu" + fi + if use llvm_targets_NVPTX; then + plugins+=";cuda" + build_devicertl=TRUE + gpus+="nvptx" + fi + [[ ${gpus} == amdgpunvptx ]] && gpus=all + fi + + local mycmakeargs=( + -DOFFLOAD_LIBDIR_SUFFIX="${libdir#lib}" + -DLIBOMPTARGET_PLUGINS_TO_BUILD="${plugins}" + -DLIBOMPTARGET_OMPT_SUPPORT="$(usex ompt)" + -DLIBOMPTARGET_BUILD_DEVICERTL_BCLIB="${build_devicertl}" + + # this breaks building static target libs + -DBUILD_SHARED_LIBS=OFF + + -DFFI_INCLUDE_DIR="${ffi_cflags#-I}" + -DFFI_LIBRARY_DIR="${ffi_ldflags#-L}" + ) + + [[ ! ${LLVM_ALLOW_GPU_TESTING} ]] && mycmakeargs+=( + # prevent trying to access the GPU + -DLIBOMPTARGET_AMDGPU_ARCH=LIBOMPTARGET_AMDGPU_ARCH-NOTFOUND + -DLIBOMPTARGET_NVPTX_ARCH=LIBOMPTARGET_NVPTX_ARCH-NOTFOUND + ) + [[ -n ${gpus} ]] && mycmakeargs+=( + -DLIBOMPTARGET_DEVICE_ARCHITECTURES="${gpus}" + ) + use test && mycmakeargs+=( + # this project does not use standard LLVM cmake macros + -DOPENMP_LLVM_LIT_EXECUTABLE="${EPREFIX}/usr/bin/lit" + -DOPENMP_LIT_ARGS="$(get_lit_flags)" + + -DOPENMP_TEST_C_COMPILER="$(type -P "${CHOST}-clang")" + -DOPENMP_TEST_CXX_COMPILER="$(type -P "${CHOST}-clang++")" + ) + + cmake_src_configure + + if [[ -z ${gpus} ]]; then + # clang requires libomptarget.devicertl.a, but it can be empty + > "${BUILD_DIR}"/libomptarget.devicertl.a || die + fi +} + +src_test() { + # respect TMPDIR! + local -x LIT_PRESERVES_TMP=1 + + cmake_build check-offload +} + +src_install() { + cmake_src_install + + if [[ ! -f ${ED}/usr/$(get_libdir)/libomptarget.devicertl.a ]] + then + dolib.a "${BUILD_DIR}"/libomptarget.devicertl.a + fi +} diff --git a/llvm-runtimes/openmp/Manifest b/llvm-runtimes/openmp/Manifest index cea52d17d78a..33a9c966bc8c 100644 --- a/llvm-runtimes/openmp/Manifest +++ b/llvm-runtimes/openmp/Manifest @@ -12,6 +12,7 @@ DIST llvm-project-19.1.4.src.tar.xz.sig 438 BLAKE2B b0925bdb761046d69779e0b035e2 DIST llvm-project-19.1.5.src.tar.xz 141243716 BLAKE2B 228fc66ab688abfc16f31b2cd83163b81ef61604ace21eab69a1776f0dc88cbe8fa831162205849e5be3975a214136399572b4ad1b908986e37b2d38a1a7fa5d SHA512 648854e9c91fdcc5c677ce3800e046f2060b998a45cf9f7eebe02898431b3924f9348b6fc366102cd4fdda72dcb8f32076f98aa69927e0e20b3f1007fba10b22 DIST llvm-project-19.1.5.src.tar.xz.sig 438 BLAKE2B 1d40a5c5405f99ef86e3360f9ea153afd1ae4001697210fd799a988113e8a3cef39e2c4794edd9332f384d8490f4ce2ab6bee6d98f794f84775807f833b81c0a SHA512 a438c86ce882eb1ac3e50842937068794ed162bb1b7ded68a2fe3ec2ab4f57cc38aee667cfb46afe6da22eef7ed1cb65820a473f63bd5a0dc6aad41df7bfad54 DIST llvm-project-32f7f0010bca99ee4bd917f57272733fb2bf3bd9.tar.gz 223983502 BLAKE2B fd3e6b0b795abc42568ef98fa774d927029c18838a5d0f34eaa66c37976444a63f2fc5d883f3bf3a98533f51e387936f1c659230f31c757d26153425696a16cd SHA512 65a345ad5b77c627008f759947e5e9f28a62c8992d7146113e0446e5849feaf9088c15c8b22ca0824af5b927d6a417f5326258b489fb8ccea78ec9e0e0fe8fba +DIST llvm-project-49a5ad8e5714fd404210279303acc97b495d66d0.tar.gz 224456065 BLAKE2B 0077b9d37c479ac6190cc4b897cc35d6f1f3e6a772cd0620bcb1006afc19377e9968e38fb9d9adffe316e85290c9045deecbf9bf62b440c55968634b442edb31 SHA512 45d779eb27c230f656fda47c85127381cab8c8f7f75d77411c6960269f8aad5fa3c99c024a98ab8a349da1c88ad9d892cc82f91a6f344b791b281449031ae49a EBUILD openmp-15.0.7-r6.ebuild 3471 BLAKE2B a6878395f003d40944adfcabbf2247e1ab8833ae54d2a16824e5a99edff94f4a985d4fc706964b3f26b0e55166234be5e68aa63b1c5b819d35413e1c8b6438f8 SHA512 4c08ce8624b029cf516b364172616c7d2fa22355d937ca72f76fc881f1539a441302e08c9dad75496e7f0229bca61802ef449ecf429b067eb24118e46978bab9 EBUILD openmp-16.0.6.ebuild 3984 BLAKE2B b8507f3eea34c530720512140fa811036893bca9a3ebf25b2d2a90d6302759038017b7a9e0999865ede4e6a96a8bb558ffc46e330f34ca0ed60e741747a32259 SHA512 2dea5938ccc1d0e955fc8ff134ff03a54754b063932c5eece47769d21fe29d19ac9135c01d78d76d577faf7ba046548e57306f1a31fa747a392d241131c5707f EBUILD openmp-17.0.6.ebuild 4052 BLAKE2B 39b4f5a76895dbd711fc2a72ff7b7216a8afd29017fab649de5326a8a6cf0907f42899de853af60465816279de3780fe7cde33cdb3706a0be12abdbec34266d5 SHA512 66ece92770a60d74785584a4cbcbf7b5ac1e258c60d20d14a7dd8d140f460b343dda8dd67e2d6a91149fa650b42ca574504020e04358d544ae26e66f724911c6 @@ -20,4 +21,5 @@ EBUILD openmp-19.1.4.ebuild 2243 BLAKE2B 9387969f89d1416235a3e5b657167aa9de9f5e8 EBUILD openmp-19.1.5.ebuild 2248 BLAKE2B d95258d4cb8e02ea89ecfcc276c448f0b61c33cd287f8ad8afd5a28b2729a4d5b83555f55897352d954fb043b2a0d2febab84599e69ba58a6c7a9f85967f6c2f SHA512 0f3c0a6202973c659f6ec087ff501cd579132c94a3a2d6757be2cf32f0e947e59f3bfda718bd4bd6fd44cee0aa2eabaa3264e715f32e09a20e38c0d133a7053c EBUILD openmp-20.0.0.9999.ebuild 2163 BLAKE2B 1eba3d0fc3b379fc31839cba455be9cafb54b1b1a665410a13eb2ec518613f4819e26684ec6983fe2733f54026bda6319f5061ac18cca7befce82028e2263a5a SHA512 ea7f7232725b7b228a23b56819ad1ccd1c83b8f3ec4d4be72731baa9c5b868ddfd25e8bc63b8dda6599a1b45088a1a73a867c4494f12f3bf69c57a853f7b183f EBUILD openmp-20.0.0_pre20241207.ebuild 2163 BLAKE2B 1eba3d0fc3b379fc31839cba455be9cafb54b1b1a665410a13eb2ec518613f4819e26684ec6983fe2733f54026bda6319f5061ac18cca7befce82028e2263a5a SHA512 ea7f7232725b7b228a23b56819ad1ccd1c83b8f3ec4d4be72731baa9c5b868ddfd25e8bc63b8dda6599a1b45088a1a73a867c4494f12f3bf69c57a853f7b183f +EBUILD openmp-20.0.0_pre20241215.ebuild 2163 BLAKE2B 1eba3d0fc3b379fc31839cba455be9cafb54b1b1a665410a13eb2ec518613f4819e26684ec6983fe2733f54026bda6319f5061ac18cca7befce82028e2263a5a SHA512 ea7f7232725b7b228a23b56819ad1ccd1c83b8f3ec4d4be72731baa9c5b868ddfd25e8bc63b8dda6599a1b45088a1a73a867c4494f12f3bf69c57a853f7b183f MISC metadata.xml 883 BLAKE2B 127e896b82a49633a6866b33ca776ebe2dd149a5d04da4484a53186f219a85db0ab9d826bc1cc61d4df9fa54c9bcc546be070a0b28985174925fd947aa09cca2 SHA512 dc32cae01401feb93eede6506b3955c766ff19b44976fcc67277559b23ac151993377daeed9ba83b2dd71dbdeea330cd1208dcb0c9c5f56be270883b31f9b15f diff --git a/llvm-runtimes/openmp/openmp-20.0.0_pre20241215.ebuild b/llvm-runtimes/openmp/openmp-20.0.0_pre20241215.ebuild new file mode 100644 index 000000000000..ea3715dad3ed --- /dev/null +++ b/llvm-runtimes/openmp/openmp-20.0.0_pre20241215.ebuild @@ -0,0 +1,88 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..13} ) +inherit flag-o-matic cmake-multilib linux-info llvm.org python-single-r1 + +DESCRIPTION="OpenMP runtime library for LLVM/clang compiler" +HOMEPAGE="https://openmp.llvm.org" + +LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" +SLOT="0/${LLVM_SOABI}" +IUSE="+debug gdb-plugin hwloc ompt test" +REQUIRED_USE=" + gdb-plugin? ( ${PYTHON_REQUIRED_USE} ) +" +RESTRICT="!test? ( test )" + +RDEPEND=" + gdb-plugin? ( ${PYTHON_DEPS} ) + hwloc? ( >=sys-apps/hwloc-2.5:0=[${MULTILIB_USEDEP}] ) +" +# tests: +# - dev-python/lit provides the test runner +# - llvm-core/llvm provide test utils (e.g. FileCheck) +# - llvm-core/clang provides the compiler to run tests +DEPEND=" + ${RDEPEND} +" +BDEPEND=" + dev-lang/perl + test? ( + ${PYTHON_DEPS} + $(python_gen_cond_dep ' + dev-python/lit[${PYTHON_USEDEP}] + ') + llvm-core/clang + ) +" + +LLVM_COMPONENTS=( openmp cmake llvm/include ) +llvm.org_set_globals + +pkg_setup() { + if use gdb-plugin || use test; then + python-single-r1_pkg_setup + fi +} + +multilib_src_configure() { + # LTO causes issues in other packages building, #870127 + filter-lto + + # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844 + use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG" + + local libdir="$(get_libdir)" + local mycmakeargs=( + -DOPENMP_LIBDIR_SUFFIX="${libdir#lib}" + + -DLIBOMP_USE_HWLOC=$(usex hwloc) + -DLIBOMP_OMPD_GDB_SUPPORT=$(multilib_native_usex gdb-plugin) + -DLIBOMP_OMPT_SUPPORT=$(usex ompt) + + # do not install libgomp.so & libiomp5.so aliases + -DLIBOMP_INSTALL_ALIASES=OFF + # disable unnecessary hack copying stuff back to srcdir + -DLIBOMP_COPY_EXPORTS=OFF + ) + + use test && mycmakeargs+=( + # this project does not use standard LLVM cmake macros + -DOPENMP_LLVM_LIT_EXECUTABLE="${EPREFIX}/usr/bin/lit" + -DOPENMP_LIT_ARGS="$(get_lit_flags)" + + -DOPENMP_TEST_C_COMPILER="$(type -P "${CHOST}-clang")" + -DOPENMP_TEST_CXX_COMPILER="$(type -P "${CHOST}-clang++")" + ) + cmake_src_configure +} + +multilib_src_test() { + # respect TMPDIR! + local -x LIT_PRESERVES_TMP=1 + + cmake_build check-libomp +} |