summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarek Szuba <marecki@gentoo.org>2017-03-24 16:06:51 +0100
committerMarek Szuba <marecki@gentoo.org>2017-03-24 16:08:07 +0100
commitbae64690e192a4cc9c5620b9c491351362da683a (patch)
tree6e918de57bea58eab8c68c043aa3bdbdb6b0e9e1 /dev-libs
parentapp-portage/eclass-manpages: Add instruction on creating snaps (diff)
downloadgentoo-bae64690e192a4cc9c5620b9c491351362da683a.tar.gz
gentoo-bae64690e192a4cc9c5620b9c491351362da683a.tar.bz2
gentoo-bae64690e192a4cc9c5620b9c491351362da683a.zip
dev-libs/beignet: bump to 1.3.1
Package-Manager: Portage-2.3.3, Repoman-2.3.1
Diffstat (limited to 'dev-libs')
-rw-r--r--dev-libs/beignet/Manifest1
-rw-r--r--dev-libs/beignet/beignet-1.3.1.ebuild104
-rw-r--r--dev-libs/beignet/files/beignet-1.3.1-oclicd_no_upstream_icdfile.patch14
3 files changed, 119 insertions, 0 deletions
diff --git a/dev-libs/beignet/Manifest b/dev-libs/beignet/Manifest
index 1314f8e25fe6..3fe61eede1c6 100644
--- a/dev-libs/beignet/Manifest
+++ b/dev-libs/beignet/Manifest
@@ -1,2 +1,3 @@
DIST beignet-1.2.1-source.tar.gz 1080590 SHA256 b74eb03534a12b86a896cdbd8209b072c8a38e7af456195793a498428a7ac81f SHA512 f0d0d0590be1624928d9ee1a0666f49d908eff1ee9c1a7a28c4e680523419e544f607899bcfdae7f4ce5d32d411739afb481c0c22383db4a7381ccc71326e7f2 WHIRLPOOL 74bb72220e865406100a232fd8755b37746acf3616adbc7c66389a7a7ef3d7ca959ea1234d167091161019c1c3fc0fb9b877fc70af695bd2d2bb232c83725322
DIST beignet-1.3.0-source.tar.gz 1133643 SHA256 63d98b4fe8fba3dbc0299d29fef84560625e5ac51b16b8fed453021d4afb5cd5 SHA512 7eb3c8bca484462787a6b4d360059b63608305b171e33078f1b65dcbcbf6831bcca95e762af3f4f0b9c99449c7d607e63ea138149b9f3a854d7017df927aa7ee WHIRLPOOL cbaa92f67a5f53b3d3243dd08c9a680c734b732601667a40ba147023fa96c0b4f78794f76011ab172c66265ad4bf0eddd5b6b301fc0a67790dc3d30c23d7ec83
+DIST beignet-1.3.1-source.tar.gz 1136608 SHA256 399b7bc64d674b3092683263f7c085c5592686b9d837817e77857248e5cb561f SHA512 727c8ce68dc39672aa37370ebf2748955925a7cfd58c970c9a641706b45cc31d4a7d3eeebc366ed32ef69add5dd36189814454e5b31f12a6f09ea1a51c810338 WHIRLPOOL 528667a58fbd446e7177edc578543b301205a05fae99d3b1d3782792cac564683e7318fe4e83d81c194ee29fa6cca613e86ce8064f26b551385c8b6c51f4b21e
diff --git a/dev-libs/beignet/beignet-1.3.1.ebuild b/dev-libs/beignet/beignet-1.3.1.ebuild
new file mode 100644
index 000000000000..c49c57c7136c
--- /dev/null
+++ b/dev-libs/beignet/beignet-1.3.1.ebuild
@@ -0,0 +1,104 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PYTHON_COMPAT=( python{2_7,3_4,3_5} )
+CMAKE_BUILD_TYPE="Release"
+
+inherit python-any-r1 cmake-multilib flag-o-matic toolchain-funcs
+
+DESCRIPTION="OpenCL implementation for Intel GPUs"
+HOMEPAGE="https://01.org/beignet"
+
+LICENSE="LGPL-2.1+"
+SLOT="0"
+IUSE="ocl-icd ocl20"
+
+if [[ "${PV}" == "9999" ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="git://anongit.freedesktop.org/beignet"
+ KEYWORDS=""
+else
+ KEYWORDS="~amd64"
+ SRC_URI="https://01.org/sites/default/files/${P}-source.tar.gz"
+ S=${WORKDIR}/Beignet-${PV}-Source
+fi
+
+COMMON="${PYTHON_DEPS}
+ media-libs/mesa
+ sys-devel/clang:0=
+ >=sys-devel/llvm-3.6:0=
+ ocl20? ( >=sys-devel/llvm-3.9:0= )
+ >=x11-libs/libdrm-2.4.70[video_cards_intel]
+ x11-libs/libXext
+ x11-libs/libXfixes"
+RDEPEND="${COMMON}
+ app-eselect/eselect-opencl"
+DEPEND="${COMMON}
+ ${PYTHON_DEPS}
+ ocl-icd? ( dev-libs/ocl-icd )
+ virtual/pkgconfig"
+
+PATCHES=(
+ "${FILESDIR}"/no-debian-multiarch.patch
+ "${FILESDIR}"/${P}-oclicd_no_upstream_icdfile.patch
+ "${FILESDIR}"/${PN}-1.2.0_no-hardcoded-cflags.patch
+ "${FILESDIR}"/llvm-terminfo.patch
+)
+
+DOCS=(
+ docs/.
+)
+
+pkg_pretend() {
+ if [[ ${MERGE_TYPE} != "binary" ]]; then
+ if tc-is-gcc; then
+ if [[ $(gcc-major-version) -eq 4 ]] && [[ $(gcc-minor-version) -lt 6 ]]; then
+ eerror "Compilation with gcc older than 4.6 is not supported"
+ die "Too old gcc found."
+ fi
+ fi
+ fi
+}
+
+pkg_setup() {
+ python_setup
+}
+
+src_prepare() {
+ # See Bug #593968
+ append-flags -fPIC
+
+ cmake-utils_src_prepare
+ # We cannot run tests because they require permissions to access
+ # the hardware, and building them is very time-consuming.
+ cmake_comment_add_subdirectory utests
+}
+
+multilib_src_configure() {
+ VENDOR_DIR="/usr/$(get_libdir)/OpenCL/vendors/${PN}"
+
+ local mycmakeargs=(
+ -DCMAKE_INSTALL_PREFIX="${VENDOR_DIR}"
+ -DOCLICD_COMPAT=$(usex ocl-icd)
+ -DENABLE_OPENCL_20=$(usex ocl20)
+ )
+
+ cmake-utils_src_configure
+}
+
+multilib_src_install() {
+ VENDOR_DIR="/usr/$(get_libdir)/OpenCL/vendors/${PN}"
+
+ cmake-utils_src_install
+
+ insinto /etc/OpenCL/vendors/
+ echo "${VENDOR_DIR}/lib/${PN}/libcl.so" > "${PN}-${ABI}.icd" || die "Failed to generate ICD file"
+ doins "${PN}-${ABI}.icd"
+
+ dosym "lib/${PN}/libcl.so" "${VENDOR_DIR}"/libOpenCL.so.1
+ dosym "lib/${PN}/libcl.so" "${VENDOR_DIR}"/libOpenCL.so
+ dosym "lib/${PN}/libcl.so" "${VENDOR_DIR}"/libcl.so.1
+ dosym "lib/${PN}/libcl.so" "${VENDOR_DIR}"/libcl.so
+}
diff --git a/dev-libs/beignet/files/beignet-1.3.1-oclicd_no_upstream_icdfile.patch b/dev-libs/beignet/files/beignet-1.3.1-oclicd_no_upstream_icdfile.patch
new file mode 100644
index 000000000000..7e9e88361b42
--- /dev/null
+++ b/dev-libs/beignet/files/beignet-1.3.1-oclicd_no_upstream_icdfile.patch
@@ -0,0 +1,14 @@
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -213,11 +213,6 @@
+ Find_Package(OCLIcd)
+ IF(OCLIcd_FOUND)
+ MESSAGE(STATUS "Looking for OCL ICD header file - found")
+- configure_file (
+- "intel-beignet.icd.in"
+- "${ICD_FILE_NAME}"
+- )
+- install (FILES ${CMAKE_CURRENT_BINARY_DIR}/${ICD_FILE_NAME} DESTINATION /etc/OpenCL/vendors)
+ ELSE(OCLIcd_FOUND)
+ MESSAGE(STATUS "Looking for OCL ICD header file - not found")
+ MESSAGE(FATAL_ERROR "OCL ICD loader miss. If you really want to disable OCL ICD support, please run cmake with option -DOCLICD_COMPAT=0.")