Gentoo Archives: gentoo-dev

From: NP-Hardass <NP-Hardass@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] [RFC] New eclass: mate
Date: Tue, 12 Apr 2016 00:15:19
Message-Id: 570C3DF8.3070704@gentoo.org
In Reply to: [gentoo-dev] [RFC] New eclass: mate by NP-Hardass
1 -----BEGIN PGP SIGNED MESSAGE-----
2 Hash: SHA256
3
4 On 04/11/2016 01:09 AM, NP-Hardass wrote:
5 > Greetings all,
6 >
7 > As all potential new eclasses are supposed to be discussed here, I
8 > thought I'd file a message and see if anyone had anything to
9 > contribute on the matter.
10 >
11 > I'm in the midst of a major version bump for the entirety of the
12 > MATE desktop environment, consisting of 40-50 packages. There is a
13 > huge amount of repetition in my ebuilds, and a lot of things are
14 > formulaic (SRC_URI, HOMEPAGE, EGIT_REPO_URI, inherits, src_prepare,
15 > etc). As such, I think that moving all of that to an eclass would
16 > greatly simplify my life and my ebuilds, so I thought I'd look into
17 > creating an eclass.
18 >
19 > Any opinions either way? Thanks in advance.
20 >
21 >
22 >
23
24 A little background, MATE is a fork of GNOME, so there are many things
25 in common, however, the two aren't always in sync. As such, there is
26 often code reuse, but not always. For example, GNOME has deprecated
27 GNOME_DEBUG macros whereas MATE has not done so yet.
28
29 Attached are two eclasses mate-desktop.org.eclass and mate.eclass.
30
31 mate-desktop.org.eclass mimics the gnome.org eclass. It defines a
32 couple of useful variables, as well as sets SRC_URI or EGIT_REPO_URI
33 for a live ebuild.
34
35 mate.eclass is supposed to parallel gnome2.eclass. A couple of notes:
36 mate-desktop.org.eclass is necessary to override all of the defaults
37 in gnome.org.eclass which are not applicable to MATE. The src_prepare
38 function is borrowed from autotools-utils. With EAPI 6, if any user
39 is capable of modifying the build system via eapply_user, I'd like to
40 be able to detect and regenerate the build system accordingly.
41 Additionally, upstream does not supply Makefiles or configure scripts
42 for live ebuilds, so I always have to run eautoreconf in those cases.
43 Stubs: Well, you will probably notice that I have stubs to the gnome2
44 remaining functions. This was done for several reasons. 1) in the
45 event that the gnome2 eclass goes in a different direction than MATE,
46 it's easy to switch our own implementation, and 2) if I don't and I
47 have reference to the gnome2 eclass, I have to explicitly inherit it
48 in all ebuilds, which somewhat defeats the point the indirection
49 gained by having the mate eclass. I'd have to inherit gnome2 mate
50 mate-desktop.org in every ebuild to ensure that everything is
51 inherited properly. It's a little bit messy, but still doable. But
52 for the previous reason, built in independence from the gnome eclass
53 if needed, it seems much easier to me to stub out gnome2 in the meantime
54 .
55
56 - --
57 NP-Hardass
58 -----BEGIN PGP SIGNATURE-----
59 Version: GnuPG v2
60
61 iQIcBAEBCAAGBQJXDD34AAoJEBzZQR2yrxj7ELkQAJK78s2tNt67XR7fgIYWZkTa
62 a52MsFdW5e14yqKZAmKZqIde3zRo65BAoa15BVscM2o9iH1CtJolbrq0i603OBej
63 RGt5RkgOqmUYg8lU/z1fyX7PLzm3ukTBSNQ0Y5m5jofo2sbg4WMFiaaQkmvChnQd
64 TA5dI+nMzz8gfQJvXoorj+JZziOikH4i8lsge2QKP7IUDe16fjUO8VM8J+5v4uk+
65 XXeIPFq3PXoHeGW9jLo9jibapntDlPOStoalY5dRIkIZSpe124TfVhCSOMeuWtRB
66 VzvvaW+D2MFL9NU2WcsQtU8H71CY/bZl3qPiA9n6OcFowIyVXBP9W7lhpcBmWbYx
67 HIsI8UEXriuMJPhiZ/mzkEKaXohElcvbolvQigejGCxzJVQ1fxpoHINXaN/KCEQ8
68 fxsKeLCM/toPuFcqjru1znZb05cLm1UAcN15YK3ldrcJNGY9tPxHj09dt74eIWor
69 49HZeFSftef637vFA+3NEN9aVVRyd9O9Fc+wK8FI7ki3O2br4SoOw122NUfjFWoB
70 4xguWOJjspcbxobzK7nzrKhTYLDhh+oymTj4TLmmzvTo3zgBgYhbVJNP5HoycfPB
71 nZBzYZIht0bl/BbdGvdOyDVacLG+X7QlWKcx/bUmcrv3rih59D8XrtzlVhOavvhW
72 RZ4Wo+feNwXrLN9aOfcL
73 =GGgO
74 -----END PGP SIGNATURE-----

Attachments

File name MIME type
mate.eclass text/plain
mate-desktop.org.eclass text/plain
mate.eclass.sig application/pgp-signature
mate-desktop.org.eclass.sig application/pgp-signature

Replies

Subject Author
Re: [gentoo-dev] [RFC] New eclass: mate NP-Hardass <NP-Hardass@g.o>
Re: [gentoo-dev] [RFC] New eclass: mate Pacho Ramos <pacho@g.o>