summaryrefslogtreecommitdiff
path: root/dev-libs
diff options
context:
space:
mode:
Diffstat (limited to 'dev-libs')
-rw-r--r--dev-libs/Manifest.gzbin100173 -> 100183 bytes
-rw-r--r--dev-libs/gobject-introspection/Manifest2
-rw-r--r--dev-libs/gobject-introspection/gobject-introspection-1.78.1.ebuild2
-rw-r--r--dev-libs/libmirage/Manifest2
-rw-r--r--dev-libs/libmirage/libmirage-3.2.8.ebuild55
-rw-r--r--dev-libs/pocl/Manifest5
-rw-r--r--dev-libs/pocl/files/pocl-5.0-missing-definitions-fix.patch41
-rw-r--r--dev-libs/pocl/pocl-5.0.ebuild115
-rw-r--r--dev-libs/pocl/pocl-6.0.ebuild115
9 files changed, 335 insertions, 2 deletions
diff --git a/dev-libs/Manifest.gz b/dev-libs/Manifest.gz
index d2730f431ef0..9f0ce77bda66 100644
--- a/dev-libs/Manifest.gz
+++ b/dev-libs/Manifest.gz
Binary files differ
diff --git a/dev-libs/gobject-introspection/Manifest b/dev-libs/gobject-introspection/Manifest
index bb5242d0f1fb..9599ea048fe4 100644
--- a/dev-libs/gobject-introspection/Manifest
+++ b/dev-libs/gobject-introspection/Manifest
@@ -2,5 +2,5 @@ AUX gobject-introspection-1.78.1-tests-py312.patch 2770 BLAKE2B 18e74962bddd40e7
DIST gobject-introspection-1.76.1.tar.xz 1055416 BLAKE2B 2251c34b543c95f95bdec6853c8234db1b2e6271e729eaa5abf28e39c7718b326e0813a1214c62fb4634fd11218c4c856e6651de09081b01c9fcf8f73b8cf316 SHA512 84331a30f8854d2259609650c21aadd6363ea1417a75828bd395f8f4346da1c6d6550cff5f2c9f5f6fd6fbf2a9d27b5880c2ee1616fa905c5f362384d481a916
DIST gobject-introspection-1.78.1.tar.xz 1060296 BLAKE2B 115cf9ea27cec2d8d3a84081c909b72144fd1568bc316677c26f49652dc93b34fba10701678ad4977dcf97a89f7608545fbd2d73c2503c87635b2102e66ae024 SHA512 a3081882995a762645b04faa71082dbd523bee845519007e48b13235aad8a4cd4c74f0d042a6c17710125f945bd970e4b76e95a559274e294d595e04725a4e97
EBUILD gobject-introspection-1.76.1.ebuild 1960 BLAKE2B c399a1996b2f45bf4dbab33e5d2a5e1773066eb7e2d6761102733c4cbc2ac4ac42e4aaa21fa8eeee172f07e1307d737e33b065482e8007b4517af305bd923c44 SHA512 dd66aaa7dbb68ac507800fb1b7f07f08944120c6bc394461f6ec5f35d84ded3bc65ef722744363f96806f713fa66fd1815152af795661f5b3583cde8cd68dd03
-EBUILD gobject-introspection-1.78.1.ebuild 2079 BLAKE2B 96f614ae767252c9f933763ddda3f426d535a4a10a5027bc266882988256ed97da396c5e4be0d47da5de4170651c4b71c439075e7e25422242ea774310bfd4bd SHA512 5aa28d1ac91ef523f2248625e0ccdd3abbccb2b4e81c4ed6fa7219a509ed9e7fc5425750331cfedef3adaddd20092fbda3613b7cc263d8ec578d4da7f1daa1e6
+EBUILD gobject-introspection-1.78.1.ebuild 2079 BLAKE2B b2474e1d98196407e1b9de23948e03b7760746636fc7008bfd7684b4845285033f93b77588b2b22259077d7451ab706e065213a0835ce9c09f8d3e5d81d9283e SHA512 5884026cf73b3f852a0404f8a1b4cbd6d11618584ff4155577ae6558e18923fd5c521c04c2e5c60790beb296eb597ffb9d10ce344bca3db14b97d5aafd35f260
MISC metadata.xml 485 BLAKE2B 6ecc9396bcb29a8365be4058592c307ddcb0cc16ab56723ca32a378b5608b86378ab291345a6a3ccbe8225c6ffc91b6ba1e2996b5b0d1f4271d0757bf376ef8e SHA512 43a479854b1d5783c028ecfd8357a632db089f95de9e703608de7f229a37beee5e43781ff3f68b2dfa9bceac1355597373d31d209fdea0301917be5fbe7e7fbe
diff --git a/dev-libs/gobject-introspection/gobject-introspection-1.78.1.ebuild b/dev-libs/gobject-introspection/gobject-introspection-1.78.1.ebuild
index e54b7e1668da..b9506b1ab48c 100644
--- a/dev-libs/gobject-introspection/gobject-introspection-1.78.1.ebuild
+++ b/dev-libs/gobject-introspection/gobject-introspection-1.78.1.ebuild
@@ -3,7 +3,7 @@
EAPI=8
-PYTHON_COMPAT=( python3_{10..12} )
+PYTHON_COMPAT=( python3_{10..13} )
PYTHON_REQ_USE="xml(+)"
inherit gnome.org meson python-single-r1 xdg
diff --git a/dev-libs/libmirage/Manifest b/dev-libs/libmirage/Manifest
index 551b57f22d59..887151cd78ec 100644
--- a/dev-libs/libmirage/Manifest
+++ b/dev-libs/libmirage/Manifest
@@ -1,3 +1,5 @@
DIST libmirage-3.2.7.tar.xz 229564 BLAKE2B e1e02526fcd8daec8716e0457e38be68df9e13f8609e29772c2bee080ace7e5e76112c6ffb57719144a8c9acddc942dd44e827371ffe90673cd34b0ba0f74b08 SHA512 cbb2e98dca93009c9395d1d29dc529cf4cf912b64f166c0652ee4193c83f3e93ee1f4af623f8f0903ad1d77634fe89e5c3076d138678bcb84641880e1a1d1f76
+DIST libmirage-3.2.8.tar.xz 229616 BLAKE2B 37b662bbeff84144ee2ff2e6225af022cd031ef7db7734d22510cef6b1b9599c603c009c603fdb43fa13877858fc5871cd8c7fa68739f06dab60d910c9577db6 SHA512 ab4f099dd3a0a7705d7ee828cf023ab61185e3d5fbf324823a55ee604a008b66a206b8f666c0482b0eac6ac144a2421f04badd2e3e11dbc5e7bd2b211dcb2716
EBUILD libmirage-3.2.7.ebuild 1166 BLAKE2B 6bdf2147d0210f0b3d2402e08d464da17b678dcc3084bc8e0e6f9f603b4b5bfec293a345dde10ff6e9d7ce9db0a4b78feb649151bfa32a7abbf8a39caf46dca5 SHA512 80858020e3ac94ff50e2e681c5ed8261402d5e8a681ff7f6bb37278276796102cfd9be555a6cc3f3a58d68b4a6741f14eeab5d00480d6db688451e62def73664
+EBUILD libmirage-3.2.8.ebuild 1137 BLAKE2B a9d12fbaf260244c76915cb5ae5c1660fb7b579243c2bf9864ca82fe8a1192f3bd3976d56c0a6e6b54c2b24618912565ce5aae81ea05f74eca76ccb167cc05d5 SHA512 abaffe9ff33bf6a694c57bb7c7110762e4761d3d523f5536d2d1183c8b1f7c9b0e9a9b0faac59d91fd49b40fe58ab873b92f183fbe8ef672bc417190197543d8
MISC metadata.xml 386 BLAKE2B c36f939406f1162a5f368c5ccd061fb81d010b324b8195227b4ad60cdd86fe1b614e0bafa3ffa5b2c1e9c601e1a05ea235ddb51636f80e9f84769661d10f5d9b SHA512 6c7b47259051bda83c8acfd6b1e97647af66dd34c0f12e3cf80d5bb24ebfd562d9da8ed21a687d634d5263317f366c91e9861abdf7c99e094669687d604dd0ab
diff --git a/dev-libs/libmirage/libmirage-3.2.8.ebuild b/dev-libs/libmirage/libmirage-3.2.8.ebuild
new file mode 100644
index 000000000000..ec9d1a2848d6
--- /dev/null
+++ b/dev-libs/libmirage/libmirage-3.2.8.ebuild
@@ -0,0 +1,55 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake xdg-utils
+
+DESCRIPTION="CD and DVD image access library"
+HOMEPAGE="https://cdemu.sourceforge.io"
+SRC_URI="https://download.sourceforge.net/cdemu/libmirage/${P}.tar.xz"
+
+LICENSE="GPL-2+"
+SLOT="0/11"
+KEYWORDS="~amd64 ~x86"
+IUSE="doc +introspection"
+
+DEPEND="
+ >=app-arch/bzip2-1:=
+ >=app-arch/xz-utils-5:=
+ >=dev-libs/glib-2.38:2
+ >=media-libs/libsamplerate-0.1:=
+ >=media-libs/libsndfile-1.0:=
+ sys-libs/zlib:=
+ introspection? ( >=dev-libs/gobject-introspection-1.30 )
+"
+RDEPEND="
+ ${DEPEND}
+"
+BDEPEND="
+ dev-util/desktop-file-utils
+ dev-util/intltool
+ sys-devel/gettext
+ virtual/pkgconfig
+ doc? ( dev-util/gtk-doc )
+ introspection? ( >=dev-libs/gobject-introspection-1.30 )
+"
+
+DOCS=( AUTHORS README )
+
+src_configure() {
+ local mycmakeargs=(
+ -DGTKDOC_ENABLED="$(usex doc)"
+ -DINTROSPECTION_ENABLED="$(usex introspection)"
+ -DPOST_INSTALL_HOOKS=OFF # avoid sandbox violation, #487304
+ )
+ cmake_src_configure
+}
+
+pkg_postinst() {
+ xdg_mimeinfo_database_update
+}
+
+pkg_postrm() {
+ xdg_mimeinfo_database_update
+}
diff --git a/dev-libs/pocl/Manifest b/dev-libs/pocl/Manifest
index 6a171140179c..de5a81d1bd84 100644
--- a/dev-libs/pocl/Manifest
+++ b/dev-libs/pocl/Manifest
@@ -1,3 +1,8 @@
+AUX pocl-5.0-missing-definitions-fix.patch 3832 BLAKE2B f2487dc9eb6c2df4ecbb80fb27310276e1bda3703c316628bf639b714d3f1d22044f645ed34c6dbc756e44de5c1dcec2e53448a58284e93918bfbe38b2f17405 SHA512 0a8f10992a7db8df7c6e56c510c5e346dfdf8a9d085953250cb3eee8df50264e70927c2530dad91205482dd9c6775b86a4a1cedeb024f3dd262d0efd4ea39d54
DIST pocl-4.0.tar.gz 2140919 BLAKE2B 1e9dd4de4824dd4a9e2b0d053d1786062c135d3bf7ca99dc884657b89c651fca6c0f3dedb568439802a58b0bfabc10939ca344b0110ae5fdb31be06f596d2a48 SHA512 3835a9e8fc8562d50a91a11b807cf87a096891f5c27675127b66412eacff2e541b6143b49b4155f43a09f4e53faa062ec20f3b20badeca206ece9f45ad50f26a
+DIST pocl-5.0.tar.gz 2361502 BLAKE2B eca07953ff56e7e4ca10f71db12819547bc8ff28da26e569c3544edd802f9ded0a8bd0d9cb260069cfe3788f9bc6c84d6ae96c1148c4e92fe6268a95a60ee5b6 SHA512 c2d6c80cbcba7af1c31dfa794c2aa7be6d1ce2cc9900fbf6e0a1536747440602cdc0f1a84f81f85737818a7ea60b490558ef328b3b156e52c63db3fe4ce490b0
+DIST pocl-6.0.tar.gz 2466652 BLAKE2B e074f35bfe8ccd70038fe05ca01da033849bed83075330f1149597455a5892281d4d09b8db5b4731e7e0c248d1ffdc8e8707c1ebe53d50624294ad92aa886be6 SHA512 a24efadbbb81c810cd5c4bbb8abfa75b9bbdfeca786e8471dd75d40a78024d04c1b5c5a7114e75e1eb70a1b6a3756bb47ba741de0f1c4d1416fbce4688d62cc0
EBUILD pocl-4.0.ebuild 3059 BLAKE2B adb846af8030fa7be32a4d4f0d75237a9325507ee929f61826a1bc781e2462d35e46efa2b46495cf8a221116c275fcfdc5ebf48f6daf5a6b1d0dcd64ba0d9802 SHA512 33c083f0c023446ef43d441d79dc6eb378f1cb6c1a30ddec591894636ec845d4c909aab45977676ab6629454103681bf2741ad8ca8ce239435140a1902367bfc
+EBUILD pocl-5.0.ebuild 3123 BLAKE2B 16a8c0aee115f388a7ea8715962647136949d544c899596b2cb3e5a14645082490c2b3d994ee59de4b068bf73248dafba106ce9e58527c6a67d3e8959c2f7a78 SHA512 8f4c7184b874e3fe68d52079f5233f7590ae03f69b1ddaf602f473eb547558a6a2f33a03f79b541fe6cdd9e70e479449707731848b907969201fa48bcf1b5b97
+EBUILD pocl-6.0.ebuild 2847 BLAKE2B 12d9587babbd8ea84f91e6905fc381ed6966962724ba2f4a78f5fb6e7fc9000a5a09987304ef9980a366d599f0c6df43ca9d2ae5e3e351f989045dab6abcbdac SHA512 a7f1d6d925b07ce8ddaf299ef2fae2c8380bbdfb2c270c7f00e8f20d52e367a039b2adc755a78559705b33380345f6a20878078a119814089d8dff3ab03251b4
MISC metadata.xml 1058 BLAKE2B 8bc6e959a3683f8f1ebdb45950b72a0205e0e347e2140e3bc32e0df578bc567c87b48a0b5acc00cac3c9dd7da1d6c9e67c797a3e9b8c471810893e82abe23576 SHA512 99c20d26d65dc26ebab7818ccd3e5b15ab5b22c82bdd37493c02f80b234f80c6ca6ab369cb69f914ea3812aaceebde400504532d2d0b80d6422f3873d0f7ac06
diff --git a/dev-libs/pocl/files/pocl-5.0-missing-definitions-fix.patch b/dev-libs/pocl/files/pocl-5.0-missing-definitions-fix.patch
new file mode 100644
index 000000000000..251bdad65bd6
--- /dev/null
+++ b/dev-libs/pocl/files/pocl-5.0-missing-definitions-fix.patch
@@ -0,0 +1,41 @@
+Fixes missing definitions.
+
+FAILED: lib/CL/devices/almaif/CMakeFiles/pocl-devices-almaif.dir/MMAPDevice.cc.o
+/usr/bin/x86_64-pc-linux-gnu-g++ -DCL_HPP_TARGET_OPENCL_VERSION=300 -DCL_TARGET_OPENCL_VERSION=300 -DCL_USE_DEPRECATED_OPENCL_1_0_APIS -DCL_USE_DEPRECATED_OPENCL_1_1_APIS -DCL_USE_DEPRECATED_OPENCL_1_2_APIS -DCL_USE_DEPRECATED_OPENCL_2_0_APIS -DCL_USE_DEPRECATED_OPENCL_2_1_APIS -DCL_USE_DEPRECATED_OPENCL_2_2_APIS -Dpocl_devices_almaif_EXPORTS -I/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0_build -I/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/include -I/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/include/hpp -I/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/devices -I/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/. -O2 -pipe -march=x86-64 -mtune=generic -std=c++11 -fPIC -Wno-ignored-attributes -fvisibility=hidden -fvisibility-inlines-hidden -MD -MT lib/CL/devices/almaif/CMakeFiles/pocl-devices-almaif.dir/MMAPDevice.cc.o -MF lib/CL/devices/almaif/CMakeFiles/pocl-devices-almaif.dir/MMAPDevice.cc.o.d -o lib/CL/devices/almaif/CMakeFiles/pocl-devices-almaif.dir/MMAPDevice.cc.o -c /var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/devices/almaif/MMAPDevice.cc
+In file included from /var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/devices/almaif/MMAPDevice.hh:28,
+ from /var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/devices/almaif/MMAPDevice.cc:24:
+/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/devices/almaif/AlmaIFDevice.hh:45:36: error: ‘cl_kernel’ has not been declared
+ 45 | cl_kernel Kernel, _cl_command_node *Command);
+ | ^~~~~~~~~
+/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/devices/almaif/AlmaIFDevice.hh:45:54: error: ‘_cl_command_node’ has not been declared
+ 45 | cl_kernel Kernel, _cl_command_node *Command);
+ | ^~~~~~~~~~~~~~~~
+/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/devices/almaif/AlmaIFDevice.hh:67:34: error: ‘pocl_mem_identifier’ has not been declared
+ 67 | virtual void writeDataToDevice(pocl_mem_identifier *DstMemId,
+ | ^~~~~~~~~~~~~~~~~~~
+/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/devices/almaif/AlmaIFDevice.hh:71:35: error: ‘pocl_mem_identifier’ has not been declared
+ 71 | pocl_mem_identifier *SrcMemId, size_t Size,
+ | ^~~~~~~~~~~~~~~~~~~
+/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/devices/almaif/AlmaIFDevice.hh:79:11: error: ‘cl_int’ does not name a type; did you mean ‘u_int’?
+ 79 | virtual cl_int allocateBuffer(pocl_mem_identifier *P, size_t Size);
+ | ^~~~~~
+ | u_int
+/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/devices/almaif/AlmaIFDevice.hh:81:27: error: ‘pocl_mem_identifier’ has not been declared
+ 81 | virtual void freeBuffer(pocl_mem_identifier *P);
+ | ^~~~~~~~~~~~~~~~~~~
+/var/tmp/portage/dev-libs/pocl-5.0/work/pocl-5.0/lib/CL/devices/almaif/AlmaIFDevice.hh:83:38: error: ‘pocl_mem_identifier’ has not been declared
+ 83 | virtual size_t pointerDeviceOffset(pocl_mem_identifier *P);
+ | ^~~~~~~~~~~~~~~~~~~
+
+diff -Nuar a/lib/CL/devices/almaif/AlmaIFDevice.hh b/lib/CL/devices/almaif/AlmaIFDevice.hh
+--- a/lib/CL/devices/almaif/AlmaIFDevice.hh 2023-12-19 13:24:31.000000000 +0000
++++ b/lib/CL/devices/almaif/AlmaIFDevice.hh 2024-01-13 03:42:12.045091773 +0000
+@@ -34,6 +34,8 @@
+ #include <stdlib.h>
+ #include <string>
+
++#include "pocl_cl.h"
++
+ struct almaif_kernel_data_s;
+
+ class AlmaIFDevice {
diff --git a/dev-libs/pocl/pocl-5.0.ebuild b/dev-libs/pocl/pocl-5.0.ebuild
new file mode 100644
index 000000000000..16d02903db69
--- /dev/null
+++ b/dev-libs/pocl/pocl-5.0.ebuild
@@ -0,0 +1,115 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+LLVM_MAX_SLOT=17
+inherit cmake llvm
+
+DESCRIPTION="Portable Computing Language (an implementation of OpenCL)"
+HOMEPAGE="http://portablecl.org https://github.com/pocl/pocl"
+SRC_URI="https://github.com/pocl/pocl/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc64"
+# TODO: hsa tce
+IUSE="accel +conformance cuda debug examples float-conversion hardening +hwloc memmanager test"
+# Tests not yet passing, fragile in Portage environment(?)
+RESTRICT="!test? ( test ) test"
+
+# TODO: add dependencies for cuda
+# Note: No := on LLVM because it pulls in Clang
+# see llvm.eclass for why
+CLANG_DEPS="
+ !cuda? ( <sys-devel/clang-$((${LLVM_MAX_SLOT} + 1)):= )
+ cuda? ( <sys-devel/clang-$((${LLVM_MAX_SLOT} + 1)):=[llvm_targets_NVPTX] )
+"
+RDEPEND="
+ dev-libs/libltdl
+ <sys-devel/llvm-$((${LLVM_MAX_SLOT} + 1)):*
+ virtual/opencl
+
+ ${CLANG_DEPS}
+ debug? ( dev-util/lttng-ust:= )
+ hwloc? ( sys-apps/hwloc:=[cuda?] )
+"
+DEPEND="${RDEPEND}"
+BDEPEND="
+ ${CLANG_DEPS}
+ virtual/pkgconfig
+"
+
+PATCHES=( "${FILESDIR}/${P}-missing-definitions-fix.patch" )
+
+llvm_check_deps() {
+ local usedep=$(usev cuda "[llvm_targets_NVPTX]")
+
+ # Clang is used at both build time (executed) and runtime
+ has_version -r "sys-devel/llvm:${LLVM_SLOT}${usedep}" && \
+ has_version -r "sys-devel/clang:${LLVM_SLOT}${usedep}" && \
+ has_version -b "sys-devel/clang:${LLVM_SLOT}${usedep}"
+}
+
+src_configure() {
+ local host_cpu_variants="generic"
+
+ if use amd64 ; then
+ # Use pocl's curated list of CPU variants which should contain a good match for any given amd64 CPU
+ host_cpu_variants="distro"
+ elif use ppc64 ; then
+ # A selection of architectures in which new Altivec / VSX features were added
+ # This attempts to recreate the amd64 "distro" option for ppc64
+ # See discussion in bug #831859
+ host_cpu_variants="pwr10;pwr9;pwr8;pwr7;pwr6;g5;a2;generic"
+ fi
+
+ local mycmakeargs=(
+ -DENABLE_HSA=OFF
+
+ -DENABLE_ICD=ON
+ -DPOCL_ICD_ABSOLUTE_PATH=ON
+ -DPOCL_INSTALL_PUBLIC_LIBDIR="${EPREFIX}/usr/$(get_libdir)/OpenCL/vendors/pocl"
+
+ # only appends -flto
+ -DENABLE_IPO=OFF
+
+ -DENABLE_POCL_BUILDING=ON
+ -DKERNELLIB_HOST_CPU_VARIANTS="${host_cpu_variants}"
+
+ -DSTATIC_LLVM=OFF
+ -DWITH_LLVM_CONFIG=$(get_llvm_prefix -d "${LLVM_MAX_SLOT}")/bin/llvm-config
+
+ -DENABLE_ALMAIF_DEVICE=$(usex accel)
+ -DENABLE_CONFORMANCE=$(usex conformance)
+ -DENABLE_CUDA=$(usex cuda)
+ -DENABLE_HWLOC=$(usex hwloc)
+ -DENABLE_POCL_FLOAT_CONVERSION=$(usex float-conversion)
+ -DHARDENING_ENABLE=$(usex hardening)
+ -DPOCL_DEBUG_MESSAGES=$(usex debug)
+ -DUSE_POCL_MEMMANAGER=$(usex memmanager)
+ -DENABLE_TESTS=$(usex test)
+ )
+
+ cmake_src_configure
+}
+
+src_test() {
+ export POCL_BUILDING=1
+ export POCL_DEVICES=basic
+ export CTEST_OUTPUT_ON_FAILURE=1
+ export TEST_VERBOSE=1
+
+ # Referenced https://github.com/pocl/pocl/blob/master/.drone.yml
+ # But couldn't seem to get tests working yet
+ cmake_src_test
+}
+
+src_install() {
+ cmake_src_install
+
+ if use examples; then
+ dodoc -r examples
+ docompress -x /usr/share/doc/${P}/examples
+ fi
+}
diff --git a/dev-libs/pocl/pocl-6.0.ebuild b/dev-libs/pocl/pocl-6.0.ebuild
new file mode 100644
index 000000000000..c16b713bd7c3
--- /dev/null
+++ b/dev-libs/pocl/pocl-6.0.ebuild
@@ -0,0 +1,115 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+LLVM_COMPAT=( {15..18} )
+inherit cmake cuda llvm-r1
+
+DESCRIPTION="Portable Computing Language (an implementation of OpenCL)"
+HOMEPAGE="http://portablecl.org https://github.com/pocl/pocl"
+SRC_URI="https://github.com/pocl/pocl/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc64"
+# TODO: hsa tce
+IUSE="accel +conformance cuda debug examples float-conversion hardening +hwloc memmanager test"
+# Tests not yet passing, fragile in Portage environment(?)
+RESTRICT="!test? ( test ) test"
+
+CLANG_DEPS="
+ $(llvm_gen_dep '
+ !cuda? (
+ sys-devel/clang:${LLVM_SLOT}=
+ sys-devel/llvm:${LLVM_SLOT}=
+ )
+ cuda? (
+ sys-devel/clang:${LLVM_SLOT}=[llvm_targets_NVPTX]
+ sys-devel/llvm:${LLVM_SLOT}=[llvm_targets_NVPTX]
+ )
+ ')
+"
+RDEPEND="
+ ${CLANG_DEPS}
+ dev-libs/libltdl
+ virtual/opencl
+ debug? ( dev-util/lttng-ust:= )
+ cuda? ( dev-util/nvidia-cuda-toolkit:= )
+ hwloc? ( sys-apps/hwloc:=[cuda?] )
+"
+DEPEND="${RDEPEND}"
+BDEPEND="
+ ${CLANG_DEPS}
+ virtual/pkgconfig
+"
+
+src_prepare() {
+ use cuda && cuda_src_prepare
+ cmake_src_prepare
+}
+
+src_configure() {
+ local host_cpu_variants="generic"
+
+ if use amd64 ; then
+ # Use pocl's curated list of CPU variants which should contain a good match for any given amd64 CPU
+ host_cpu_variants="distro"
+ elif use ppc64 ; then
+ # A selection of architectures in which new Altivec / VSX features were added
+ # This attempts to recreate the amd64 "distro" option for ppc64
+ # See discussion in bug #831859
+ host_cpu_variants="pwr10;pwr9;pwr8;pwr7;pwr6;g5;a2;generic"
+ elif use riscv; then
+ host_cpu_variants="generic-rv64"
+ fi
+
+ local mycmakeargs=(
+ -DENABLE_HSA=OFF
+
+ -DENABLE_ICD=ON
+ -DPOCL_ICD_ABSOLUTE_PATH=ON
+ -DPOCL_INSTALL_PUBLIC_LIBDIR="${EPREFIX}/usr/$(get_libdir)/OpenCL/vendors/pocl"
+
+ # only appends -flto
+ -DENABLE_IPO=OFF
+
+ -DENABLE_POCL_BUILDING=ON
+ -DKERNELLIB_HOST_CPU_VARIANTS="${host_cpu_variants}"
+
+ -DSTATIC_LLVM=OFF
+ -DWITH_LLVM_CONFIG=$(get_llvm_prefix -d)/bin/llvm-config
+
+ -DENABLE_ALMAIF_DEVICE=$(usex accel)
+ -DENABLE_CONFORMANCE=$(usex conformance)
+ -DENABLE_CUDA=$(usex cuda)
+ -DENABLE_HWLOC=$(usex hwloc)
+ -DENABLE_POCL_FLOAT_CONVERSION=$(usex float-conversion)
+ -DHARDENING_ENABLE=$(usex hardening)
+ -DPOCL_DEBUG_MESSAGES=$(usex debug)
+ -DUSE_POCL_MEMMANAGER=$(usex memmanager)
+ -DENABLE_TESTS=$(usex test)
+ )
+
+ cmake_src_configure
+}
+
+src_test() {
+ export POCL_BUILDING=1
+ export POCL_DEVICES=basic
+ export CTEST_OUTPUT_ON_FAILURE=1
+ export TEST_VERBOSE=1
+
+ # Referenced https://github.com/pocl/pocl/blob/master/.drone.yml
+ # But couldn't seem to get tests working yet
+ cmake_src_test
+}
+
+src_install() {
+ cmake_src_install
+
+ if use examples; then
+ dodoc -r examples
+ docompress -x /usr/share/doc/${P}/examples
+ fi
+}