public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: games-board/lc0/
@ 2025-09-19 10:31 Patrick Lauer
  0 siblings, 0 replies; only message in thread
From: Patrick Lauer @ 2025-09-19 10:31 UTC (permalink / raw
  To: gentoo-commits

commit:     c25dd1d569233bcf3197f14a7959afbfe55c47fd
Author:     Patrick Lauer <patrick <AT> gentoo <DOT> org>
AuthorDate: Fri Sep 19 10:29:48 2025 +0000
Commit:     Patrick Lauer <patrick <AT> gentoo <DOT> org>
CommitDate: Fri Sep 19 10:31:37 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c25dd1d5

games-board/lc0: new package, add 0.31.2, 0.32.0

Signed-off-by: Patrick Lauer <patrick <AT> gentoo.org>

 games-board/lc0/Manifest          |  5 ++++
 games-board/lc0/lc0-0.31.2.ebuild | 49 +++++++++++++++++++++++++++++++++
 games-board/lc0/lc0-0.32.0.ebuild | 57 +++++++++++++++++++++++++++++++++++++++
 games-board/lc0/metadata.xml      | 16 +++++++++++
 4 files changed, 127 insertions(+)

diff --git a/games-board/lc0/Manifest b/games-board/lc0/Manifest
new file mode 100644
index 000000000000..695f7c028d14
--- /dev/null
+++ b/games-board/lc0/Manifest
@@ -0,0 +1,5 @@
+DIST lc0-0.31.2.tar.gz 692468 BLAKE2B 2ce23c4d960d8a8cc63e310fbea4b1191dff83bacab13393c7e16c22c18740aa8cb5637eb489d8d5d84aa6ddf52f28b20000c600a054b7d775ff5c967affe57f SHA512 eb5b63c1b57daa07fd68ea03fb7fb4ba55ac3c0562af2cd57953f43fb70e0bf4b67a1ec749ae9c066133c35bb47a0fe5635678baf24421fa160dc42ac7f6efa8
+DIST lc0-0.32.0-opencl.hpp 419645 BLAKE2B f90ba05216c36927e974a22bc65b186640940cf44b06da8e6201392e84e0470e9e980898037b2effe9c744c20d2e766ff8bf2f1f15a05f8d445ce21cd74385ba SHA512 5bdb531c095942f9f65aee647b0e04688b04fff80201db0f44ab16c83d2d493fc75cf61906f741c91e218706b45874f79ed0814eaa796663cbe8c7f81df6aaee
+DIST lc0-0.32.0.tar.gz 834904 BLAKE2B 41e4a7aca6e7733a3a0f1a84667525faf9790ef4276a15a3b3e5d38266a898ea168277e27de0df8a312fe46e8a54bca69a7a43cd7232166aa1deb2fd3f5bd11a SHA512 8c1785a21dd4deb9015644bc91cad9899666cb385f2f20a2465e65995966354bf5b8100f1d59195bedbb4f55c8960079629bf768178f51b44cdba95653b87255
+DIST lc0-common-0.31.2.tar.gz 4031 BLAKE2B 022e829de6a4534fc1f9c92944295c402057551178eb31d9623471d81a204c7ae7ffb464dcc00dbc4664348418503408750c05655904812f4e327ec6cc14c303 SHA512 45ea7c8e5fa8bacd158f6d3504da2e5f52c68c8ebe232c3eb40db36a5db4cf1f08d31f9cb063bda6748ae8cc12e418ac24f84a0ea63e8d04614cfbad1bdc37b6
+DIST lc0-common-0.32.0.tar.gz 4031 BLAKE2B 022e829de6a4534fc1f9c92944295c402057551178eb31d9623471d81a204c7ae7ffb464dcc00dbc4664348418503408750c05655904812f4e327ec6cc14c303 SHA512 45ea7c8e5fa8bacd158f6d3504da2e5f52c68c8ebe232c3eb40db36a5db4cf1f08d31f9cb063bda6748ae8cc12e418ac24f84a0ea63e8d04614cfbad1bdc37b6

diff --git a/games-board/lc0/lc0-0.31.2.ebuild b/games-board/lc0/lc0-0.31.2.ebuild
new file mode 100644
index 000000000000..1bcc092de12c
--- /dev/null
+++ b/games-board/lc0/lc0-0.31.2.ebuild
@@ -0,0 +1,49 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit meson
+
+DESCRIPTION="Neural-network chess engine"
+HOMEPAGE="https://github.com/LeelaChessZero/lc0/"
+SRC_URI="https://github.com/LeelaChessZero/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz
+	https://github.com/LeelaChessZero/lczero-common/archive/c47d3683972d9ef293b0c0bc7675f7c2c5ce2274.tar.gz -> ${PN}-common-${PV}.tar.gz"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="blas dnnl ispc onnx opencl test"
+
+RDEPEND="dev-cpp/eigen
+	dev-cpp/gtest
+	blas? ( sci-libs/openblas )
+	opencl? ( virtual/opencl )
+	ispc? ( dev-lang/ispc )
+	dnnl? ( sci-ml/oneDNN )
+	"
+DEPEND="${RDEPEND}"
+
+RESTRICT="!test? ( test )"
+
+src_prepare() {
+	cp -r "${WORKDIR}/lczero-common-c47d3683972d9ef293b0c0bc7675f7c2c5ce2274/proto" "${S}/libs/lczero-common/" || die
+	eapply_user
+	default
+}
+
+src_configure() {
+	local emesonargs=(
+		$(meson_use ispc ispc)
+		$(meson_use dnnl dnnl)
+		$(meson_use opencl opencl)
+		)
+	meson_src_configure
+}
+
+src_install() {
+	mkdir -p "${D}/usr/bin"
+	cp "${S}-build/lc0" "${D}/usr/bin" || die
+
+	default
+}

diff --git a/games-board/lc0/lc0-0.32.0.ebuild b/games-board/lc0/lc0-0.32.0.ebuild
new file mode 100644
index 000000000000..4fef9c4681b8
--- /dev/null
+++ b/games-board/lc0/lc0-0.32.0.ebuild
@@ -0,0 +1,57 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit meson
+
+DESCRIPTION="Neural-network chess engine"
+HOMEPAGE="https://github.com/LeelaChessZero/lc0/"
+SRC_URI="https://github.com/LeelaChessZero/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz
+	https://github.com/LeelaChessZero/lczero-common/archive/c47d3683972d9ef293b0c0bc7675f7c2c5ce2274.tar.gz -> ${PN}-common-${PV}.tar.gz
+	https://raw.githubusercontent.com/KhronosGroup/OpenCL-CLHPP/refs/tags/v2025.07.22/include/CL/opencl.hpp -> ${P}-opencl.hpp"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="blas dnnl ispc onnx opencl test"
+
+RDEPEND="dev-cpp/eigen
+	dev-cpp/gtest
+	blas? ( sci-libs/openblas )
+	ispc? ( dev-lang/ispc )
+	dnnl? ( sci-ml/oneDNN )
+	onnx? ( sci-libs/onnxruntime )
+	opencl? ( virtual/opencl )"
+
+DEPEND="${RDEPEND}"
+
+RESTRICT="!test? ( test )"
+
+src_prepare() {
+	cp -r "${WORKDIR}/lczero-common-c47d3683972d9ef293b0c0bc7675f7c2c5ce2274/proto" "${S}/libs/lczero-common/" || die
+	cp "${DISTDIR}/${P}-opencl.hpp" "third_party/opencl.hpp" || die
+	eapply_user
+
+	default
+}
+
+src_configure() {
+	local emesonargs=(
+		$(meson_use ispc ispc)
+		$(meson_use dnnl dnnl)
+		$(meson_use opencl opencl)
+		'-Donnx_libdir=/usr/lib64'
+		'-Donnx_include=/usr/include/onnxruntime'
+		'-Dcpp_args=-I/usr/include/eigen3'
+		'-Ddag_classic=false'
+		)
+	meson_src_configure
+}
+
+src_install() {
+	mkdir -p "${D}/usr/bin"
+	cp "${S}-build/lc0" "${D}/usr/bin" || die
+
+	default
+}

diff --git a/games-board/lc0/metadata.xml b/games-board/lc0/metadata.xml
new file mode 100644
index 000000000000..ccf7bfbd21f4
--- /dev/null
+++ b/games-board/lc0/metadata.xml
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+	<maintainer type="person">
+		<email>patrick@gentoo.org</email>
+		<name>Patrick Lauer</name>
+	</maintainer>
+	<use>
+		<flag name="dnnl">Enable dnnl / OneDNN backend</flag>
+		<flag name="ispc">Enable ispc backend</flag>
+		<flag name="onnx">Enable onnx backend</flag>
+	</use>
+	<upstream>
+		<remote-id type="github">LeelaChessZero/lc0</remote-id>
+	</upstream>
+</pkgmetadata>


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2025-09-19 10:32 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-19 10:31 [gentoo-commits] repo/gentoo:master commit in: games-board/lc0/ Patrick Lauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox