summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Sturmlechner <asturm@gentoo.org>2021-01-08 17:12:24 +0100
committerAndreas Sturmlechner <asturm@gentoo.org>2021-01-08 20:19:06 +0100
commitdce14a783c92e42f5ee4f459049e9cf65c9287f7 (patch)
tree0193197229eeea386b0b17f07d0910e43730a110 /dev-games
parentapp-emulation/docker-cli: 20.10.2 qa-requested changes (diff)
downloadgentoo-dce14a783c92e42f5ee4f459049e9cf65c9287f7.tar.gz
gentoo-dce14a783c92e42f5ee4f459049e9cf65c9287f7.tar.bz2
gentoo-dce14a783c92e42f5ee4f459049e9cf65c9287f7.zip
dev-games/freecell-solver: Properly depend on dev-libs/rinutils
Package-Manager: Portage-3.0.12, Repoman-3.0.2 Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
Diffstat (limited to 'dev-games')
-rw-r--r--dev-games/freecell-solver/files/freecell-solver-6.2.0-no-git-clone-kthxbye.patch20
-rw-r--r--dev-games/freecell-solver/freecell-solver-6.2.0-r1.ebuild57
2 files changed, 77 insertions, 0 deletions
diff --git a/dev-games/freecell-solver/files/freecell-solver-6.2.0-no-git-clone-kthxbye.patch b/dev-games/freecell-solver/files/freecell-solver-6.2.0-no-git-clone-kthxbye.patch
new file mode 100644
index 000000000000..17675d22ab0a
--- /dev/null
+++ b/dev-games/freecell-solver/files/freecell-solver-6.2.0-no-git-clone-kthxbye.patch
@@ -0,0 +1,20 @@
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -210,7 +210,7 @@
+ # Clone the patsolve repository with the appropriate branch.
+ SET (pats_dir "patsolve")
+
+-IF (NOT EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/${pats_dir}")
++IF (0)
+ EXECUTE_PROCESS(
+ COMMAND "git" "clone" "https://github.com/shlomif/patsolve.git" "${pats_dir}"
+ WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}"
+@@ -219,7 +219,7 @@
+
+ # Clone the rinutils repository with the appropriate tag.
+ SET (rinutils_dir "rinutils")
+-IF (NOT EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/${rinutils_dir}")
++IF (0)
+ EXECUTE_PROCESS(
+ COMMAND "git" "clone" "-b" "0.6.0" "https://github.com/shlomif/rinutils.git" "${rinutils_dir}"
+ WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}"
diff --git a/dev-games/freecell-solver/freecell-solver-6.2.0-r1.ebuild b/dev-games/freecell-solver/freecell-solver-6.2.0-r1.ebuild
new file mode 100644
index 000000000000..c74ccd6cfb05
--- /dev/null
+++ b/dev-games/freecell-solver/freecell-solver-6.2.0-r1.ebuild
@@ -0,0 +1,57 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{6,7,8,9} )
+inherit cmake python-single-r1
+
+DESCRIPTION="C library for automatically solving Freecell and some other solitaire variants"
+HOMEPAGE="https://fc-solve.shlomifish.org/"
+SRC_URI="https://fc-solve.shlomifish.org/downloads/fc-solve/${P}.tar.xz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="amd64 arm64 x86"
+IUSE="tcmalloc"
+
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+RDEPEND="${PYTHON_DEPS}
+ dev-libs/rinutils
+ $(python_gen_cond_dep '
+ dev-python/pysol_cards[${PYTHON_MULTI_USEDEP}]
+ dev-python/random2[${PYTHON_MULTI_USEDEP}]
+ dev-python/six[${PYTHON_MULTI_USEDEP}]
+ ')
+ tcmalloc? ( dev-util/google-perftools )
+"
+DEPEND="${RDEPEND}
+ dev-perl/Moo
+ dev-perl/Path-Tiny
+ dev-perl/Template-Toolkit
+"
+
+DOCS=( README.html )
+
+PATCHES=(
+ "${FILESDIR}/${PN}-5.22.1-no-docs.patch"
+ "${FILESDIR}/${P}-no-git-clone-kthxbye.patch"
+)
+
+src_prepare() {
+ cmake_src_prepare
+ python_fix_shebang board_gen
+ rm -r rinutils || die
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DBUILD_STATIC_LIBRARY=OFF
+ -DFCS_BUILD_DOCS=OFF
+ -DFCS_WITH_TEST_SUITE=OFF # requires unpackaged dependencies
+ -DFCS_AVOID_TCMALLOC=$(usex !tcmalloc)
+ )
+
+ cmake_src_configure
+}