Gentoo Archives: gentoo-proxy-maint

From: Joonas Niilola <juippis@g.o>
To: gentoo-proxy-maint@l.g.o
Subject: Re: [gentoo-proxy-maint] [PATCH 1/2] games-arcade/oshu: Version bump, 2.0.1
Date: Mon, 30 Mar 2020 06:43:52
Message-Id: a5cf43e5-8600-93c5-c386-9785862b42ca@gentoo.org
In Reply to: [gentoo-proxy-maint] [PATCH 1/2] games-arcade/oshu: Version bump, 2.0.1 by "Haelwenn (lanodan) Monnier"
1 On 3/30/20 5:30 AM, Haelwenn (lanodan) Monnier wrote:
2 > Signed-off-by: Haelwenn (lanodan) Monnier <contact@×××××××××.me>
3 > ---
4 > games-arcade/oshu/Manifest | 1 +
5 > games-arcade/oshu/oshu-2.0.1.ebuild | 65 +++++++++++++++++++++++++++++
6 > 2 files changed, 66 insertions(+)
7 > create mode 100644 games-arcade/oshu/oshu-2.0.1.ebuild
8 >
9 > diff --git a/games-arcade/oshu/Manifest b/games-arcade/oshu/Manifest
10 > index ef952619335..58793eeb050 100644
11 > --- a/games-arcade/oshu/Manifest
12 > +++ b/games-arcade/oshu/Manifest
13 > @@ -1,2 +1,3 @@
14 > DIST oshu-2.0.0.tar.gz 144088 BLAKE2B c4383746624f4de62e158a2f94d4e5c1a3e2f037fd05d80607932414f20a031103bd73f108644a93faadf61c21f3d2505da3afd2ea7ea43bd59e32966724928b SHA512 ed2b8294b06d239948c563135d997b422191be681ff86714a244ca64079251508a5a62e23cf3ae1e0ac2b3128b6401901233714eab7787989296ca1700192643
15 > +DIST oshu-2.0.1.tar.gz 144900 BLAKE2B 47f1d0a11255459ae357142499aeffcf07fbcad961cb34ba98e9efa7cb4229cf8d61ec836a4c899f2ea0883f1252395bc0c6ff34c5d670d67091cf6483d135ff SHA512 65768b3d8e7733464f05a19bbee594c0be728267bbd0667bc0f34e0d01a39e52d4ecce89a9223f7c454d73b21bc735401e9d83eea8b0a2eaf1c7825a3bd6b1cf
16 > DIST oshu-skin-v1.tar.gz 2224947 BLAKE2B 0b463133dd7ab54421551627d12932f5257848b1130d57af8c2ff6b6836a49c9322b8f2f7e95de540909390d0139e547650a6bb321614cf92fac464b09075674 SHA512 d562294ac5e122a9d9971e3ab92f6168d848177cc5e22a94bbc450fde2b3b14007796a24d33722da9b6675467b109ce128ba94dca5dcc7c61c91c1e373032618
17 > diff --git a/games-arcade/oshu/oshu-2.0.1.ebuild b/games-arcade/oshu/oshu-2.0.1.ebuild
18 > new file mode 100644
19 > index 00000000000..b46284d4604
20 > --- /dev/null
21 > +++ b/games-arcade/oshu/oshu-2.0.1.ebuild
22 > @@ -0,0 +1,65 @@
23 > +# Copyright 1999-2020 Gentoo Authors
24 > +# Distributed under the terms of the GNU General Public License v2
25 > +
26 > +EAPI=7
27 > +
28 > +CMAKE_MIN_VERSION="3.9.0"
29 > +
30 > +inherit cmake-utils
31
32 Try to use cmake.eclass, cmake-utils is being deprecated for this kind
33 of use.
34
35 Remember to update functions below.
36
37
38 > +
39 > +DESCRIPTION="Lightweight osu! port"
40 > +HOMEPAGE="https://github.com/fmang/oshu"
41 > +
42 > +if [[ $PV = *9999 ]]; then
43 > + inherit git-r3
44 > + EGIT_REPO_URI="https://github.com/fmang/oshu.git"
45 > + SRC_URI="osu-skin? ( https://www.mg0.fr/oshu/skins/osu-v1.tar.gz -> ${PN}-skin-v1.tar.gz )"
46 > +else
47 > + SRC_URI="https://github.com/fmang/oshu/archive/${PV}.tar.gz -> oshu-${PV}.tar.gz
48 > + osu-skin? ( https://www.mg0.fr/oshu/skins/osu-v1.tar.gz -> ${PN}-skin-v1.tar.gz )"
49 > + KEYWORDS="~amd64 ~x86"
50 > +fi
51 > +
52 > +LICENSE="GPL-3 CC-BY-NC-4.0"
53 > +SLOT="0"
54 > +IUSE="osu-skin"
55 > +
56 > +RDEPEND="
57 > + >=media-libs/libsdl2-2.0.5:=
58 > + media-libs/sdl2-image:=
59 > + x11-libs/cairo:=
60 > + x11-libs/pango:=
61 > + media-video/ffmpeg:=
62 > +"
63
64 Only ffmpeg from has subslots, so := on the other ones are redundant.
65
66
67 > +
68 > +DEPEND="${RDEPEND}"
69 > +
70 > +RESTRICT="test"
71
72 Why? Add a comment and preferably a bug number / upstream issue on top
73 to explain the restriction.
74
75
76 > +
77 > +src_prepare() {
78 > + if use osu-skin; then
79 > + eapply "${FILESDIR}/oshu-2.0.0-use_unpacked_osu-skin.patch"
80 > + mv "${WORKDIR}/osu" share/skins/
81
82 || die
83
84
85 > + fi
86 > +
87 > + cmake-utils_src_prepare
88 > +}
89 > +
90 > +src_configure() {
91 > + local mycmakeargs=(
92 > + '-DOSHU_DEFAULT_SKIN='$(usex osu-skin 'osu' 'minimal')
93 > + '-DOSHU_SKINS=minimal'$(usex osu-skin ';osu' '')
94 > + )
95 > +
96 > + cmake-utils_src_configure
97 > +}
98 > +
99 > +pkg_postinst() {
100 > + xdg_desktop_database_update
101 > + xdg_mimeinfo_database_update
102 > +}
103 > +
104 > +pkg_postrm() {
105 > + xdg_desktop_database_update
106 > + xdg_mimeinfo_database_update
107 > +}
108
109 No xdg* eclass is inherited. I'm aware cmake.utils inherits it, but you
110 should imply the eclasses whose functions you use, so if the situation
111 with cmake.eclass changes in future this won't break. You can also use
112 xdg.eclass and you don't have to define pkg_{postinst,postrm} in this
113 ebuild at all.

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies

Subject Author
[gentoo-proxy-maint] [PATCH v2 1/3] games-arcade/oshu: Version bump, 2.0.1 "Haelwenn (lanodan) Monnier" <contact@×××××××××.me>
[gentoo-proxy-maint] [PATCH v2 2/3] games-arcade/oshu: Version clean, 2.0.0 "Haelwenn (lanodan) Monnier" <contact@×××××××××.me>
[gentoo-proxy-maint] [PATCH v2 3/3] games-arcade/oshu: Add live ebuild "Haelwenn (lanodan) Monnier" <contact@×××××××××.me>