Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 432848 - gnome-extra/gnome-games uses games.eclass incorrectly
Summary: gnome-extra/gnome-games uses games.eclass incorrectly
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords:
Depends on: 351375
Blocks: 463766
  Show dependency tree
 
Reported: 2012-08-26 12:39 UTC by Julian Ospald
Modified: 2013-07-26 18:42 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
gnome-games.eclass (gnome-games.eclass,2.90 KB, text/plain)
2013-05-02 15:32 UTC, Pacho Ramos
Details
five-or-more-3.8.1.ebuild (five-or-more-3.8.1.ebuild,485 bytes, text/plain)
2013-05-12 10:16 UTC, Pacho Ramos
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Julian Ospald 2012-08-26 12:39:02 UTC
games.eclass has a few policies on how to use it. games.eclass is not inherited last here, games variables such as install destinations are not respected, games_pkg_preinst is ignored which can be used in conjunction with GAMES_STATEDIR (the ebuild currently uses /var/lib/games) and prepgamesdirs is missing.

I suggest to go for review in #gentoo-games.
Comment 1 Alexandre Rostovtsev (RETIRED) gentoo-dev 2012-08-26 16:11:23 UTC
The whole /var/lig/games highscore setup for gnome-games is broken to be honest...
Comment 2 Gilles Dartiguelongue (RETIRED) gentoo-dev 2012-08-29 15:23:12 UTC
inheriting the eclass last does not guarantee its functions will be called by ebuild per PMS iirc.

