Gentoo Archives: gentoo-commits

From: "Michał Górny" <mgorny@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-libs/libomp/
Date: Mon, 24 Jul 2017 19:04:04
Message-Id: 1500923030.51bf6e063e82add109f17897248623bbe45d0d53.mgorny@gentoo
1 commit: 51bf6e063e82add109f17897248623bbe45d0d53
2 Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
3 AuthorDate: Sun Jul 23 16:51:28 2017 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Mon Jul 24 19:03:50 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=51bf6e06
7
8 sys-libs/libomp: Branch for 5.0.0 release
9
10 sys-libs/libomp/libomp-5.0.9999.ebuild | 74 ++++++++++++++++++++++++++++++++++
11 1 file changed, 74 insertions(+)
12
13 diff --git a/sys-libs/libomp/libomp-5.0.9999.ebuild b/sys-libs/libomp/libomp-5.0.9999.ebuild
14 new file mode 100644
15 index 00000000000..086e4db0217
16 --- /dev/null
17 +++ b/sys-libs/libomp/libomp-5.0.9999.ebuild
18 @@ -0,0 +1,74 @@
19 +# Copyright 1999-2016 Gentoo Foundation
20 +# Distributed under the terms of the GNU General Public License v2
21 +
22 +EAPI=6
23 +
24 +: ${CMAKE_MAKEFILE_GENERATOR:=ninja}
25 +# (needed due to CMAKE_BUILD_TYPE != Gentoo)
26 +CMAKE_MIN_VERSION=3.7.0-r1
27 +PYTHON_COMPAT=( python2_7 )
28 +
29 +inherit cmake-multilib git-r3 python-any-r1
30 +
31 +DESCRIPTION="OpenMP runtime library for LLVM/clang compiler"
32 +HOMEPAGE="https://openmp.llvm.org"
33 +SRC_URI=""
34 +EGIT_REPO_URI="https://git.llvm.org/git/openmp.git
35 + https://github.com/llvm-mirror/openmp.git"
36 +EGIT_BRANCH="release_50"
37 +
38 +# Additional licenses:
39 +# - MIT-licensed Intel code,
40 +# - LLVM Software Grant from Intel.
41 +
42 +LICENSE="|| ( UoI-NCSA MIT ) MIT LLVM-Grant"
43 +SLOT="0"
44 +KEYWORDS=""
45 +IUSE="hwloc ompt test"
46 +
47 +RDEPEND="hwloc? ( sys-apps/hwloc:0=[${MULTILIB_USEDEP}] )"
48 +# tests:
49 +# - dev-python/lit provides the test runner
50 +# - sys-devel/llvm provide test utils (e.g. FileCheck)
51 +# - sys-devel/clang provides the compiler to run tests
52 +DEPEND="${RDEPEND}
53 + dev-lang/perl
54 + test? (
55 + $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]')
56 + sys-devel/llvm
57 + >=sys-devel/clang-3.9.0
58 + )"
59 +
60 +# least intrusive of all
61 +CMAKE_BUILD_TYPE=RelWithDebInfo
62 +
63 +python_check_deps() {
64 + has_version "dev-python/lit[${PYTHON_USEDEP}]"
65 +}
66 +
67 +pkg_setup() {
68 + use test && python-any-r1_pkg_setup
69 +}
70 +
71 +multilib_src_configure() {
72 + local libdir="$(get_libdir)"
73 + local mycmakeargs=(
74 + -DLIBOMP_LIBDIR_SUFFIX="${libdir#lib}"
75 + -DLIBOMPTARGET_LIBDIR_SUFFIX="${libdir#lib}"
76 + -DLIBOMP_USE_HWLOC=$(usex hwloc)
77 + -DLIBOMP_OMPT_SUPPORT=$(usex ompt)
78 + # do not install libgomp.so & libiomp5.so aliases
79 + -DLIBOMP_INSTALL_ALIASES=OFF
80 + # disable unnecessary hack copying stuff back to srcdir
81 + -DLIBOMP_COPY_EXPORTS=OFF
82 + -DLIBOMP_TEST_COMPILER="$(type -P "${CHOST}-clang")"
83 + )
84 + cmake-utils_src_configure
85 +}
86 +
87 +multilib_src_test() {
88 + # respect TMPDIR!
89 + local -x LIT_PRESERVES_TMP=1
90 +
91 + cmake-utils_src_make check-libomp
92 +}