Gentoo Archives: gentoo-commits

From: Ionen Wolkens <ionen@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-im/discord-bin/
Date: Tue, 19 Oct 2021 00:55:34
Message-Id: 1634604375.71922357de1ff64aec7d79f489c2335d12ff5856.ionen@gentoo
1 commit: 71922357de1ff64aec7d79f489c2335d12ff5856
2 Author: Hayley Hughes <hayley <AT> foxes <DOT> systems>
3 AuthorDate: Tue Oct 12 01:57:56 2021 +0000
4 Commit: Ionen Wolkens <ionen <AT> gentoo <DOT> org>
5 CommitDate: Tue Oct 19 00:46:15 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=71922357
7
8 net-im/discord-bin: EAPI8, various fixes
9
10 - Fix deps to match NEEDED libraries (bug #814440)
11 - Make appindicator an optfeature (bug #743808)
12 - Add sound optfeature (bug #722668)
13 - Add missing EPREFIX to sed
14 - Replace Exec in desktop file to just discord (respects EPREFIX)
15 - Removed unnecessary inclusion of xdg
16 - General cleanup
17
18 Bug: https://bugs.gentoo.org/722668
19 Closes: https://bugs.gentoo.org/743808
20 Closes: https://bugs.gentoo.org/814440
21 Package-Manager: Portage-3.0.20, Repoman-3.0.3
22 Signed-off-by: Hayley Hughes <hayley <AT> foxes.systems>
23 Closes: https://github.com/gentoo/gentoo/pull/22583
24 Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>
25
26 net-im/discord-bin/discord-bin-0.0.16-r1.ebuild | 88 +++++++++++++++++++++++++
27 1 file changed, 88 insertions(+)
28
29 diff --git a/net-im/discord-bin/discord-bin-0.0.16-r1.ebuild b/net-im/discord-bin/discord-bin-0.0.16-r1.ebuild
30 new file mode 100644
31 index 00000000000..36552f2d121
32 --- /dev/null
33 +++ b/net-im/discord-bin/discord-bin-0.0.16-r1.ebuild
34 @@ -0,0 +1,88 @@
35 +# Copyright 1999-2021 Gentoo Authors
36 +# Distributed under the terms of the GNU General Public License v2
37 +
38 +EAPI=8
39 +
40 +MY_PN="${PN%-bin}"
41 +MY_BIN="${MY_PN^}"
42 +
43 +inherit desktop linux-info optfeature pax-utils unpacker
44 +
45 +DESCRIPTION="All-in-one voice and text chat for gamers"
46 +HOMEPAGE="https://discordapp.com"
47 +SRC_URI="https://dl.discordapp.net/apps/linux/${PV}/${MY_PN}-${PV}.deb"
48 +S="${WORKDIR}"
49 +
50 +LICENSE="all-rights-reserved"
51 +SLOT="0"
52 +KEYWORDS="~amd64"
53 +RESTRICT="mirror bindist"
54 +
55 +RDEPEND="
56 + app-accessibility/at-spi2-atk:2
57 + app-accessibility/at-spi2-core:2
58 + dev-libs/atk
59 + dev-libs/expat
60 + dev-libs/glib:2
61 + dev-libs/nspr
62 + dev-libs/nss
63 + media-libs/alsa-lib
64 + media-libs/mesa
65 + net-print/cups
66 + sys-apps/dbus
67 + x11-libs/cairo
68 + x11-libs/gdk-pixbuf:2
69 + x11-libs/gtk+:3
70 + x11-libs/libX11
71 + x11-libs/libXcomposite
72 + x11-libs/libXdamage
73 + x11-libs/libXext
74 + x11-libs/libXfixes
75 + x11-libs/libXrandr
76 + x11-libs/libdrm
77 + x11-libs/libxcb
78 + x11-libs/libxkbcommon
79 + x11-libs/libxshmfence
80 + x11-libs/pango
81 +"
82 +
83 +QA_PREBUILT="
84 + opt/discord/${MY_BIN}
85 + opt/discord/chrome-sandbox
86 + opt/discord/libffmpeg.so
87 + opt/discord/libvk_swiftshader.so
88 + opt/discord/libvulkan.so
89 + opt/discord/libEGL.so
90 + opt/discord/libGLESv2.so
91 + opt/discord/libVkICD_mock_icd.so
92 + opt/discord/swiftshader/libEGL.so
93 + opt/discord/swiftshader/libGLESv2.so
94 + opt/discord/swiftshader/libvk_swiftshader.so
95 +"
96 +
97 +CONFIG_CHECK="~USER_NS"
98 +
99 +src_prepare() {
100 + default
101 +
102 + sed -i \
103 + -e "s:/usr/share/discord/Discord:discord:" \
104 + usr/share/${MY_PN}/${MY_PN}.desktop || die
105 +}
106 +
107 +src_install() {
108 + doicon usr/share/${MY_PN}/${MY_PN}.png
109 + domenu usr/share/${MY_PN}/${MY_PN}.desktop
110 +
111 + insinto /opt/${MY_PN}
112 + doins -r usr/share/${MY_PN}/.
113 + fperms +x /opt/${MY_PN}/${MY_BIN}
114 + dosym -r /opt/${MY_PN}/${MY_BIN} /usr/bin/${MY_PN}
115 +
116 + pax-mark -m "${ED}"/opt/${MY_PN}/${MY_PN}
117 +}
118 +
119 +pkg_postinst() {
120 + optfeature "sound support" media-sound/pulseaudio media-video/pipewire
121 + optfeature "system tray support" dev-libs/libappindicator
122 +}