summaryrefslogtreecommitdiff
path: root/sys-libs/libomp
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-10-26 08:44:00 +0100
committerV3n3RiX <venerix@koprulu.sector>2023-10-26 08:44:00 +0100
commit1e8bc3b2037289b8577740cea9321c37c52a49a2 (patch)
treeeb73b737abc04c27ce7e878f621e1a49deb09857 /sys-libs/libomp
parentc3a905eafd0ea87d50767fa3d24a6b565a41faa9 (diff)
gentoo auto-resync : 26:10:2023 - 08:43:59
Diffstat (limited to 'sys-libs/libomp')
-rw-r--r--sys-libs/libomp/Manifest2
-rw-r--r--sys-libs/libomp/libomp-18.0.0_pre20231025.ebuild150
2 files changed, 152 insertions, 0 deletions
diff --git a/sys-libs/libomp/Manifest b/sys-libs/libomp/Manifest
index 7ccdf69550c0..b066bc58198b 100644
--- a/sys-libs/libomp/Manifest
+++ b/sys-libs/libomp/Manifest
@@ -10,6 +10,7 @@ DIST llvm-project-16.0.6.src.tar.xz.sig 566 BLAKE2B 2060cebd5ed57cb8a86a44238c43
DIST llvm-project-17.0.3.src.tar.xz 127843636 BLAKE2B 5331d9b545faab282a4caec9ee688d0f1e0615a56a26aa24d8f6fbbae10258e132d94634dab2f7bd69ada06bb28dc899730b9cd774a1086d7c03d5706de6d997 SHA512 44f37dea494a66a83c252e28d7d0517c3b2eed5b196565432dc663c7914bd66d665c8d13479e2776a14cac1905faf6972f986176722c053b58528570a6e68316
DIST llvm-project-17.0.3.src.tar.xz.sig 438 BLAKE2B 045e7ca82c8d9b3f182e4fa331ec841b24777ac1888f10de435a389ae3a88172e0559a3fca0c2d37cc874464411ae50d7bc0d0829455149a8de8b953ef6c98c7 SHA512 95f9e6729074cfd71b0ffb21e423cd0fd87763268c24e0513f7afd6a85d08061658c44c03ea3ea3b6e3cc7051676d44c41a791e6905c8abb456d48a3762fc152
DIST llvm-project-5d35273a32d239b7407338e13ed71b59174d6536.tar.gz 198787569 BLAKE2B 7f4f1eb490028e18826a6ebade649a682e433252ceab1f3dcd9e50c34f24e7ef108c3325ec209a4d4fa1ded8e09ebda4980cb9d8ddce8a0d517923d6c38b8f4a SHA512 4d263561fb12cc07a5e8f7ed2f8f22a3645aa959cf963a6a735a9bb93cfc2a51bf7e4d36b54e8425725029cfcfd868dfcc53af95d26d84be72be124d8c564271
+DIST llvm-project-a7700985577694d6cc2498833f27b4fb5eeaf252.tar.gz 199221825 BLAKE2B 047ab7c0e80e1dbbe61ebd9aaae17166665a33b5cb50beec6da2cc19bec9a16777b82c157e74f88b0678d843b200f292d696a964211a8e532f128491dc39a6e4 SHA512 b747210d53402ae01238fa82195fa5c1c8d1c832d976bcc996ef657ac54dacb2fb19521c6f080151e6b1af8a49ddfe58979afaa00b3f1f72dc664ac79b99a8bb
DIST llvm-project-e6e90840708099425b7b69dd053634ff25d4907f.tar.gz 199022115 BLAKE2B 442aff8f561f7c5834a36b7eb217fd2b984e58af9cbcf3e6495305f386a7651e73345bbe65133af4bffaf8cb209cfb9a94fb28756ffaaaae8f7d28ec253ccb78 SHA512 fa9c180f36f4c782208ae7baff1683ee466c70f7d021b21b9cb8a8fd0f2005c0b47889d8bb37f5fb984f6b2ec26c74df60490c7b51ac3d080830e6844e33e300
EBUILD libomp-14.0.6-r1.ebuild 3917 BLAKE2B d92540af690dd622122ad1a4ed2548afa141f1254fbe9a9b3d34286b36f0fa70ccaf915f218c1bea8c68377ea20724db9443d365e2e5f290707f444d3ff47ca5 SHA512 433ae63716103af5aa493c7dbae43f10003cac95abaae579dcb61cba6390da4b9b3fc921e410ba899719bd170fa153a7b3d66c8776c37fd074066173c1fea160
EBUILD libomp-15.0.7-r2.ebuild 3474 BLAKE2B c75fddce61b7e8fe837b4c5bc1b7dacfbe4bc1572537dd7c44c23f894d05b104e8946d896b3b19d78de32a87d866d5911a0f3a8f81796469bba2753d051b2105 SHA512 7dc7c5fd7cd370acadfdf6e15ed09cde0798312ed3c72e770596aecb5817a4ec1477cc1092e3c159d1988bba4200808259705206f80d8fd0019fe07c34f4455d
@@ -20,4 +21,5 @@ EBUILD libomp-17.0.3.ebuild 3994 BLAKE2B 9dcb5843a7ef3f28c4b174b264b53b7b4e0638d
EBUILD libomp-18.0.0.9999.ebuild 3910 BLAKE2B 9104678d4e75d56a9dcd6f7b1f032130534e49d78d5a99194fe93a064ae1bb734b865fec73da45598c9d91b479b16cc327c577bfb98c17cd061d83b228b3baac SHA512 30343370384efe4791fb91df02f465a64c67a98ad480f5a8e8d3a4d16d7b8a4c5fc564936b8c6b4facbe1443bd34542c76d344a7f7b745ca9b85622917d1c486
EBUILD libomp-18.0.0_pre20231013.ebuild 3910 BLAKE2B 9104678d4e75d56a9dcd6f7b1f032130534e49d78d5a99194fe93a064ae1bb734b865fec73da45598c9d91b479b16cc327c577bfb98c17cd061d83b228b3baac SHA512 30343370384efe4791fb91df02f465a64c67a98ad480f5a8e8d3a4d16d7b8a4c5fc564936b8c6b4facbe1443bd34542c76d344a7f7b745ca9b85622917d1c486
EBUILD libomp-18.0.0_pre20231019.ebuild 3910 BLAKE2B 9104678d4e75d56a9dcd6f7b1f032130534e49d78d5a99194fe93a064ae1bb734b865fec73da45598c9d91b479b16cc327c577bfb98c17cd061d83b228b3baac SHA512 30343370384efe4791fb91df02f465a64c67a98ad480f5a8e8d3a4d16d7b8a4c5fc564936b8c6b4facbe1443bd34542c76d344a7f7b745ca9b85622917d1c486
+EBUILD libomp-18.0.0_pre20231025.ebuild 3910 BLAKE2B 9104678d4e75d56a9dcd6f7b1f032130534e49d78d5a99194fe93a064ae1bb734b865fec73da45598c9d91b479b16cc327c577bfb98c17cd061d83b228b3baac SHA512 30343370384efe4791fb91df02f465a64c67a98ad480f5a8e8d3a4d16d7b8a4c5fc564936b8c6b4facbe1443bd34542c76d344a7f7b745ca9b85622917d1c486
MISC metadata.xml 963 BLAKE2B fdea4545db21492049061b85eaa7038965183e10aceae7c41daadc1ce10e7e1bcb2e86344659787ee244360b50b51c99e1a348d3acd2185dac80097541a00dd7 SHA512 c279f8e9c2463dc3f6e02856e520105d6f3321b633439bfe7409bfd6e7e43f1450053dc4f6663492caf7077caf3f4ab0f5cf0161631639e3aefa9ff985dc476f
diff --git a/sys-libs/libomp/libomp-18.0.0_pre20231025.ebuild b/sys-libs/libomp/libomp-18.0.0_pre20231025.ebuild
new file mode 100644
index 000000000000..960f9ce8087f
--- /dev/null
+++ b/sys-libs/libomp/libomp-18.0.0_pre20231025.ebuild
@@ -0,0 +1,150 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..12} )
+inherit flag-o-matic cmake-multilib linux-info llvm llvm.org
+inherit python-single-r1 toolchain-funcs
+
+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 offload ompt test
+ llvm_targets_AMDGPU llvm_targets_NVPTX
+"
+REQUIRED_USE="
+ gdb-plugin? ( ${PYTHON_REQUIRED_USE} )
+"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ gdb-plugin? ( ${PYTHON_DEPS} )
+ hwloc? ( >=sys-apps/hwloc-2.5:0=[${MULTILIB_USEDEP}] )
+ offload? (
+ dev-libs/libffi:=[${MULTILIB_USEDEP}]
+ ~sys-devel/llvm-${PV}[${MULTILIB_USEDEP}]
+ llvm_targets_AMDGPU? ( dev-libs/rocr-runtime:= )
+ )
+"
+# tests:
+# - dev-python/lit provides the test runner
+# - sys-devel/llvm provide test utils (e.g. FileCheck)
+# - sys-devel/clang provides the compiler to run tests
+DEPEND="
+ ${RDEPEND}
+"
+BDEPEND="
+ dev-lang/perl
+ offload? (
+ llvm_targets_AMDGPU? ( sys-devel/clang )
+ llvm_targets_NVPTX? ( sys-devel/clang )
+ virtual/pkgconfig
+ )
+ test? (
+ ${PYTHON_DEPS}
+ $(python_gen_cond_dep '
+ dev-python/lit[${PYTHON_USEDEP}]
+ ')
+ sys-devel/clang
+ )
+"
+
+LLVM_COMPONENTS=( openmp cmake llvm/include )
+llvm.org_set_globals
+
+kernel_pds_check() {
+ if use kernel_linux && kernel_is -lt 4 15 && kernel_is -ge 4 13; then
+ local CONFIG_CHECK="~!SCHED_PDS"
+ local ERROR_SCHED_PDS="\
+PDS scheduler versions >= 0.98c < 0.98i (e.g. used in kernels >= 4.13-pf11
+< 4.14-pf9) do not implement sched_yield() call which may result in horrible
+performance problems with libomp. If you are using one of the specified
+kernel versions, you may want to disable the PDS scheduler."
+
+ check_extra_config
+ fi
+}
+
+pkg_pretend() {
+ kernel_pds_check
+}
+
+pkg_setup() {
+ use offload && LLVM_MAX_SLOT=${LLVM_MAJOR} llvm_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 build_omptarget=OFF
+ # upstream disallows building libomptarget when sizeof(void*) != 8
+ if use offload &&
+ "$(tc-getCC)" ${CFLAGS} ${CPPFLAGS} -c -x c - -o /dev/null \
+ <<-EOF &>/dev/null
+ int test[sizeof(void *) == 8 ? 1 : -1];
+ EOF
+ then
+ build_omptarget=ON
+ fi
+
+ 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)
+
+ -DOPENMP_ENABLE_LIBOMPTARGET=${build_omptarget}
+
+ # do not install libgomp.so & libiomp5.so aliases
+ -DLIBOMP_INSTALL_ALIASES=OFF
+ # disable unnecessary hack copying stuff back to srcdir
+ -DLIBOMP_COPY_EXPORTS=OFF
+ # prevent trying to access the GPU
+ -DLIBOMPTARGET_AMDGPU_ARCH=LIBOMPTARGET_AMDGPU_ARCH-NOTFOUND
+ )
+
+ if [[ ${build_omptarget} == ON ]]; then
+ if has "${CHOST%%-*}" aarch64 powerpc64le x86_64; then
+ mycmakeargs+=(
+ -DLIBOMPTARGET_BUILD_AMDGPU_PLUGIN=$(usex llvm_targets_AMDGPU)
+ -DLIBOMPTARGET_BUILD_CUDA_PLUGIN=$(usex llvm_targets_NVPTX)
+ )
+ else
+ mycmakeargs+=(
+ -DLIBOMPTARGET_BUILD_AMDGPU_PLUGIN=OFF
+ -DLIBOMPTARGET_BUILD_CUDA_PLUGIN=OFF
+ )
+ fi
+ fi
+
+ 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++")"
+ )
+ addpredict /dev/nvidiactl
+ cmake_src_configure
+}
+
+multilib_src_test() {
+ # respect TMPDIR!
+ local -x LIT_PRESERVES_TMP=1
+
+ cmake_build check-libomp
+}