We will review the ebuild to add any phase function that might be missing currently.
Comment 3 Julian Ospald 2012-08-29 22:08:48 UTC
(In reply to comment #2)
> inheriting the eclass last does not guarantee its functions will be called
> by ebuild per PMS iirc.

I am fully aware of that.

inheriting it last is just a precaution afais in case other inherited eclasses change their behavior and start to overwrite undefined phases via exports like pkg_setup or pkg_preinst

that's _currently_ not the case here anyway since almost all phases are defined, however it can happen on version bump and such

but you gnome guys could argue from the same perspective I guess...

the most important things are respected games variables for binaries/libs and games-data stuff and "prepgamesdirs" call for the permissions
Comment 4 Pacho Ramos gentoo-dev 2013-04-24 18:54:14 UTC
This needs to be reviewed before starting to add all ebuilds for splitted gnome-games... not sure if we could have a gnome-games.eclass handling this need of games/gnome eclasses coexistence :|
Comment 5 Pacho Ramos gentoo-dev 2013-04-27 06:50:20 UTC
(In reply to comment #4)
> This needs to be reviewed before starting to add all ebuilds for splitted
> gnome-games... not sure if we could have a gnome-games.eclass handling this
> need of games/gnome eclasses coexistence :|

Phases that would need to be used:
- pkg_setup -> from games.eclass
- src_configure -> we need settings from egamesconf... but would also be nice to pass some options from gnome2_src_configure... not sure what to do :| I would probably have a gnome-games_src_configure that would run gnome2_src_configure + prefix settings copied from egamesconf
- src_compile -> from gnome2.eclass
- pkg_{pre,post}inst -> from both eclasses


Regarding highscores file... I have no idea about what to do :| In OpenSuSE and Fedora I cannot see any change related with highscores files
Comment 6 Pacho Ramos gentoo-dev 2013-05-02 15:31:39 UTC
For now, this one is sent to upstream:
https://bugzilla.gnome.org/show_bug.cgi?id=699482

But I still don't think gtk-doc and glib schemas should be installed on a different prefix :/
Comment 7 Pacho Ramos gentoo-dev 2013-05-02 15:32:01 UTC
Created attachment 347146 [details]
gnome-games.eclass

Last eclass attempt
Comment 8 Pacho Ramos gentoo-dev 2013-05-04 11:54:34 UTC
Reported this one because locales and /var/ are installed in wrong directories :S, if anyone has any idea about what is failing, please speak!
Comment 9 Pacho Ramos gentoo-dev 2013-05-04 11:54:42 UTC
https://bugzilla.gnome.org/show_bug.cgi?id=699482
Comment 10 Pacho Ramos gentoo-dev 2013-05-12 10:16:00 UTC
Created attachment 348058 [details]
five-or-more-3.8.1.ebuild

ebuild to test
Comment 11 Pacho Ramos gentoo-dev 2013-05-12 13:20:53 UTC
Maybe intltool is the problem:
https://bugs.launchpad.net/intltool/+bug/1030541
Comment 12 Pacho Ramos gentoo-dev 2013-05-12 13:48:17 UTC
(In reply to comment #11)
> Maybe intltool is the problem:
> https://bugs.launchpad.net/intltool/+bug/1030541

We have various options:
- Patch our intltool package and regenerate Makefile.in.in files (probably via eclass)
- Keep our intltool as upstream (broken) and fix offending line in Makefile.in.in via eclass.

Anyway, if upstream don't care, all generated tarballs will keep bogus if we don't regenerate files always with our patched intltool

Any thoughts?
Comment 13 Pacho Ramos gentoo-dev 2013-05-12 13:48:51 UTC
CCing intltool maintainers then per previous comment
Comment 14 Pacho Ramos gentoo-dev 2013-05-12 13:54:45 UTC
scoredir='${localstatedir}/games' in configure.ac is the cause of /var/games/games... probably we will need to not set --localstatedir to GAMES_STATEDIR
Comment 15 Pacho Ramos gentoo-dev 2013-05-26 07:26:50 UTC
+*intltool-0.50.2-r1 (26 May 2013)
+
+  26 May 2013; Pacho Ramos <pacho@gentoo.org>
+  +files/intltool-0.50.2-absolute-paths.patch,
+  +files/intltool-0.50.2-localedir-fix.patch, +intltool-0.50.2-r1.ebuild:
+  Use plain localedir to install mo files to rather than trying to guess one
+  (#432848#c11), fix handling absolute paths in single file key output
+  (#470040).
+
Comment 16 Pacho Ramos gentoo-dev 2013-05-26 07:30:22 UTC
(In reply to Pacho Ramos from comment #12)
> Anyway, if upstream don't care, all generated tarballs will keep bogus if we
> don't regenerate files always with our patched intltool
> 
> Any thoughts?

We can now DEPEND on fixed version, the problem is that, strictly, all current tarballs are bogus because were generated with broken upstream version. How should we fix them? 
intltoolize --copy --automake --force

works but, where should we call it? On each broken ebuild (all)? at gnome-games.eclass? gnome2.eclass? (in that case, how can we easily add a check for calling it only when wrong Makefile.in.in is detected?)
Comment 17 Pacho Ramos gentoo-dev 2013-06-02 19:01:43 UTC
(In reply to Pacho Ramos from comment #16)
> (In reply to Pacho Ramos from comment #12)
> > Anyway, if upstream don't care, all generated tarballs will keep bogus if we
> > don't regenerate files always with our patched intltool
> > 
> > Any thoughts?
> 
> We can now DEPEND on fixed version, the problem is that, strictly, all
> current tarballs are bogus because were generated with broken upstream
> version. How should we fix them? 
> intltoolize --copy --automake --force
> 
> works but, where should we call it? On each broken ebuild (all)? at
> gnome-games.eclass? gnome2.eclass? (in that case, how can we easily add a
> check for calling it only when wrong Makefile.in.in is detected?)

I would go for calling "intltoolize --copy --automake --force" always if "has_version dev-util/intltool" (to not add a DEPEND on intltool for all packages using gnome2.eclass) and if "${S}/po/Makefile.in.in" exists (otherwise, intltoolize is not needed and would fail).

The advantage of running it always is that we "unbundle" Makefile.in.in file and are sure we use a file that we can easily control and fix. In this case, for example, we could simply stabilize fixed intltool version and add a blockers for older versions in DEPEND in gnome2.eclass
Comment 18 Pacho Ramos gentoo-dev 2013-07-26 18:42:05 UTC
this is solved in 3.8