diff options
author | V3n3RiX <venerix@koprulu.sector> | 2024-12-24 06:30:58 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2024-12-24 06:30:58 +0000 |
commit | 17e417b73cb3e25edbc6541bd107bc9c593d66bd (patch) | |
tree | 866f98b73f846149d0c9e7e5a1cf0527b7c54e08 /games-board | |
parent | 338095605b6c9c82690f77f27a32490c9a57bdcb (diff) |
gentoo auto-resync : 24:12:2024 - 06:30:57
Diffstat (limited to 'games-board')
-rw-r--r-- | games-board/Manifest.gz | bin | 10052 -> 10048 bytes | |||
-rw-r--r-- | games-board/stockfish/Manifest | 2 | ||||
-rw-r--r-- | games-board/stockfish/files/stockfish-17-gcc15.patch | 40 | ||||
-rw-r--r-- | games-board/stockfish/stockfish-17-r1.ebuild | 99 |
4 files changed, 141 insertions, 0 deletions
diff --git a/games-board/Manifest.gz b/games-board/Manifest.gz Binary files differindex 722b95fedc54..2dc3d19c1081 100644 --- a/games-board/Manifest.gz +++ b/games-board/Manifest.gz diff --git a/games-board/stockfish/Manifest b/games-board/stockfish/Manifest index 5235d8156781..22c65a3d921a 100644 --- a/games-board/stockfish/Manifest +++ b/games-board/stockfish/Manifest @@ -1,3 +1,4 @@ +AUX stockfish-17-gcc15.patch 1391 BLAKE2B 5e3cc575d7209c0e54cd12d5d71041673069f374a6a46fad4f2f1b99b8e4f86eb47349fd699d660dff714c6371d46331f7eb8f4307dc5dc6d6973e53b6262ff2 SHA512 c4c9dccd6d10cdca5f5eabe96208bd5565f94b03c6afcec95665e3b31a47cdef776c01badb22fa7b7408bb948cc3887bb9671b4309e6bf2adefb4adfd9365db6 DIST stockfish-10-src.zip 174377 BLAKE2B 58142b16f59f15773c8811d6e10588dbc680c94cd504d26f4ca285dbe632d845ede06571e501a4e2b77adbb9b00d91978236ff179a46a73dc9a03cfa1ae3490c SHA512 959c4f3c497ba3108884dabc38de824f11781ae57b4ab5fdf25daf9a7fc0326e663adb1c081b8c8d57a7bf5f2e941369502a50a0c93135a001c6bd1af360d0f8 DIST stockfish-13-nn-62ef826d1a6d.nnue 21022697 BLAKE2B 013396fec72e14dfb90ca308bdcbaf98f27b29feb03cb2c855f521dc33d0787de51812cb2a52e4aa94622120fc89a5f2302fd6296a4fb1db33e0de57156a41c3 SHA512 25a0a1b5c440fcfaa8ee122391fbb075e4b4e6bdacae816a2897bb346c0d5c459ae464fc7680414e87eadf2a5a00565d4f3ac2c559fea4bdddd1e4a38874fba7 DIST stockfish-13.tar.gz 181226 BLAKE2B ab6f2afccce2b4767c69d07c18aa611cb71388aae9b27e8a6c95b61db4a27c18b0e7a21aa30e10b4b56d018c1a4146dcea4896c4d68d7a9f297fa0758739ce9c SHA512 5ee6581b8324ed32f02ed0f1ea5df311635203e5f1806d00f9819ad076ef4082481f8ecebbb531154cbb120bb2b396c738c3ef2e2e6ee0fd6a5bd6ff88192706 @@ -26,5 +27,6 @@ EBUILD stockfish-15.1.ebuild 2045 BLAKE2B 3f74063bf4037fbe63e9d8be80e11865f3fdd5 EBUILD stockfish-16-r1.ebuild 2637 BLAKE2B 46fff5df168a923d4ded0e2bba036afb64942cd0d4e1661945d53be9b5b779588529476f729ed39745c05478e14d6b4c83ea27a3105e5f990ca83e1e1a48769c SHA512 55d569079fca0e0d8aae9d321d37bf49eaf0cc8860970e906e11fcdb9626fabe9ad2ff585c3146bf734ac8c4baf4fbc6cb2e85ff294dea427d9c9c8c4a7252fe EBUILD stockfish-16.1.ebuild 2704 BLAKE2B ddbbcbb171cfdc0ee397dea1207e5be3e7d54d59db02040da05a6f37061b847eb44d65500e11f2cdd5e8a5e15e431f9617d61c33263d58ddea146cd91ec326af SHA512 c73e2f585fbd668f067cf325ebc98b8546738c0953e4982a3b9db37bf40f7377126efd2a1661f0ba910ee60347d7050ad9660b6618b5c115f599b6066c425e12 EBUILD stockfish-16.ebuild 2380 BLAKE2B 4752a92066f6938691947e329a03b7ab82aa7432fc79cc9899f5aef6b476a419c529dc60eb541c1a54c94b84a85f6729e82445875cc5e32ca33f1169f3f3c2ee SHA512 92e33d7910cd7d232f11425524f56c7dd21265f80a262660cda8fcb080d434bb00fa7b4aeac82761b93b3865cffb9d5d02fbf65786c0da295ec2e69f8cac86bd +EBUILD stockfish-17-r1.ebuild 2756 BLAKE2B 6ec991fd5964fe2bb428bd495d37f9834e40866fdb798fceab72ddc722c42713437529477ffeb10d3b3df2dfc3554bd6c7f03475eda72d6570258e458e24a8fc SHA512 efd74f776b030a5f7456058c25e996d361827e5cdf2455a3204c154aafd3d39b0e7329138f6a61cc245388bc98991e71c8cc56f24bc132ddd92a7a56ea3ccfb9 EBUILD stockfish-17.ebuild 2702 BLAKE2B 3d5c32dd6d525e41d498a90c90dfcf5fe3b48a08a737a635565cbe32d236694dd6bd3ffbd19abaff163e707a78b4a4ef6a170271a5e6e4540bf1cd837824c1f6 SHA512 8059e7b4bc89e53821f30666d6509ce89c1d0ecd0c913b929de259b6d8017ef79192dcad747013d3d00bba88d8077b78fb27b8c3565d6a2ce685bafc13969022 MISC metadata.xml 573 BLAKE2B 2b1f870ab3bad4a90940374e974a37ec52239b6684e78e5dd41b95a1503854c06a3a5185b48c56c542a4195d00293cc6628c362d93a835997e41122215bf8540 SHA512 a21725ea89118c85924985d95614e8702209b3184848f63271910dafa3d1f4e6238fb015558e287cc341262bb65bbafc33606042eb589c7499a92088c2a43574 diff --git a/games-board/stockfish/files/stockfish-17-gcc15.patch b/games-board/stockfish/files/stockfish-17-gcc15.patch new file mode 100644 index 000000000000..c92918335ada --- /dev/null +++ b/games-board/stockfish/files/stockfish-17-gcc15.patch @@ -0,0 +1,40 @@ +https://bugs.gentoo.org/940504 +https://github.com/official-stockfish/Stockfish/issues/5714 +https://github.com/official-stockfish/Stockfish/commit/1776448917e49b922a762d2d08c00a3f3be10205 + +From 1776448917e49b922a762d2d08c00a3f3be10205 Mon Sep 17 00:00:00 2001 +From: Disservin <disservin.social@gmail.com> +Date: Fri, 13 Dec 2024 17:00:05 +0100 +Subject: [PATCH] Move Embedded Net Data out of Anon Namespace + +fixes https://github.com/official-stockfish/Stockfish/issues/5714 + +closes https://github.com/official-stockfish/Stockfish/pull/5715 + +No functional change +--- + src/nnue/network.cpp | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/src/nnue/network.cpp b/src/nnue/network.cpp +index 0a4452f6604..01cf2516d4a 100644 +--- a/nnue/network.cpp ++++ b/nnue/network.cpp +@@ -38,7 +38,6 @@ + #include "nnue_common.h" + #include "nnue_misc.h" + +-namespace { + // Macro to embed the default efficiently updatable neural network (NNUE) file + // data in the engine binary (using incbin.h, by Dale Weiler). + // This macro invocation will declare the following three variables +@@ -58,6 +57,8 @@ const unsigned char* const gEmbeddedNNUESmallEnd = &gEmbeddedNNUESmallData[1 + const unsigned int gEmbeddedNNUESmallSize = 1; + #endif + ++namespace { ++ + struct EmbeddedNNUE { + EmbeddedNNUE(const unsigned char* embeddedData, + const unsigned char* embeddedEnd, + diff --git a/games-board/stockfish/stockfish-17-r1.ebuild b/games-board/stockfish/stockfish-17-r1.ebuild new file mode 100644 index 000000000000..8f2125616f25 --- /dev/null +++ b/games-board/stockfish/stockfish-17-r1.ebuild @@ -0,0 +1,99 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit toolchain-funcs + +NNUE_FILES="nn-1111cefa1111.nnue nn-37f18f62d772.nnue" +DESCRIPTION="Free UCI chess engine, claimed to be the strongest in the world" +HOMEPAGE="https://stockfishchess.org/" +SRC_URI="https://github.com/official-stockfish/Stockfish/archive/sf_${PV}.tar.gz -> ${P}.tar.gz" +for i in ${NNUE_FILES}; do + SRC_URI+=" https://tests.stockfishchess.org/api/nn/${i} -> ${P}-${i}" +done +S="${WORKDIR}/Stockfish-sf_${PV}/src" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~loong ~riscv ~x86" +IUSE="cpu_flags_arm_v7 cpu_flags_x86_avx2 cpu_flags_x86_popcnt cpu_flags_x86_sse cpu_flags_x86_avx512f" +IUSE+=" cpu_flags_x86_avx512dq debug general-32 general-64 +optimize" + +BDEPEND="|| ( app-arch/unzip app-arch/zip )" + +PATCHES=( + "${FILESDIR}"/${P}-gcc15.patch +) + +pkg_setup() { + if ! tc-is-clang && ! tc-is-gcc; then + die "Unsupported compiler: $(tc-getCC)" + fi +} + +src_prepare() { + default + + # remove config sanity check that doesn't like our COMPILER settings + sed -i -e 's/ config-sanity//g' Makefile || die + + for i in $NNUE_FILES; do + cp "${DISTDIR}"/${P}-${i} ${i} || die "copying the nnue file failed" + done + + # prevent pre-stripping + sed -e 's:-strip $(BINDIR)/$(EXE)::' -i Makefile \ + || die 'failed to disable stripping in the Makefile' + + # Makefile is a bit optimistic + sed -e 's:-flto=full:-flto:g' -i Makefile || die +} + +src_compile() { + local my_arch + + # generic unoptimized first + use general-32 && my_arch=general-32 + use general-64 && my_arch=general-64 + + # x86 + use x86 && my_arch=x86-32-old + use cpu_flags_x86_sse && my_arch=x86-32 + + # amd64 + use amd64 && my_arch=x86-64 + use cpu_flags_x86_popcnt && my_arch=x86-64-modern + + # both bmi2 and avx2 are part of hni (haswell new instructions) + use cpu_flags_x86_avx2 && my_arch=x86-64-bmi2 + + # avx512 + # we currently can't express 'avx512vnni' 'avx512dq' 'avx512f' 'avx512bw' 'avx512vl' + # so only enable basic support + use cpu_flags_x86_avx512f && use cpu_flags_x86_avx512dq && my_arch=x86-64-avx512 + + # other architectures + use cpu_flags_arm_v7 && my_arch=armv7 + use ppc && my_arch=ppc + use ppc64 && my_arch=ppc64 + + # Bug 919781: COMP is a fixed string like clang/gcc to set tools for PGO + local comp + tc-is-gcc && comp="gcc" + tc-is-clang && comp="clang" + + # There's a nice hack in the Makefile that overrides the value of CXX with + # COMPILER to support Travis CI and we abuse it to make sure that we + # build with our compiler of choice. + emake profile-build ARCH="${my_arch}" \ + COMP="${comp}" \ + COMPILER="$(tc-getCXX)" \ + debug=$(usex debug "yes" "no") \ + optimize=$(usex optimize "yes" "no") +} + +src_install() { + dobin "${PN}" + dodoc ../AUTHORS ../README.md +} |