1 |
commit: 62e9e11fc198ea109dc6cc61336eaae76b3c2e47 |
2 |
Author: Michał Górny <mgorny <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Feb 28 13:08:02 2023 +0000 |
4 |
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Feb 28 13:08:02 2023 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=62e9e11f |
7 |
|
8 |
sys-libs/libomp: Remove old |
9 |
|
10 |
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> |
11 |
|
12 |
sys-libs/libomp/Manifest | 4 - |
13 |
sys-libs/libomp/libomp-16.0.0_rc2.ebuild | 149 ----------------------- |
14 |
sys-libs/libomp/libomp-17.0.0_pre20230211.ebuild | 149 ----------------------- |
15 |
sys-libs/libomp/libomp-17.0.0_pre20230218.ebuild | 149 ----------------------- |
16 |
4 files changed, 451 deletions(-) |
17 |
|
18 |
diff --git a/sys-libs/libomp/Manifest b/sys-libs/libomp/Manifest |
19 |
index a4c929d7413f..62d0092cea6e 100644 |
20 |
--- a/sys-libs/libomp/Manifest |
21 |
+++ b/sys-libs/libomp/Manifest |
22 |
@@ -4,10 +4,6 @@ DIST llvm-project-14.0.6.src.tar.xz 105618228 BLAKE2B ee67c5407df8cef493b9c0004f |
23 |
DIST llvm-project-14.0.6.src.tar.xz.sig 566 BLAKE2B cb658ad43d8ab6c43a5773aedadf0569c97b5ee4b1bd58eceb10e1879a30880c741c3d66bedd462c892309b688fb7b2673115a62d1f74d71ee375a578de9547f SHA512 b4a7b368532a7a4a24376cfa7db8f6d3478f6d4446474342fc00b474ecf466330cd0f16783209263c4c72d5fc7ddedfb11b95578842e700cfb7ee0bb34cc95d6 |
24 |
DIST llvm-project-15.0.7.src.tar.xz 110936452 BLAKE2B f3d277e2029157329e5be78b78af36b0826a1dfd9a337992499bf701e33149665bfc47d5e14978e38f342559629a559f8b2ce328705ba34fdf6830f5ae9721a5 SHA512 4836d3603f32e8e54434cbfa8ef33d9d473ac5dc20ebf9c67132653c73f4524931abd1084655eaee5f20bcfcb91bcc4bbc5c4a0b603ad0c9029c556e14dc4c52 |
25 |
DIST llvm-project-15.0.7.src.tar.xz.sig 566 BLAKE2B 47dc8c82d86237b80c6d85f83a6c9a6e9e174cf8e7f367b071e0cd9481d7cd408e991337c5624e07f3f370f26387c814f212808575ed1c1b58404d3e3836b7df SHA512 fc6891b440dd1175eb8df3790590af8d36bc92301660f84744ae15123475aeb900a151e6a8e7998ded27ec4d86871903ad0b89cd61164943054c2e3bc8d8beb2 |
26 |
-DIST llvm-project-16.0.0rc2.src.tar.xz 117917640 BLAKE2B 92c6b1daaa500339403dcf530efb23e1d869c7b9cd8677a6680e57d5d087fb54182f009d58bdda714b62a5866d7fe3b10deedc1e251fffdaae513706d95325af SHA512 c68bb7f2a8004666ecc5c55e89e2ca1252b384e6240a2b7c5588b74794ffc6ce93bb4b0db394abba6436cce04a6de301e80821aeda04d7aab49efb96b6f8cf40 |
27 |
-DIST llvm-project-16.0.0rc2.src.tar.xz.sig 566 BLAKE2B 35b2a8edf3392e1c0e9bf7f1a5e6e18fdda3d98a2164947cebf0c19d7d7c7a459901060345745dff794cf99bea243fec5cb625ca68d7c73d31ac01f18cbaa58c SHA512 4f6d43f00c3bce36c3a005441473fe37fe2ca97df4b8dd306045bd0d8bd14406ae7068a3dea54d4535eaa37b7ccca54b3f5b6f5aef70a7dfc23ed336d4ad408c |
28 |
DIST llvm-project-16.0.0rc3.src.tar.xz 117914548 BLAKE2B 18ffa35eb73c7cc4626d7b6b7b30aade7171ee2e17fb8d72e79a67185e809f611fefa4cfef17e5cd16822a5a70de2222534dc9f146fc53987eb49ff6a9d98c18 SHA512 d14e5e5ec984a0dc0292a2d27440398b3e32f120c1579517054dcb1a05dbc4ac5f1c6d078a3d6ef8597a71af6f22863868680a972a571839dcd573418b4a4697 |
29 |
DIST llvm-project-16.0.0rc3.src.tar.xz.sig 566 BLAKE2B 43683d2d7b266a847516f71412bf6236a355462430330fc0da1d624fb8dfbc98bfc982d367baee74d5b4964a9e82e7a4a6ea84bdcff3996d246932f516cced1a SHA512 61adc4dc3eb5a4c11a7f96f9267ff37895e5845a08d48a609a03a2696c1b6bca5af5861a6f28de936c48e6d621bf282170589187f2cb593a912b9078300cf47c |
30 |
-DIST llvm-project-22fb66eb94b643c858c2beecbcfac438a7fa29ed.tar.gz 179795537 BLAKE2B aef57ef739c52a8f8b2b327a8f6d8cce4734d9704018fb43a21468e56748e5d5b3d2d47fb4e95fd72b2af9f2e4be88839553e26fd7da08df60c5cc0f51c001d4 SHA512 9ed093ef7dac4891660aafbc5cad66bddefa796bff4dd70c792cc636268742142d82b84520ac2f5a5963521d7b9e4325440763ce0c88937f89722f07d3acd4b8 |
31 |
-DIST llvm-project-5e262d58c42668c78d932fab6bf75cf8c3b9d07e.tar.gz 179975303 BLAKE2B 184e7ff6e9a7de77d4a8c36c6910e4e3c7c5e9ff73ed6111ec4704dd457205278abb258ff37170e41a6b21c9ae3f243a80b34e4b17f8977fb9a42876db6465b7 SHA512 ec7e16a4d8f8292d1184ae08c1c5eda0dba1876e7d9c228eb0added5cde45f3094fde7eb1da662d436f85315850310cc0612210ff3ddf82967d5c2de0047a724 |
32 |
DIST llvm-project-b0676fb0fb0a44a4a1c4ec1f0270fef1f1842817.tar.gz 180277698 BLAKE2B d2c1e6a1942e51f5844c18605f38b005e9bb4123850a173e4c4b3d7b6a14f4986c7b276b40df4d0594ae04e869e92ba1a4269c5055c0229cfd28aa1bd709da4f SHA512 d1281b942dcc254641865f11b0c4fbd1d562d016681b6b7268549bed1cdb7d4536f743a8ed089095eaab9f4bfb9de624153f448bf13d0e22f8ea24a4d264df7b |
33 |
|
34 |
diff --git a/sys-libs/libomp/libomp-16.0.0_rc2.ebuild b/sys-libs/libomp/libomp-16.0.0_rc2.ebuild |
35 |
deleted file mode 100644 |
36 |
index ebf0c81b440e..000000000000 |
37 |
--- a/sys-libs/libomp/libomp-16.0.0_rc2.ebuild |
38 |
+++ /dev/null |
39 |
@@ -1,149 +0,0 @@ |
40 |
-# Copyright 1999-2023 Gentoo Authors |
41 |
-# Distributed under the terms of the GNU General Public License v2 |
42 |
- |
43 |
-EAPI=8 |
44 |
- |
45 |
-PYTHON_COMPAT=( python3_{9..11} ) |
46 |
-inherit flag-o-matic cmake-multilib linux-info llvm llvm.org |
47 |
-inherit python-single-r1 toolchain-funcs |
48 |
- |
49 |
-DESCRIPTION="OpenMP runtime library for LLVM/clang compiler" |
50 |
-HOMEPAGE="https://openmp.llvm.org" |
51 |
- |
52 |
-LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" |
53 |
-SLOT="0/${LLVM_SOABI}" |
54 |
-KEYWORDS="~loong" |
55 |
-IUSE=" |
56 |
- debug gdb-plugin hwloc offload ompt test |
57 |
- llvm_targets_AMDGPU llvm_targets_NVPTX |
58 |
-" |
59 |
-REQUIRED_USE=" |
60 |
- gdb-plugin? ( ${PYTHON_REQUIRED_USE} ) |
61 |
-" |
62 |
-RESTRICT="!test? ( test )" |
63 |
- |
64 |
-RDEPEND=" |
65 |
- gdb-plugin? ( ${PYTHON_DEPS} ) |
66 |
- hwloc? ( >=sys-apps/hwloc-2.5:0=[${MULTILIB_USEDEP}] ) |
67 |
- offload? ( |
68 |
- dev-libs/libffi:=[${MULTILIB_USEDEP}] |
69 |
- ~sys-devel/llvm-${PV}[${MULTILIB_USEDEP}] |
70 |
- llvm_targets_AMDGPU? ( dev-libs/rocr-runtime:0/5.3 ) |
71 |
- ) |
72 |
-" |
73 |
-# tests: |
74 |
-# - dev-python/lit provides the test runner |
75 |
-# - sys-devel/llvm provide test utils (e.g. FileCheck) |
76 |
-# - sys-devel/clang provides the compiler to run tests |
77 |
-DEPEND=" |
78 |
- ${RDEPEND} |
79 |
-" |
80 |
-BDEPEND=" |
81 |
- dev-lang/perl |
82 |
- offload? ( |
83 |
- llvm_targets_AMDGPU? ( sys-devel/clang ) |
84 |
- llvm_targets_NVPTX? ( sys-devel/clang ) |
85 |
- virtual/pkgconfig |
86 |
- ) |
87 |
- test? ( |
88 |
- ${PYTHON_DEPS} |
89 |
- $(python_gen_cond_dep ' |
90 |
- dev-python/lit[${PYTHON_USEDEP}] |
91 |
- ') |
92 |
- sys-devel/clang |
93 |
- ) |
94 |
-" |
95 |
- |
96 |
-LLVM_COMPONENTS=( openmp cmake llvm/include ) |
97 |
-llvm.org_set_globals |
98 |
- |
99 |
-kernel_pds_check() { |
100 |
- if use kernel_linux && kernel_is -lt 4 15 && kernel_is -ge 4 13; then |
101 |
- local CONFIG_CHECK="~!SCHED_PDS" |
102 |
- local ERROR_SCHED_PDS="\ |
103 |
-PDS scheduler versions >= 0.98c < 0.98i (e.g. used in kernels >= 4.13-pf11 |
104 |
-< 4.14-pf9) do not implement sched_yield() call which may result in horrible |
105 |
-performance problems with libomp. If you are using one of the specified |
106 |
-kernel versions, you may want to disable the PDS scheduler." |
107 |
- |
108 |
- check_extra_config |
109 |
- fi |
110 |
-} |
111 |
- |
112 |
-pkg_pretend() { |
113 |
- kernel_pds_check |
114 |
-} |
115 |
- |
116 |
-pkg_setup() { |
117 |
- use offload && LLVM_MAX_SLOT=${LLVM_MAJOR} llvm_pkg_setup |
118 |
- if use gdb-plugin || use test; then |
119 |
- python-single-r1_pkg_setup |
120 |
- fi |
121 |
-} |
122 |
- |
123 |
-multilib_src_configure() { |
124 |
- # LTO causes issues in other packages building, #870127 |
125 |
- filter-lto |
126 |
- |
127 |
- # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844 |
128 |
- use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG" |
129 |
- |
130 |
- local build_omptarget=OFF |
131 |
- # upstream disallows building libomptarget when sizeof(void*) != 8 |
132 |
- if use offload && |
133 |
- "$(tc-getCC)" ${CFLAGS} ${CPPFLAGS} -c -x c - -o /dev/null \ |
134 |
- <<-EOF &>/dev/null |
135 |
- int test[sizeof(void *) == 8 ? 1 : -1]; |
136 |
- EOF |
137 |
- then |
138 |
- build_omptarget=ON |
139 |
- fi |
140 |
- |
141 |
- local libdir="$(get_libdir)" |
142 |
- local mycmakeargs=( |
143 |
- -DOPENMP_LIBDIR_SUFFIX="${libdir#lib}" |
144 |
- |
145 |
- -DLIBOMP_USE_HWLOC=$(usex hwloc) |
146 |
- -DLIBOMP_OMPD_GDB_SUPPORT=$(multilib_native_usex gdb-plugin) |
147 |
- -DLIBOMP_OMPT_SUPPORT=$(usex ompt) |
148 |
- |
149 |
- -DOPENMP_ENABLE_LIBOMPTARGET=${build_omptarget} |
150 |
- |
151 |
- # do not install libgomp.so & libiomp5.so aliases |
152 |
- -DLIBOMP_INSTALL_ALIASES=OFF |
153 |
- # disable unnecessary hack copying stuff back to srcdir |
154 |
- -DLIBOMP_COPY_EXPORTS=OFF |
155 |
- ) |
156 |
- |
157 |
- if [[ ${build_omptarget} == ON ]]; then |
158 |
- if has "${CHOST%%-*}" aarch64 powerpc64le x86_64; then |
159 |
- mycmakeargs+=( |
160 |
- -DLIBOMPTARGET_BUILD_AMDGPU_PLUGIN=$(usex llvm_targets_AMDGPU) |
161 |
- -DLIBOMPTARGET_BUILD_CUDA_PLUGIN=$(usex llvm_targets_NVPTX) |
162 |
- ) |
163 |
- else |
164 |
- mycmakeargs+=( |
165 |
- -DLIBOMPTARGET_BUILD_AMDGPU_PLUGIN=OFF |
166 |
- -DLIBOMPTARGET_BUILD_CUDA_PLUGIN=OFF |
167 |
- ) |
168 |
- fi |
169 |
- fi |
170 |
- |
171 |
- use test && mycmakeargs+=( |
172 |
- # this project does not use standard LLVM cmake macros |
173 |
- -DOPENMP_LLVM_LIT_EXECUTABLE="${EPREFIX}/usr/bin/lit" |
174 |
- -DOPENMP_LIT_ARGS="$(get_lit_flags)" |
175 |
- |
176 |
- -DOPENMP_TEST_C_COMPILER="$(type -P "${CHOST}-clang")" |
177 |
- -DOPENMP_TEST_CXX_COMPILER="$(type -P "${CHOST}-clang++")" |
178 |
- ) |
179 |
- addpredict /dev/nvidiactl |
180 |
- cmake_src_configure |
181 |
-} |
182 |
- |
183 |
-multilib_src_test() { |
184 |
- # respect TMPDIR! |
185 |
- local -x LIT_PRESERVES_TMP=1 |
186 |
- |
187 |
- cmake_build check-libomp |
188 |
-} |
189 |
|
190 |
diff --git a/sys-libs/libomp/libomp-17.0.0_pre20230211.ebuild b/sys-libs/libomp/libomp-17.0.0_pre20230211.ebuild |
191 |
deleted file mode 100644 |
192 |
index 6bb50cb9edf9..000000000000 |
193 |
--- a/sys-libs/libomp/libomp-17.0.0_pre20230211.ebuild |
194 |
+++ /dev/null |
195 |
@@ -1,149 +0,0 @@ |
196 |
-# Copyright 1999-2023 Gentoo Authors |
197 |
-# Distributed under the terms of the GNU General Public License v2 |
198 |
- |
199 |
-EAPI=8 |
200 |
- |
201 |
-PYTHON_COMPAT=( python3_{9..11} ) |
202 |
-inherit flag-o-matic cmake-multilib linux-info llvm llvm.org |
203 |
-inherit python-single-r1 toolchain-funcs |
204 |
- |
205 |
-DESCRIPTION="OpenMP runtime library for LLVM/clang compiler" |
206 |
-HOMEPAGE="https://openmp.llvm.org" |
207 |
- |
208 |
-LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" |
209 |
-SLOT="0/${LLVM_SOABI}" |
210 |
-KEYWORDS="" |
211 |
-IUSE=" |
212 |
- debug gdb-plugin hwloc offload ompt test |
213 |
- llvm_targets_AMDGPU llvm_targets_NVPTX |
214 |
-" |
215 |
-REQUIRED_USE=" |
216 |
- gdb-plugin? ( ${PYTHON_REQUIRED_USE} ) |
217 |
-" |
218 |
-RESTRICT="!test? ( test )" |
219 |
- |
220 |
-RDEPEND=" |
221 |
- gdb-plugin? ( ${PYTHON_DEPS} ) |
222 |
- hwloc? ( >=sys-apps/hwloc-2.5:0=[${MULTILIB_USEDEP}] ) |
223 |
- offload? ( |
224 |
- dev-libs/libffi:=[${MULTILIB_USEDEP}] |
225 |
- ~sys-devel/llvm-${PV}[${MULTILIB_USEDEP}] |
226 |
- llvm_targets_AMDGPU? ( dev-libs/rocr-runtime:0/5.3 ) |
227 |
- ) |
228 |
-" |
229 |
-# tests: |
230 |
-# - dev-python/lit provides the test runner |
231 |
-# - sys-devel/llvm provide test utils (e.g. FileCheck) |
232 |
-# - sys-devel/clang provides the compiler to run tests |
233 |
-DEPEND=" |
234 |
- ${RDEPEND} |
235 |
-" |
236 |
-BDEPEND=" |
237 |
- dev-lang/perl |
238 |
- offload? ( |
239 |
- llvm_targets_AMDGPU? ( sys-devel/clang ) |
240 |
- llvm_targets_NVPTX? ( sys-devel/clang ) |
241 |
- virtual/pkgconfig |
242 |
- ) |
243 |
- test? ( |
244 |
- ${PYTHON_DEPS} |
245 |
- $(python_gen_cond_dep ' |
246 |
- dev-python/lit[${PYTHON_USEDEP}] |
247 |
- ') |
248 |
- sys-devel/clang |
249 |
- ) |
250 |
-" |
251 |
- |
252 |
-LLVM_COMPONENTS=( openmp cmake llvm/include ) |
253 |
-llvm.org_set_globals |
254 |
- |
255 |
-kernel_pds_check() { |
256 |
- if use kernel_linux && kernel_is -lt 4 15 && kernel_is -ge 4 13; then |
257 |
- local CONFIG_CHECK="~!SCHED_PDS" |
258 |
- local ERROR_SCHED_PDS="\ |
259 |
-PDS scheduler versions >= 0.98c < 0.98i (e.g. used in kernels >= 4.13-pf11 |
260 |
-< 4.14-pf9) do not implement sched_yield() call which may result in horrible |
261 |
-performance problems with libomp. If you are using one of the specified |
262 |
-kernel versions, you may want to disable the PDS scheduler." |
263 |
- |
264 |
- check_extra_config |
265 |
- fi |
266 |
-} |
267 |
- |
268 |
-pkg_pretend() { |
269 |
- kernel_pds_check |
270 |
-} |
271 |
- |
272 |
-pkg_setup() { |
273 |
- use offload && LLVM_MAX_SLOT=${LLVM_MAJOR} llvm_pkg_setup |
274 |
- if use gdb-plugin || use test; then |
275 |
- python-single-r1_pkg_setup |
276 |
- fi |
277 |
-} |
278 |
- |
279 |
-multilib_src_configure() { |
280 |
- # LTO causes issues in other packages building, #870127 |
281 |
- filter-lto |
282 |
- |
283 |
- # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844 |
284 |
- use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG" |
285 |
- |
286 |
- local build_omptarget=OFF |
287 |
- # upstream disallows building libomptarget when sizeof(void*) != 8 |
288 |
- if use offload && |
289 |
- "$(tc-getCC)" ${CFLAGS} ${CPPFLAGS} -c -x c - -o /dev/null \ |
290 |
- <<-EOF &>/dev/null |
291 |
- int test[sizeof(void *) == 8 ? 1 : -1]; |
292 |
- EOF |
293 |
- then |
294 |
- build_omptarget=ON |
295 |
- fi |
296 |
- |
297 |
- local libdir="$(get_libdir)" |
298 |
- local mycmakeargs=( |
299 |
- -DOPENMP_LIBDIR_SUFFIX="${libdir#lib}" |
300 |
- |
301 |
- -DLIBOMP_USE_HWLOC=$(usex hwloc) |
302 |
- -DLIBOMP_OMPD_GDB_SUPPORT=$(multilib_native_usex gdb-plugin) |
303 |
- -DLIBOMP_OMPT_SUPPORT=$(usex ompt) |
304 |
- |
305 |
- -DOPENMP_ENABLE_LIBOMPTARGET=${build_omptarget} |
306 |
- |
307 |
- # do not install libgomp.so & libiomp5.so aliases |
308 |
- -DLIBOMP_INSTALL_ALIASES=OFF |
309 |
- # disable unnecessary hack copying stuff back to srcdir |
310 |
- -DLIBOMP_COPY_EXPORTS=OFF |
311 |
- ) |
312 |
- |
313 |
- if [[ ${build_omptarget} == ON ]]; then |
314 |
- if has "${CHOST%%-*}" aarch64 powerpc64le x86_64; then |
315 |
- mycmakeargs+=( |
316 |
- -DLIBOMPTARGET_BUILD_AMDGPU_PLUGIN=$(usex llvm_targets_AMDGPU) |
317 |
- -DLIBOMPTARGET_BUILD_CUDA_PLUGIN=$(usex llvm_targets_NVPTX) |
318 |
- ) |
319 |
- else |
320 |
- mycmakeargs+=( |
321 |
- -DLIBOMPTARGET_BUILD_AMDGPU_PLUGIN=OFF |
322 |
- -DLIBOMPTARGET_BUILD_CUDA_PLUGIN=OFF |
323 |
- ) |
324 |
- fi |
325 |
- fi |
326 |
- |
327 |
- use test && mycmakeargs+=( |
328 |
- # this project does not use standard LLVM cmake macros |
329 |
- -DOPENMP_LLVM_LIT_EXECUTABLE="${EPREFIX}/usr/bin/lit" |
330 |
- -DOPENMP_LIT_ARGS="$(get_lit_flags)" |
331 |
- |
332 |
- -DOPENMP_TEST_C_COMPILER="$(type -P "${CHOST}-clang")" |
333 |
- -DOPENMP_TEST_CXX_COMPILER="$(type -P "${CHOST}-clang++")" |
334 |
- ) |
335 |
- addpredict /dev/nvidiactl |
336 |
- cmake_src_configure |
337 |
-} |
338 |
- |
339 |
-multilib_src_test() { |
340 |
- # respect TMPDIR! |
341 |
- local -x LIT_PRESERVES_TMP=1 |
342 |
- |
343 |
- cmake_build check-libomp |
344 |
-} |
345 |
|
346 |
diff --git a/sys-libs/libomp/libomp-17.0.0_pre20230218.ebuild b/sys-libs/libomp/libomp-17.0.0_pre20230218.ebuild |
347 |
deleted file mode 100644 |
348 |
index 6bb50cb9edf9..000000000000 |
349 |
--- a/sys-libs/libomp/libomp-17.0.0_pre20230218.ebuild |
350 |
+++ /dev/null |
351 |
@@ -1,149 +0,0 @@ |
352 |
-# Copyright 1999-2023 Gentoo Authors |
353 |
-# Distributed under the terms of the GNU General Public License v2 |
354 |
- |
355 |
-EAPI=8 |
356 |
- |
357 |
-PYTHON_COMPAT=( python3_{9..11} ) |
358 |
-inherit flag-o-matic cmake-multilib linux-info llvm llvm.org |
359 |
-inherit python-single-r1 toolchain-funcs |
360 |
- |
361 |
-DESCRIPTION="OpenMP runtime library for LLVM/clang compiler" |
362 |
-HOMEPAGE="https://openmp.llvm.org" |
363 |
- |
364 |
-LICENSE="Apache-2.0-with-LLVM-exceptions || ( UoI-NCSA MIT )" |
365 |
-SLOT="0/${LLVM_SOABI}" |
366 |
-KEYWORDS="" |
367 |
-IUSE=" |
368 |
- debug gdb-plugin hwloc offload ompt test |
369 |
- llvm_targets_AMDGPU llvm_targets_NVPTX |
370 |
-" |
371 |
-REQUIRED_USE=" |
372 |
- gdb-plugin? ( ${PYTHON_REQUIRED_USE} ) |
373 |
-" |
374 |
-RESTRICT="!test? ( test )" |
375 |
- |
376 |
-RDEPEND=" |
377 |
- gdb-plugin? ( ${PYTHON_DEPS} ) |
378 |
- hwloc? ( >=sys-apps/hwloc-2.5:0=[${MULTILIB_USEDEP}] ) |
379 |
- offload? ( |
380 |
- dev-libs/libffi:=[${MULTILIB_USEDEP}] |
381 |
- ~sys-devel/llvm-${PV}[${MULTILIB_USEDEP}] |
382 |
- llvm_targets_AMDGPU? ( dev-libs/rocr-runtime:0/5.3 ) |
383 |
- ) |
384 |
-" |
385 |
-# tests: |
386 |
-# - dev-python/lit provides the test runner |
387 |
-# - sys-devel/llvm provide test utils (e.g. FileCheck) |
388 |
-# - sys-devel/clang provides the compiler to run tests |
389 |
-DEPEND=" |
390 |
- ${RDEPEND} |
391 |
-" |
392 |
-BDEPEND=" |
393 |
- dev-lang/perl |
394 |
- offload? ( |
395 |
- llvm_targets_AMDGPU? ( sys-devel/clang ) |
396 |
- llvm_targets_NVPTX? ( sys-devel/clang ) |
397 |
- virtual/pkgconfig |
398 |
- ) |
399 |
- test? ( |
400 |
- ${PYTHON_DEPS} |
401 |
- $(python_gen_cond_dep ' |
402 |
- dev-python/lit[${PYTHON_USEDEP}] |
403 |
- ') |
404 |
- sys-devel/clang |
405 |
- ) |
406 |
-" |
407 |
- |
408 |
-LLVM_COMPONENTS=( openmp cmake llvm/include ) |
409 |
-llvm.org_set_globals |
410 |
- |
411 |
-kernel_pds_check() { |
412 |
- if use kernel_linux && kernel_is -lt 4 15 && kernel_is -ge 4 13; then |
413 |
- local CONFIG_CHECK="~!SCHED_PDS" |
414 |
- local ERROR_SCHED_PDS="\ |
415 |
-PDS scheduler versions >= 0.98c < 0.98i (e.g. used in kernels >= 4.13-pf11 |
416 |
-< 4.14-pf9) do not implement sched_yield() call which may result in horrible |
417 |
-performance problems with libomp. If you are using one of the specified |
418 |
-kernel versions, you may want to disable the PDS scheduler." |
419 |
- |
420 |
- check_extra_config |
421 |
- fi |
422 |
-} |
423 |
- |
424 |
-pkg_pretend() { |
425 |
- kernel_pds_check |
426 |
-} |
427 |
- |
428 |
-pkg_setup() { |
429 |
- use offload && LLVM_MAX_SLOT=${LLVM_MAJOR} llvm_pkg_setup |
430 |
- if use gdb-plugin || use test; then |
431 |
- python-single-r1_pkg_setup |
432 |
- fi |
433 |
-} |
434 |
- |
435 |
-multilib_src_configure() { |
436 |
- # LTO causes issues in other packages building, #870127 |
437 |
- filter-lto |
438 |
- |
439 |
- # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844 |
440 |
- use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG" |
441 |
- |
442 |
- local build_omptarget=OFF |
443 |
- # upstream disallows building libomptarget when sizeof(void*) != 8 |
444 |
- if use offload && |
445 |
- "$(tc-getCC)" ${CFLAGS} ${CPPFLAGS} -c -x c - -o /dev/null \ |
446 |
- <<-EOF &>/dev/null |
447 |
- int test[sizeof(void *) == 8 ? 1 : -1]; |
448 |
- EOF |
449 |
- then |
450 |
- build_omptarget=ON |
451 |
- fi |
452 |
- |
453 |
- local libdir="$(get_libdir)" |
454 |
- local mycmakeargs=( |
455 |
- -DOPENMP_LIBDIR_SUFFIX="${libdir#lib}" |
456 |
- |
457 |
- -DLIBOMP_USE_HWLOC=$(usex hwloc) |
458 |
- -DLIBOMP_OMPD_GDB_SUPPORT=$(multilib_native_usex gdb-plugin) |
459 |
- -DLIBOMP_OMPT_SUPPORT=$(usex ompt) |
460 |
- |
461 |
- -DOPENMP_ENABLE_LIBOMPTARGET=${build_omptarget} |
462 |
- |
463 |
- # do not install libgomp.so & libiomp5.so aliases |
464 |
- -DLIBOMP_INSTALL_ALIASES=OFF |
465 |
- # disable unnecessary hack copying stuff back to srcdir |
466 |
- -DLIBOMP_COPY_EXPORTS=OFF |
467 |
- ) |
468 |
- |
469 |
- if [[ ${build_omptarget} == ON ]]; then |
470 |
- if has "${CHOST%%-*}" aarch64 powerpc64le x86_64; then |
471 |
- mycmakeargs+=( |
472 |
- -DLIBOMPTARGET_BUILD_AMDGPU_PLUGIN=$(usex llvm_targets_AMDGPU) |
473 |
- -DLIBOMPTARGET_BUILD_CUDA_PLUGIN=$(usex llvm_targets_NVPTX) |
474 |
- ) |
475 |
- else |
476 |
- mycmakeargs+=( |
477 |
- -DLIBOMPTARGET_BUILD_AMDGPU_PLUGIN=OFF |
478 |
- -DLIBOMPTARGET_BUILD_CUDA_PLUGIN=OFF |
479 |
- ) |
480 |
- fi |
481 |
- fi |
482 |
- |
483 |
- use test && mycmakeargs+=( |
484 |
- # this project does not use standard LLVM cmake macros |
485 |
- -DOPENMP_LLVM_LIT_EXECUTABLE="${EPREFIX}/usr/bin/lit" |
486 |
- -DOPENMP_LIT_ARGS="$(get_lit_flags)" |
487 |
- |
488 |
- -DOPENMP_TEST_C_COMPILER="$(type -P "${CHOST}-clang")" |
489 |
- -DOPENMP_TEST_CXX_COMPILER="$(type -P "${CHOST}-clang++")" |
490 |
- ) |
491 |
- addpredict /dev/nvidiactl |
492 |
- cmake_src_configure |
493 |
-} |
494 |
- |
495 |
-multilib_src_test() { |
496 |
- # respect TMPDIR! |
497 |
- local -x LIT_PRESERVES_TMP=1 |
498 |
- |
499 |
- cmake_build check-libomp |
500 |
-} |