Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[gentoo-dev] RFC: qt4-r2.eclass - new eclass for Qt-based apps

0 views
Skip to first unread message

Dominik Kapusta

unread,
Nov 29, 2009, 6:50:02 AM11/29/09
to
Hello guys!

We, the Qt team, would like to include a new eclass in the tree.

The qt4-r2 eclass is meant to help with ebuilds for Qt-based (qmake-based, to
be precise) applications.

The eclass is attached, and here's a short comparison between qt4-r2 and qt4
(currently in tree) eclasses:

Removed in qt4-r2:
* obsolete QT4_BUILD_WITH_USE_CHECK and
QT4_OPTIONAL_BUILD_WITH_USE_CHECK hacks.

Improved in qt4-r2:
* eqmake4 function now behaves similarly to qmake itself, i.e.:
- doesn't assume ${PN}.pro, but searches for the project file if not
specified, just like qmake does
- in some cases is able to figure out the correct project file if there
are several of them in one directory (rare case, but technically
possible)

New in qt4-r2:
* automatic generation of "linguas_*" IUSE, based on LANGS and LANGSLONG
variables,
* automatic installation of documentation, based on DOCS and DOCSDIR
variables,
* exported src_configure(), src_compile() and src_install() functions

The qt4-r2 eclass requires EAPI-2.

We have been developing, testing and constantly improving qt4-r2 in qting-edge
overlay for around a year already. It's working for us and we find it very
handy compared to the old qt4.eclass.

After pushing qt4-r2 to the tree, we're going to port Qt 4 apps' ebuilds to
qt4-r2 and deprecate qt4.eclass.


Thanks,
Dominik

qt4-r2.eclass
signature.asc

Thomas Anderson

unread,
Nov 29, 2009, 9:00:02 AM11/29/09
to
On Sun, Nov 29, 2009 at 01:46:59PM +0200, Dominik Kapusta wrote:
> Hello guys!
>
> We, the Qt team, would like to include a new eclass in the tree.
>
> The qt4-r2 eclass is meant to help with ebuilds for Qt-based (qmake-based, to
> be precise) applications.
>

Haven't look at the content yet. But the name is going to make things extremely
confusing. I can see people using qt4-r2 just because it has -r2 (so it is newer
than qt4), even if they should use qt4. If you really need to introduce a new
eclass, you should use a name that accurately reflects what it does.

Cheers,
Thomas
--
---------
Thomas Anderson
Gentoo Developer
/////////
Areas of responsibility:
AMD64, Secretary to the Gentoo Council
---------

Dominik Kapusta

unread,
Nov 29, 2009, 9:40:02 AM11/29/09
to
On Sunday 29 November 2009 15:54:30 Thomas Anderson wrote:
> On Sun, Nov 29, 2009 at 01:46:59PM +0200, Dominik Kapusta wrote:
> > Hello guys!
> >
> > We, the Qt team, would like to include a new eclass in the tree.
> >
> > The qt4-r2 eclass is meant to help with ebuilds for Qt-based
> > (qmake-based, to be precise) applications.
>
> Haven't look at the content yet. But the name is going to make things
> extremely confusing. I can see people using qt4-r2 just because it has -r2
> (so it is newer than qt4), even if they should use qt4. If you really need
> to introduce a new eclass, you should use a name that accurately reflects
> what it does.
>
> Cheers,
> Thomas
>

The name is actually the simplest possible, and yes, our goal is to switch to
qt4-r2 in the end (which I mentioned at the end of my first mail). So in
general, once qt4-r2 is in, no one should use qt4.eclass.

We had several name options, e.g. qt4-tng but qt4-r2 seemed the most
straightforward. plus -r2 adds the Gentoo flavor, hence is better than e.g.
qt4-v2 :)

That said, we want qt4-r2 to be a new eclass for Qt-based ebuilds. And we
can't just make changes to qt4.eclass since there are too many ebuilds using
it and we would surely break the tree.

