summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2018-11-06 12:04:37 +0100
committerMichał Górny <mgorny@gentoo.org>2018-11-06 12:06:17 +0100
commit62dd9e5149080ee0b85f63d0e4349321ee360b90 (patch)
tree0f293dbe2a2657d92f0feb445ad66ff90578a8ce /sys-libs
parentsys-libs/libcxx: Bump to 7.0.1_rc2 (diff)
downloadgentoo-62dd9e5149080ee0b85f63d0e4349321ee360b90.tar.gz
gentoo-62dd9e5149080ee0b85f63d0e4349321ee360b90.tar.bz2
gentoo-62dd9e5149080ee0b85f63d0e4349321ee360b90.zip
sys-libs/libomp: Bump to 7.0.1_rc2
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'sys-libs')
-rw-r--r--sys-libs/libomp/Manifest1
-rw-r--r--sys-libs/libomp/libomp-7.0.1_rc2.ebuild115
2 files changed, 116 insertions, 0 deletions
diff --git a/sys-libs/libomp/Manifest b/sys-libs/libomp/Manifest
index 04ad2a1aa8e2..8d872e0540d4 100644
--- a/sys-libs/libomp/Manifest
+++ b/sys-libs/libomp/Manifest
@@ -2,3 +2,4 @@ DIST openmp-4.0.1.src.tar.xz 2275240 BLAKE2B e63cf670c4cd2678afc4d7b96be85c3d157
DIST openmp-5.0.2.src.tar.xz 2081560 BLAKE2B fbe41c6aaf4c8e961253609a598bec531ab4685cd8c307ab2528b9d7553eaa38122ee02a2c4d481454f9233c062b3a24bb174a182702a183907a3d15a10a9655 SHA512 511895ca6049c17de81ad86c39dcb940a7c1a793005e16d33e58d72ad47f62b8cb61003c234a7544a88e79f25d2c86e9df834f90d37ccbd4b47f71c369e90437
DIST openmp-6.0.1.src.tar.xz 2048320 BLAKE2B 08b3a7051c985903f78331f55a1c6e928399b87c862c43c991e9bf78b66b6e412fc96f202b82c051176dbbe02422f8ceb7414f44ea8f3522f418e515c0f70c62 SHA512 abb956583e5d11d0c6f6d97183c081d658616a74933be884a591eaa3d8c4bb04f08f02016d2c86d7384c7ff1aa44fb949b0d967fc0ff50e3132aaba412e9add8
DIST openmp-7.0.0.src.tar.xz 910680 BLAKE2B c6bc47d67dbcff12d07e536cfc8135609ba7d72360c50c02b327c24ff74ef41dc1e79c2ad8f95e202b6f318d385cc19e631b53d649e301afb6352823198f09ce SHA512 bda383d62c822db41504d7774974809cd2af042b03a0b4ca450cc1478c5977682f5c646734801c1b7a16233141d62359c17e87e1435c48a222e159a8763f8857
+DIST openmp-7.0.1rc2.src.tar.xz 909276 BLAKE2B 165ce625b8825233cffec73b1965a4759f64d921582ee1ae02d02de0602d65ec570bb8d7d70b1193f4fc43da2770c57eb0b48ecb3d6f0267ab4f29187bd9f7e8 SHA512 6a85016108b74054a4174d2d24666e32e21894b1f4feeafda4574c3f8b14404d775a66189ada015a5ac9b22bfc4673ba0849d1a80c6b1b4d8d804f2d0f04c840
diff --git a/sys-libs/libomp/libomp-7.0.1_rc2.ebuild b/sys-libs/libomp/libomp-7.0.1_rc2.ebuild
new file mode 100644
index 000000000000..2c35eb63633e
--- /dev/null
+++ b/sys-libs/libomp/libomp-7.0.1_rc2.ebuild
@@ -0,0 +1,115 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+: ${CMAKE_MAKEFILE_GENERATOR:=ninja}
+# (needed due to CMAKE_BUILD_TYPE != Gentoo)
+CMAKE_MIN_VERSION=3.7.0-r1
+PYTHON_COMPAT=( python2_7 )
+
+inherit cmake-multilib linux-info multiprocessing python-any-r1
+
+DESCRIPTION="OpenMP runtime library for LLVM/clang compiler"
+HOMEPAGE="https://openmp.llvm.org"
+SRC_URI="https://prereleases.llvm.org/${PV/_//}/openmp-${PV/_/}.src.tar.xz"
+
+# Additional licenses:
+# - MIT-licensed Intel code,
+# - LLVM Software Grant from Intel.
+
+LICENSE="|| ( UoI-NCSA MIT ) MIT LLVM-Grant"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86 ~amd64-fbsd ~amd64-linux ~x64-macos"
+IUSE="cuda hwloc kernel_linux offload ompt test"
+# CUDA works only with the x86_64 ABI
+REQUIRED_USE="offload? ( cuda? ( abi_x86_64 ) )"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ hwloc? ( sys-apps/hwloc:0=[${MULTILIB_USEDEP}] )
+ offload? (
+ virtual/libelf:=[${MULTILIB_USEDEP}]
+ virtual/libffi:=[${MULTILIB_USEDEP}]
+ cuda? ( dev-util/nvidia-cuda-sdk:= )
+ )"
+# 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}
+ dev-lang/perl
+ offload? ( virtual/pkgconfig[${MULTILIB_USEDEP}] )
+ test? (
+ $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]')
+ >=sys-devel/clang-6
+ )"
+
+S=${WORKDIR}/openmp-${PV/_/}.src
+
+# least intrusive of all
+CMAKE_BUILD_TYPE=RelWithDebInfo
+
+python_check_deps() {
+ has_version "dev-python/lit[${PYTHON_USEDEP}]"
+}
+
+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 test && python-any-r1_pkg_setup
+}
+
+multilib_src_configure() {
+ local libdir="$(get_libdir)"
+ local mycmakeargs=(
+ -DOPENMP_LIBDIR_SUFFIX="${libdir#lib}"
+
+ -DLIBOMP_USE_HWLOC=$(usex hwloc)
+ -DLIBOMP_OMPT_SUPPORT=$(usex ompt)
+
+ -DOPENMP_ENABLE_LIBOMPTARGET=$(usex offload)
+
+ # 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 offload && mycmakeargs+=(
+ # this is non-fatal and libomp checks for CUDA conditionally
+ # to ABI, so we can just ignore passing the wrong value
+ # on non-amd64 ABIs
+ -DCMAKE_DISABLE_FIND_PACKAGE_CUDA=$(usex !cuda)
+ )
+ use test && mycmakeargs+=(
+ # this project does not use standard LLVM cmake macros
+ -DOPENMP_LLVM_LIT_EXECUTABLE="${EPREFIX}/usr/bin/lit"
+ -DOPENMP_LIT_ARGS="-vv;-j;${LIT_JOBS:-$(makeopts_jobs "${MAKEOPTS}" "$(get_nproc)")}"
+
+ -DOPENMP_TEST_C_COMPILER="$(type -P "${CHOST}-clang")"
+ -DOPENMP_TEST_CXX_COMPILER="$(type -P "${CHOST}-clang++")"
+ )
+ cmake-utils_src_configure
+}
+
+multilib_src_test() {
+ # respect TMPDIR!
+ local -x LIT_PRESERVES_TMP=1
+
+ cmake-utils_src_make check-libomp
+}