diff options
author | 2022-12-09 17:15:54 +0100 | |
---|---|---|
committer | 2022-12-09 17:15:54 +0100 | |
commit | 573bdf7f8b1bb93f29a86521a642b417b387dc95 (patch) | |
tree | 77afdb9c49af856ac6b0ba2ad7a59b918433dbdd /dev-libs | |
parent | dev-libs/oneCCL: also set CC (diff) | |
download | sci-573bdf7f8b1bb93f29a86521a642b417b387dc95.tar.gz sci-573bdf7f8b1bb93f29a86521a642b417b387dc95.tar.bz2 sci-573bdf7f8b1bb93f29a86521a642b417b387dc95.zip |
dev-libs/oneDNN: new package, add 2.7.2
Signed-off-by: Andrew Ammerlaan <andrewammerlaan@gentoo.org>
Diffstat (limited to 'dev-libs')
-rw-r--r-- | dev-libs/oneDNN/Manifest | 1 | ||||
-rw-r--r-- | dev-libs/oneDNN/metadata.xml | 11 | ||||
-rw-r--r-- | dev-libs/oneDNN/oneDNN-2.7.2.ebuild | 60 |
3 files changed, 72 insertions, 0 deletions
diff --git a/dev-libs/oneDNN/Manifest b/dev-libs/oneDNN/Manifest new file mode 100644 index 000000000..3f702434b --- /dev/null +++ b/dev-libs/oneDNN/Manifest @@ -0,0 +1 @@ +DIST oneDNN-2.7.2.tar.gz 6409290 BLAKE2B 8e6fb262a77469cfaddd633bf11334d04ffb641fa798f0de23e458086c66c9b7e932d45d52baf8a93453495df9280f6a97dc3f220d7674850d1ca6c525ce2a7f SHA512 faf8ea953f552afaafcc597f647a98187c8c6dabd8a532fc1b8037626fa77a8a6543dce3247d953a470391d39189ba421ab7de589a8bb7c4c38e22327ab1c401 diff --git a/dev-libs/oneDNN/metadata.xml b/dev-libs/oneDNN/metadata.xml new file mode 100644 index 000000000..0d6dc84a7 --- /dev/null +++ b/dev-libs/oneDNN/metadata.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>sci@gentoo.org</email> + <name>Gentoo Science Project</name> + </maintainer> + <upstream> + <remote-id type="github">oneapi-src/oneDNN</remote-id> + </upstream> +</pkgmetadata> diff --git a/dev-libs/oneDNN/oneDNN-2.7.2.ebuild b/dev-libs/oneDNN/oneDNN-2.7.2.ebuild new file mode 100644 index 000000000..1c66ec72c --- /dev/null +++ b/dev-libs/oneDNN/oneDNN-2.7.2.ebuild @@ -0,0 +1,60 @@ +# Copyright 2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DOCS_BUILDER="doxygen" +DOCS_DIR="${WORKDIR}/${P}_build" +# There is additional sphinx documentation but we are missing dependency doxyrest. +inherit cmake docs + +DESCRIPTION="oneAPI Deep Neural Network Library" +HOMEPAGE="https://github.com/oneapi-src/oneDNN" +SRC_URI="https://github.com/oneapi-src/oneDNN/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="~amd64" + +IUSE="test" +# TODO: get the tests up and running +#RESTRICT="!test? ( test )" +RESTRICT="test" + +BDEPEND="sys-devel/DPC++" + +DEPEND=" + dev-cpp/tbb:= + dev-libs/level-zero:= + virtual/opencl +" +RDEPEND="${DEPEND}" + +src_prepare() { + # DPC++ compiler required for full functionality + export CC="${ESYSROOT}/usr/lib/llvm/intel/bin/clang" + export CXX="${ESYSROOT}/usr/lib/llvm/intel/bin/clang++" + + cmake_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DDNNL_CPU_RUNTIME=DPCPP + -DDNNL_GPU_RUNTIME=DPCPP + -DDNNL_BUILD_TESTS="$(usex test)" + ) + cmake_src_configure +} + +src_compile() { + cmake_src_compile + docs_compile +} + +src_install() { + cmake_src_install + # Correct docdir + mv "${ED}/usr/share/doc/dnnl/"* "${ED}/usr/share/doc/${PF}" || die + rm -r "${ED}/usr/share/doc/dnnl" || die +} |