Cheers,
Dominik

signature.asc

Markos Chandras

unread,
Nov 29, 2009, 9:50:02 AM11/29/09
to
Scarabeus ( Tomas ) proposed this patch [1]. I think it is ok to apply it

[1]: http://dev.gentoo.org/~scarabeus/qt4-r2.eclass.patch
--
Markos Chandras (hwoarang)
Gentoo Linux Developer [KDE/Qt/Sound/Sunrise/Kernel/Bug-wrangler]
Web: http://hwoarang.silverarrow.org

signature.asc

Ben de Groot

unread,
Nov 29, 2009, 11:10:03 AM11/29/09
to
2009/11/29 Thomas Anderson <tand...@gentoo.org>:

> I can see people using qt4-r2 just because it has -r2 (so it is newer
> than qt4)

That is exactly the intended behaviour. We would break the tree if we would
simply add the new functionality to the existing qt4.eclass. And in absence
of an eclass versioning mechanism, this is what we came up with. As soon
as existing ebuilds in the tree are ported over to qt4-r2, the old
qt4.eclass will
be removed.

Cheers,
--
Ben de Groot
Gentoo Linux developer (qt, media, lxde, desktop-misc)
______________________________________________________

Ben de Groot

unread,
Nov 29, 2009, 6:30:02 PM11/29/09
to
2009/11/29 Dawid Węgliński <c...@gentoo.org>:

> On Sunday 29 November 2009 16:59:10 Ben de Groot wrote:
>> As soon as existing ebuilds in the tree are ported over to qt4-r2, the old
>> qt4.eclass will be removed.
>>
> As far as i remember we don't remove eclasses. Probably you meant deprecated,
> but not removed?

I hate leaving old cruft around, so I definitely meant removed. If
that is against policy,
can you refer me to a document that specifies said policy?

Dawid Węgliński

unread,
Nov 29, 2009, 6:40:01 PM11/29/09
to
On Monday 30 November 2009 00:19:49 Ben de Groot wrote:
> 2009/11/29 Dawid Węgliński <c...@gentoo.org>:
> > On Sunday 29 November 2009 16:59:10 Ben de Groot wrote:
> >> As soon as existing ebuilds in the tree are ported over to qt4-r2, the
> >> old qt4.eclass will be removed.
> >
> > As far as i remember we don't remove eclasses. Probably you meant
> > deprecated, but not removed?
>
> I hate leaving old cruft around, so I definitely meant removed. If
> that is against policy,
> can you refer me to a document that specifies said policy?
>
> Cheers,
>

Sorry, i was not up to date with this.

http://devmanual.gentoo.org/eclass-writing/index.html

--
Cheers
Dawid Węgliński

Tomáš Chvátal

unread,
Nov 29, 2009, 7:10:02 PM11/29/09
to
Dne neděle 29 Listopad 2009 23:11:23 Dawid Węgliński napsal(a):

> On Sunday 29 November 2009 16:59:10 Ben de Groot wrote:
> > As soon as existing ebuilds in the tree are ported over to qt4-r2, the
> > old qt4.eclass will
> > be removed.
>
> As far as i remember we don't remove eclasses. Probably you meant
> deprecated, but not removed?
>
New eclasses can be removed. But yeah for now it is deprecating.
signature.asc

Dominik Kapusta

unread,
Dec 3, 2009, 3:20:02 PM12/3/09
to

Hey,

I'm attaching:
* the eclass updated according to suggestion from scarabeus,
* the diff between the first revision and the current one.

Changes include:
* moving EAPI check to the global scope,
* moving documentation around,
* passing parameters to inner functions (inherited from base.eclass).

Please review this one, if there are no objections we'd like to introduce it
to the tree in about two weeks time starting from now.

Thanks a lot,
Dominik

qt4-r2.diff
qt4-r2.eclass
signature.asc
0 new messages