app-emacs/zenburn: x86 stable wrt bug #695564
[gentoo.git] / games-rpg / hatoful-boyfriend / hatoful-boyfriend-0-r1.ebuild
1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=7
5
6 inherit desktop xdg-utils
7
8 MY_PN="Hatoful Boyfriend"
9 DESCRIPTION="Japanese visual novel and dating simulator where birds rule the Earth"
10 HOMEPAGE="https://www.devolverdigital.com/games/hatoful-boyfriend"
11 SRC_URI="${MY_PN// /_}_Linux.zip"
12 LICENSE="all-rights-reserved"
13 SLOT="0"
14 KEYWORDS="-* ~amd64 ~x86"
15 IUSE="+gui"
16 RESTRICT="bindist fetch splitdebug"
17
18 RDEPEND="
19         virtual/glu
20         virtual/opengl
21         x11-libs/libX11
22         x11-libs/libXcursor
23         x11-libs/libXext
24         x11-libs/libXrandr
25         gui? (
26                 dev-libs/atk
27                 dev-libs/glib:2
28                 media-libs/fontconfig:1.0
29                 media-libs/freetype:2
30                 x11-libs/cairo
31                 x11-libs/gdk-pixbuf:2
32                 x11-libs/gtk+:2
33                 x11-libs/pango
34         )
35 "
36
37 S="${WORKDIR}/${MY_PN}_Linux"
38
39 DIR="/opt/${PN}"
40 QA_PREBUILT="${DIR#/}/*"
41
42 pkg_nofetch() {
43         einfo "Please buy and download ${SRC_URI} from:"
44         einfo "  https://www.humblebundle.com/store/${PN}"
45         einfo "and move it to your distfiles directory."
46 }
47
48 src_install() {
49         exeinto "${DIR}"
50         newexe hatoful.$(usex amd64 x86_64 x86) hatoful
51         dosym "${DIR}"/hatoful /usr/bin/${PN}
52
53         insinto "${DIR}"
54         doins -r hatoful_Data/
55         rm -r "${ED}/${DIR}"/hatoful_Data/*/$(usex amd64 x86 x86_64) || die
56
57         if ! use gui; then
58                 rm "${ED}/${DIR}"/hatoful_Data/Plugins/*/ScreenSelector.so || die
59         fi
60
61         newicon -s 128 hatoful_Data/Resources/UnityPlayer.png ${PN}.png
62         make_desktop_entry ${PN} "${MY_PN}"
63 }
64
65 pkg_postinst() { xdg_icon_cache_update; }
66 pkg_postrm() { xdg_icon_cache_update; }