1 |
commit: e3629f5638ac3db3b78cba39c05250882fad2746 |
2 |
Author: Matthias Maier <tamiko <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Feb 28 01:09:35 2020 +0000 |
4 |
Commit: Matthias Maier <tamiko <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Feb 28 01:16:51 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e3629f56 |
7 |
|
8 |
games-board/stockfish: version bump to 11 |
9 |
|
10 |
Closes: https://bugs.gentoo.org/709784 |
11 |
Package-Manager: Portage-2.3.89, Repoman-2.3.20 |
12 |
Signed-off-by: Matthias Maier <tamiko <AT> gentoo.org> |
13 |
|
14 |
games-board/stockfish/Manifest | 1 + |
15 |
games-board/stockfish/stockfish-11.ebuild | 69 +++++++++++++++++++++++++++++++ |
16 |
2 files changed, 70 insertions(+) |
17 |
|
18 |
diff --git a/games-board/stockfish/Manifest b/games-board/stockfish/Manifest |
19 |
index ec4790075f0..b76b0028dbd 100644 |
20 |
--- a/games-board/stockfish/Manifest |
21 |
+++ b/games-board/stockfish/Manifest |
22 |
@@ -1 +1,2 @@ |
23 |
DIST stockfish-10-src.zip 174377 BLAKE2B 58142b16f59f15773c8811d6e10588dbc680c94cd504d26f4ca285dbe632d845ede06571e501a4e2b77adbb9b00d91978236ff179a46a73dc9a03cfa1ae3490c SHA512 959c4f3c497ba3108884dabc38de824f11781ae57b4ab5fdf25daf9a7fc0326e663adb1c081b8c8d57a7bf5f2e941369502a50a0c93135a001c6bd1af360d0f8 |
24 |
+DIST stockfish-11.zip 179371 BLAKE2B c58839e8c8f8b9424f93555316c9cddccc8dec8cc29dde52bfd73af0d6c727b3a94eea07db08ebc88b97986b814a3a53e22726cdece0fbdbb54a131cec591d64 SHA512 5291a8200172d37f5a94711aeeb65b11d7a9b9ccc366182c4c6a8b454dd4fad72bf19d1494fe091cb71502288f81ec3c7d0fa16b815af7fc76b2894cb26dc8f4 |
25 |
|
26 |
diff --git a/games-board/stockfish/stockfish-11.ebuild b/games-board/stockfish/stockfish-11.ebuild |
27 |
new file mode 100644 |
28 |
index 00000000000..c0198fa586c |
29 |
--- /dev/null |
30 |
+++ b/games-board/stockfish/stockfish-11.ebuild |
31 |
@@ -0,0 +1,69 @@ |
32 |
+# Copyright 1999-2020 Gentoo Authors |
33 |
+# Distributed under the terms of the GNU General Public License v2 |
34 |
+ |
35 |
+EAPI=7 |
36 |
+ |
37 |
+inherit toolchain-funcs |
38 |
+ |
39 |
+DESCRIPTION="Free UCI chess engine, claimed to be the strongest in the world" |
40 |
+HOMEPAGE="https://stockfishchess.org/" |
41 |
+ |
42 |
+SRC_URI="https://github.com/official-stockfish/Stockfish/archive/sf_${PV}.zip -> ${P}.zip" |
43 |
+LICENSE="GPL-3" |
44 |
+SLOT="0" |
45 |
+KEYWORDS="~amd64 ~x86" |
46 |
+IUSE="cpu_flags_arm_v7 cpu_flags_x86_avx2 cpu_flags_x86_popcnt cpu_flags_x86_sse debug |
47 |
+ general-32 general-64 +optimize" |
48 |
+ |
49 |
+DEPEND="|| ( app-arch/unzip app-arch/zip )" |
50 |
+RDEPEND="" |
51 |
+ |
52 |
+S="${WORKDIR}/Stockfish-sf_${PV}/src" |
53 |
+ |
54 |
+src_prepare() { |
55 |
+ default |
56 |
+ |
57 |
+ # prevent pre-stripping |
58 |
+ sed -e 's:-strip $(BINDIR)/$(EXE)::' -i Makefile \ |
59 |
+ || die 'failed to disable stripping in the Makefile' |
60 |
+} |
61 |
+ |
62 |
+src_compile() { |
63 |
+ local my_arch |
64 |
+ |
65 |
+ # generic unoptimized first |
66 |
+ use general-32 && my_arch=general-32 |
67 |
+ use general-64 && my_arch=general-64 |
68 |
+ |
69 |
+ # x86 |
70 |
+ use x86 && my_arch=x86-32-old |
71 |
+ use cpu_flags_x86_sse && my_arch=x86-32 |
72 |
+ |
73 |
+ # amd64 |
74 |
+ use amd64 && my_arch=x86-64 |
75 |
+ use cpu_flags_x86_popcnt && my_arch=x86-64-modern |
76 |
+ |
77 |
+ # both bmi2 and avx2 are part of hni (haswell new instructions) |
78 |
+ use cpu_flags_x86_avx2 && my_arch=x86-64-bmi2 |
79 |
+ |
80 |
+ # other architectures |
81 |
+ use cpu_flags_arm_v7 && my_arch=armv7 |
82 |
+ use ppc && my_arch=ppc |
83 |
+ use ppc64 && my_arch=ppc64 |
84 |
+ |
85 |
+ # Skip the "build" target and use "all" instead to avoid the config |
86 |
+ # sanity check (which would throw a fit about our compiler). There's |
87 |
+ # a nice hack in the Makefile that overrides the value of CXX with |
88 |
+ # COMPILER to support Travis CI and we abuse it to make sure that we |
89 |
+ # build with our compiler of choice. |
90 |
+ emake all ARCH="${my_arch}" \ |
91 |
+ COMP=$(tc-getCXX) \ |
92 |
+ COMPILER=$(tc-getCXX) \ |
93 |
+ debug=$(usex debug "yes" "no") \ |
94 |
+ optimize=$(usex optimize "yes" "no") |
95 |
+} |
96 |
+ |
97 |
+src_install() { |
98 |
+ dobin "${PN}" |
99 |
+ dodoc ../AUTHORS ../Readme.md |
100 |
+} |