summaryrefslogtreecommitdiff
path: root/games-board/pysolfc
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /games-board/pysolfc
reinit the tree, so we can have metadata
Diffstat (limited to 'games-board/pysolfc')
-rw-r--r--games-board/pysolfc/Manifest10
-rw-r--r--games-board/pysolfc/files/pysolfc-2.0-gentoo.patch10
-rw-r--r--games-board/pysolfc/files/pysolfc-PIL-imports.patch49
-rw-r--r--games-board/pysolfc/files/pysolfc-gentoo.patch10
-rw-r--r--games-board/pysolfc/metadata.xml15
-rw-r--r--games-board/pysolfc/pysolfc-2.0-r3.ebuild91
-rw-r--r--games-board/pysolfc/pysolfc-2.0-r5.ebuild64
7 files changed, 249 insertions, 0 deletions
diff --git a/games-board/pysolfc/Manifest b/games-board/pysolfc/Manifest
new file mode 100644
index 000000000000..15c4e652993a
--- /dev/null
+++ b/games-board/pysolfc/Manifest
@@ -0,0 +1,10 @@
+AUX pysolfc-2.0-gentoo.patch 312 SHA256 826c8f448f77a4fb8a18d83775914f439c66d382c2cd2e61fe8ec18bac161feb SHA512 55cd38419a2828c92b47deac61bbd3bd44f729f73496bb35ccbb55afad1956167de92f4588871d6303a8f39a8c2270bb5ae06272dea49978583c931e7650a545 WHIRLPOOL e157b2d9f7fe9d8abf06a98d8deefdd1a20d71ab25bf51e299cdf9f858dfea2945fdf35c1f1034a4f241475b3442c66e7f6379cbe3cf9446db319008234eccd6
+AUX pysolfc-PIL-imports.patch 1581 SHA256 21e2b7fbc905c53d3e6dfe884540df6e25a802a96eb73974bb906c2fbddf4406 SHA512 d00fb7b579e4010210131f9fe82ed90cb7ad5d39a391529d8d5c29c5f19b813afc429b1d5b8ae8af0eaf3a8082cf4a48723ce21b42522d9b9c8163a46a033aa9 WHIRLPOOL 30a1a4fa47236f3ebf1f90533ce99bd3d01347efa6b24d7d65728825e44f821e41a2129810404d60a8e4f45ff502d30ae90733c53ddbb8c73a78457618714144
+AUX pysolfc-gentoo.patch 322 SHA256 975a6e2c775dcb80f80ea79201a7acad5a1bc087f33fd85d3e509f75aeed0218 SHA512 963daef445d492a693380466fcfdc7f464947269d8a2b687039f31179c1f4fe5119efd71f83708073373c3ac5174a754075367937f99253d6b443e74e60e93d3 WHIRLPOOL 1c3d42c1001d9c79caa669e6f8085e6b5f8d1a4075335fa1719d4adaf5fe78fa99013bead83f07bf25cde6a883126fba0b76f6741a464e66793db178d88dfda4
+DIST PySolFC-2.0.tar.bz2 4208776 SHA256 dbcb8e7e6d0479c230745a2be91c0c9b9e8524407cd2075f2dae144e5d441b6c SHA512 ec5a11565bd43e097cf1854fe246b8f92acd74077c0b3b158c999f9dc45966e8f805c60a2cfbd815137d970e0e6409d0ae437b9807bac9c39353657cf596b6fc WHIRLPOOL 468d595ee1ae0a3a0129f9e822f9985cd0c7c9a00766dc711a5b8d202742bdd26393a676bc7515e39e1ddad71a3ef65d3d27ada0ec339212662126a42a07ad8c
+DIST PySolFC-Cardsets-2.0.tar.bz2 30687905 SHA256 c388d6360191b3b7e463d84e5a64260c4e3ed36e791a85227d7e8923f3f47ca7 SHA512 24275cd3656024e268a49487ac75e1e67e61ec20e0a9f88e2d1c287f91314a1a9343856d1202ce468f8863f4e9a9bf27526fbb1979a7d765718b38e64ca0cfc8 WHIRLPOOL ae779f1838d321e727c0661980c7f40ff368aa958a3fd1043448229d5b2a56ce94799f343b8527666081b043a469760f7f3b0a3e2d58263d69c16cb3456d7df5
+EBUILD pysolfc-2.0-r3.ebuild 1879 SHA256 faf310f0f388e203501d00f8f6b5dabadc65d68712aff71d166149503b736d8b SHA512 9fc5da897055f1a24a5727f81555d74ac2ca888441fbdc39d7b12eafaa446ffcf569032afb4bc7f134c1facff353f23f2a03018aa65e92d4e531e9da71951a25 WHIRLPOOL ffeef078a55b31078c561b8f9aeb9c613c1ff2ee608e23ebc1c5581b22b0ae672930a27c81eaf9c66490206051effae380606d894bc303c5ed78da37011736b5
+EBUILD pysolfc-2.0-r5.ebuild 1447 SHA256 945571e4d773b85df191af2c193ad97c363bae5269eddc41a73b06b6a921651f SHA512 05f48c1db7ea2a2ab19bf30a9cac66289d95af96586d75d481e369391a83f809bd3d008aa9729c1800bbb51a829599b5d6de6d7be543b2c1ed1305a7d7cfd6b5 WHIRLPOOL 9d9c2632c33dcc6a67edf68914bdd8f900a9e220dc65bbe6b8400940e053faffc32f8cb0b5f41a6ec04bf3c78f5afaf56b7eada959947c671d1a62c8a769f331
+MISC ChangeLog 3494 SHA256 3df978638f2e5d0e955c2ae8f399f5a107b7e19efc919ee87be9ee09206721dd SHA512 a7c144e3581a01d92a99e69f9b98f95e12a54f98e7b2a995d6eb4ceb9761cc2c9138deabc2baf973cd6afeba5070d1f0387b5e860d4c9724e4e9da2d0cd9b647 WHIRLPOOL 6019d76e3a059fbbda701445fb68954659458a3490299c669d2d4c9aa11d19f0dff1852f0cff573c879aad90525a78f5fb64ceec73920a97b4f2510fb8cdf036
+MISC ChangeLog-2015 3128 SHA256 d67e29779ea1753d9c58ec091625a0d72ad4113e96797cca889bbec933f1b559 SHA512 45027de960d48edff86716743f8ff7c409f9416f8bddfb91fe6d67ae1ca9a950f34fc9ee8cd0015093cf22c62bf770990a3c1f0ac0d0e05d961a68b4badcfe92 WHIRLPOOL 5c567bad4c35f17a40b9b9a77d0e955128482814dc7ca7e82696cb96ff73a1033d2632e5f1413f7d1af6a5850078b07fdf2ec9977172c3fc98792e82cac9d3ad
+MISC metadata.xml 505 SHA256 b85b886b6f909cf9f48b3c4e599785715f8b469320261074826915bcdbe13659 SHA512 e7bb917b63c06fd17dd5e863e354ae147bd5aa7ef3f360ec848b3ea20087a092d8b7450cfd7ce1a615a6414d6d618f32b60f299cb5a50f0e852205c3fcf4d136 WHIRLPOOL 807c218033eada3c2ed71828fcd95900a2510c2b70d9fe7f2d2e79e0a7e6d1f0477b75249f570273b4485d31234857e98ee5d16da5dfabf7ed0af57b47b1b162
diff --git a/games-board/pysolfc/files/pysolfc-2.0-gentoo.patch b/games-board/pysolfc/files/pysolfc-2.0-gentoo.patch
new file mode 100644
index 000000000000..3af96d9c0c2f
--- /dev/null
+++ b/games-board/pysolfc/files/pysolfc-2.0-gentoo.patch
@@ -0,0 +1,10 @@
+--- pysollib/settings.py.old 2014-04-07 20:05:02.335276008 +0200
++++ pysollib/settings.py 2014-04-07 20:05:33.099062670 +0200
+@@ -63,6 +63,7 @@
+ '/usr/local/share/PySolFC',
+ '/usr/games/PySolFC',
+ '/usr/local/games/PySolFC',
++ '@GAMES_DATADIR@',
+ ]
+ if os.name == 'nt':
+ pass
diff --git a/games-board/pysolfc/files/pysolfc-PIL-imports.patch b/games-board/pysolfc/files/pysolfc-PIL-imports.patch
new file mode 100644
index 000000000000..64d9980a881b
--- /dev/null
+++ b/games-board/pysolfc/files/pysolfc-PIL-imports.patch
@@ -0,0 +1,49 @@
+https://sourceforge.net/p/pysolfc/patches/10/
+https://bugs.gentoo.org/show_bug.cgi?id=471514
+
+Index: pysollib/mfxutil.py
+===================================================================
+diff --git a/pysollib/mfxutil.py b/pysollib/mfxutil.py
+--- a/pysollib/mfxutil.py (revision 279)
++++ b/pysollib/mfxutil.py (working copy)
+@@ -41,18 +41,18 @@
+ Image = ImageTk = ImageOps = None
+ if TOOLKIT == 'tk':
+ try: # PIL
+- import Image
+- import ImageTk
+- import ImageOps
++ from PIL import Image
++ from PIL import ImageTk
++ from PIL import ImageOps
+ except ImportError:
+ Image = None
+ else:
+ # for py2exe
+- import GifImagePlugin
+- import PngImagePlugin
+- import JpegImagePlugin
+- import BmpImagePlugin
+- import PpmImagePlugin
++ from PIL import GifImagePlugin
++ from PIL import PngImagePlugin
++ from PIL import JpegImagePlugin
++ from PIL import BmpImagePlugin
++ from PIL import PpmImagePlugin
+ Image._initialized = 2
+ USE_PIL = False
+ if TOOLKIT == 'tk' and Image and Image.VERSION >= '1.1.7':
+Index: scripts/cardset_viewer.py
+===================================================================
+diff --git a/scripts/cardset_viewer.py b/scripts/cardset_viewer.py
+--- a/scripts/cardset_viewer.py (revision 279)
++++ b/scripts/cardset_viewer.py (working copy)
+@@ -7,7 +7,7 @@
+ from math import sqrt, sin, cos, pi
+ from Tkinter import *
+ try:
+- import Image, ImageTk
++ from PIL import Image, ImageTk
+ except ImportError:
+ Image = None
+
diff --git a/games-board/pysolfc/files/pysolfc-gentoo.patch b/games-board/pysolfc/files/pysolfc-gentoo.patch
new file mode 100644
index 000000000000..07a7b662f320
--- /dev/null
+++ b/games-board/pysolfc/files/pysolfc-gentoo.patch
@@ -0,0 +1,10 @@
+--- a/pysollib/settings.py 2014-04-07 20:05:02.335276008 +0200
++++ b/pysollib/settings.py 2014-04-07 20:05:33.099062670 +0200
+@@ -63,6 +63,7 @@
+ '/usr/local/share/PySolFC',
+ '/usr/games/PySolFC',
+ '/usr/local/games/PySolFC',
++ '/usr/share/pysolfc',
+ ]
+ if os.name == 'nt':
+ pass
diff --git a/games-board/pysolfc/metadata.xml b/games-board/pysolfc/metadata.xml
new file mode 100644
index 000000000000..7cc738da552f
--- /dev/null
+++ b/games-board/pysolfc/metadata.xml
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>games@gentoo.org</email>
+ <name>Gentoo Games Project</name>
+ </maintainer>
+ <use>
+ <flag name="extra-cardsets">Install extra cardsets</flag>
+ <flag name="sound">Enable sound support using <pkg>dev-python/pygame</pkg></flag>
+ </use>
+ <upstream>
+ <remote-id type="sourceforge">pysolfc</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/games-board/pysolfc/pysolfc-2.0-r3.ebuild b/games-board/pysolfc/pysolfc-2.0-r3.ebuild
new file mode 100644
index 000000000000..a69e85aef5fb
--- /dev/null
+++ b/games-board/pysolfc/pysolfc-2.0-r3.ebuild
@@ -0,0 +1,91 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="tk"
+DISTUTILS_SINGLE_IMPL="1"
+
+inherit eutils python-single-r1 distutils-r1 games
+
+MY_PN=PySolFC
+SOL_URI="mirror://sourceforge/${PN}"
+
+DESCRIPTION="An exciting collection of more than 1000 solitaire card games"
+HOMEPAGE="http://pysolfc.sourceforge.net/"
+SRC_URI="${SOL_URI}/${MY_PN}-${PV}.tar.bz2
+ extra-cardsets? ( ${SOL_URI}/${MY_PN}-Cardsets-${PV}.tar.bz2 )"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="amd64 x86"
+IUSE="extra-cardsets minimal +sound"
+
+S=${WORKDIR}/${MY_PN}-${PV}
+
+DEPEND=""
+RDEPEND="${RDEPEND}
+ sound? ( dev-python/pygame[${PYTHON_USEDEP}] )
+ !minimal? ( dev-python/pillow[tk,${PYTHON_USEDEP}]
+ dev-tcltk/tktable )"
+
+python_prepare_all() {
+ local PATCHES=(
+ "${FILESDIR}/${PN}-PIL-imports.patch" #471514
+ "${FILESDIR}"/${P}-gentoo.patch
+ )
+
+ distutils-r1_python_prepare_all
+}
+
+pkg_setup() {
+ games_pkg_setup
+ python-single-r1_pkg_setup
+}
+
+src_prepare() {
+ distutils-r1_src_prepare
+
+ sed -i \
+ -e "/pysol.desktop/d" \
+ -e "s:share/icons:share/pixmaps:" \
+ -e "s:data_dir =.*:data_dir = \'${GAMES_DATADIR}/${PN}\':" \
+ setup.py || die
+
+ sed -i \
+ -e "s:@GAMES_DATADIR@:${GAMES_DATADIR}/${PN}:" \
+ pysollib/settings.py || die "fixing settings"
+
+ mv docs/README{,.txt}
+}
+
+src_compile() {
+ distutils-r1_src_compile
+}
+
+python_install_all() {
+ make_desktop_entry pysol.py "PySol Fan Club Edition" pysol02
+
+ if use extra-cardsets; then
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r "${WORKDIR}"/${MY_PN}-Cardsets-${PV}/*
+ fi
+
+ doman docs/*.6
+
+ DOCS=( README AUTHORS docs/README.txt docs/README.SOURCE )
+ HTML_DOCS=( docs/*html )
+
+ distutils-r1_python_install_all
+
+ dodir "${GAMES_BINDIR}"
+
+ mv "${D}"/usr/bin/pysol.py "${D}""${GAMES_BINDIR}"/
+
+ prepgamesdirs
+}
+
+src_install() {
+ distutils-r1_src_install
+}
diff --git a/games-board/pysolfc/pysolfc-2.0-r5.ebuild b/games-board/pysolfc/pysolfc-2.0-r5.ebuild
new file mode 100644
index 000000000000..b98ccfee931b
--- /dev/null
+++ b/games-board/pysolfc/pysolfc-2.0-r5.ebuild
@@ -0,0 +1,64 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE="tk"
+DISTUTILS_SINGLE_IMPL="1"
+
+inherit eutils distutils-r1
+
+MY_PN=PySolFC
+SOL_URI="mirror://sourceforge/${PN}"
+
+DESCRIPTION="An exciting collection of more than 1000 solitaire card games"
+HOMEPAGE="http://pysolfc.sourceforge.net/"
+SRC_URI="${SOL_URI}/${MY_PN}-${PV}.tar.bz2
+ extra-cardsets? ( ${SOL_URI}/${MY_PN}-Cardsets-${PV}.tar.bz2 )"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="extra-cardsets minimal +sound"
+
+S=${WORKDIR}/${MY_PN}-${PV}
+
+DEPEND=""
+RDEPEND="${RDEPEND}
+ !minimal? ( dev-python/pillow[tk,${PYTHON_USEDEP}]
+ dev-tcltk/tktable )
+ sound? ( dev-python/pygame[${PYTHON_USEDEP}] )"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-PIL-imports.patch" #471514
+ "${FILESDIR}/${PN}-gentoo.patch" #591904
+)
+
+python_prepare_all() {
+ sed -i \
+ -e "/pysol.desktop/d" \
+ -e "s:share/icons:share/pixmaps:" \
+ -e "s:data_dir =.*:data_dir = \'/usr/share/${PN}\':" \
+ setup.py || die
+
+ mv docs/README{,.txt} || die
+
+ distutils-r1_python_prepare_all
+}
+
+python_install_all() {
+ make_desktop_entry pysol.py "PySol Fan Club Edition" pysol02
+
+ if use extra-cardsets; then
+ insinto /usr/share/${PN}
+ doins -r "${WORKDIR}"/${MY_PN}-Cardsets-${PV}/*
+ fi
+
+ doman docs/*.6
+
+ DOCS=( README AUTHORS docs/README.txt docs/README.SOURCE )
+ HTML_DOCS=( docs/*html )
+
+ distutils-r1_python_install_all
+}