blob: 2783a034d990a093cd16f40dbdad981a09b5c8ec (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PYTHON_COMPAT=( python3_6 )
inherit eutils gnome2-utils python-r1
COMMIT="c5343cb3d828e8181ffff8249f683fce2fcca6db"
DESCRIPTION="Short-term-memory training N-Back game"
HOMEPAGE="https://github.com/samcv/brainworkshop"
SRC_URI="https://github.com/samcv/${PN}/archive/${COMMIT}.tar.gz -> ${P}.tar.gz"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~x86"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
RDEPEND="${PYTHON_DEPS}
|| ( >=dev-python/pyglet-1.1.4[${PYTHON_USEDEP},openal]
>=dev-python/pyglet-1.1.4[${PYTHON_USEDEP},alsa] )"
S="${WORKDIR}/${PN}-${COMMIT}"
PATCHES=(
"${FILESDIR}"/${PN}-${PV%_*}-fix-paths.patch
)
src_prepare() {
edos2unix ${PN}.pyw
default
sed -i \
"s#@GENTOO_DATADIR@#${EPREFIX}/usr/share/${PN}#g" \
${PN}.pyw || die
}
src_install() {
newbin ${PN}.pyw ${PN}
python_replicate_script "${ED}"usr/bin/${PN}
insinto /usr/share/${PN}
doins -r res/*
dodoc Readme.md Readme-{instructions,resources}.txt data/Readme-stats.txt
newicon -s 48 res/misc/brain/brain.png ${PN}.png
make_desktop_entry ${PN} "Brain Workshop"
}
pkg_preinst() { gnome2_icon_savelist; }
pkg_postinst() { gnome2_icon_cache_update; }
pkg_postrm() { gnome2_icon_cache_update; }
|