FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Gentoo > Gentoo Development

 
 
LinkBack Thread Tools
 
Old 05-23-2008, 10:01 PM
"Arun Raghavan"
 
Default Eclass for gnome-python* split

Greetings All,
I've been working on an ancient bug [1] requesting a split of the
gnome-python, gnome-python-extras, and gnome-python-desktop ebuilds.
The motivation behind the split is that packages that depend on a
single module or a small set of modules from one of these packages end
up pulling in the numerous dependencies required when pulling all the
modules in the package (example -- nautilus gets pulled in because of
a dep on the gnomeprint module).

I have split these 3 packages into packages for the component modules.
Since there was a lot of common functionality between these packages,
and the 28 modules' ebuilds were basically very similar, I've split
out a large amount of the required functionality into an eclass. The
work is heavily based on Jim Ramsay's (lack@g.o) work on splitting
gnome-python-desktop.

The split ebuilds are available via a git repository [2]. The actual
eclass can be viewed online at:

http://tinyurl.com/6z2ltc (full URL [3])

Feedback and comments (and even brickbats ) on the eclass are invited.

[1] https://bugs.gentoo.org/show_bug.cgi?id=108479
[2] http://gitorious.org/projects/g-py-split/repos/mainline (branch is
g-py-split)
[3] http://gitorious.org/projects/g-py-split/repos/mainline/blobs/g-py-split/eclass/gnome-python-common.eclass

Cheers!
--
Arun Raghavan
(http://nemesis.accosted.net)
v2sw5Chw4+5ln4pr6$OFck2ma4+9u8w3+1!m?l7+9GSCKi056
e6+9i4b8/9HTAen4+5g4/8APa2Xs8r1/2p5-8 hackerkey.com
--
gentoo-dev@lists.gentoo.org mailing list
 
Old 05-24-2008, 07:18 AM
Ali Polatel
 
Default Eclass for gnome-python* split

Arun Raghavan yazmış:
> Greetings All,

Hey there

> I've been working on an ancient bug [1] requesting a split of the
> gnome-python, gnome-python-extras, and gnome-python-desktop ebuilds.

Good for you :P

*snip*
>
> Feedback and comments (and even brickbats ) on the eclass are invited.
>

Attached is a patch for two minor issues with the eclass. First try to
remove py-compile only if it exists. Second, python_mod_optimize is
ROOT aware (since recently).

> Cheers!
> --
> Arun Raghavan
> (http://nemesis.accosted.net)
> v2sw5Chw4+5ln4pr6$OFck2ma4+9u8w3+1!m?l7+9GSCKi056
> e6+9i4b8/9HTAen4+5g4/8APa2Xs8r1/2p5-8 hackerkey.com

--
Regards,
Ali Polatel
diff --git a/eclass/gnome-python-common.eclass b/eclass/gnome-python-common.eclass
index f938f98..9169496 100644
--- a/eclass/gnome-python-common.eclass
+++ b/eclass/gnome-python-common.eclass
@@ -85,8 +85,10 @@ gnome-python-common_src_unpack() {
done

# disable pyc compiling
- rm py-compile
- ln -s $(type -P true) py-compile
+ if [[ -f py-compile ]]; then
+ rm py-compile
+ ln -s $(type -P true) py-compile
+ fi

[[ ${do_eautoreconf} -eq 1 ]] && eautoreconf
}
@@ -121,7 +123,7 @@ gnome-python-common_src_install() {

gnome-python-common_pkg_postinst() {
python_version
- python_mod_optimize "${ROOT}/usr/$(get_libdir)/python${PYVER}/site-packages/gtk-2.0"
+ python_mod_optimize /usr/$(get_libdir)/python${PYVER}/site-packages/gtk-2.0
}

gnome-python-common_pkg_postrm() {
 
Old 05-24-2008, 09:15 AM
"Arun Raghavan"
 
Default Eclass for gnome-python* split

Hello!

2008/5/24 Ali Polatel <hawking@gentoo.org>:
> Attached is a patch for two minor issues with the eclass. First try to
> remove py-compile only if it exists. Second, python_mod_optimize is
> ROOT aware (since recently).

Thanks for the feedback ... I've checked in your patch.

Best,
--
Arun Raghavan
(http://nemesis.accosted.net)
v2sw5Chw4+5ln4pr6$OFck2ma4+9u8w3+1!m?l7+9GSCKi056
e6+9i4b8/9HTAen4+5g4/8APa2Xs8r1/2p5-8 hackerkey.com
--
gentoo-dev@lists.gentoo.org mailing list
 
Old 05-24-2008, 03:32 PM
Christian Faulhammer
 
Default Eclass for gnome-python* split

"Arun Raghavan" <arunisgod@gmail.com>:

> Feedback and comments (and even brickbats ) on the eclass are
> invited.

* Don't install the COPYING file via the DOCS variable.
* The LICENSE should be kept per ebuild in my opinion

--
Christian Faulhammer, Gentoo Lisp project
<URL:http://www.gentoo.org/proj/en/lisp/>, #gentoo-lisp on FreeNode

<URL:http://www.faulhammer.org/>
 
Old 05-24-2008, 08:56 PM
"Arun Raghavan"
 
Default Eclass for gnome-python* split

On Sat, May 24, 2008 at 9:02 PM, Christian Faulhammer <opfer@gentoo.org> wrote:
> "Arun Raghavan" <arunisgod@gmail.com>:
>
>> Feedback and comments (and even brickbats ) on the eclass are
>> invited.
>
> * Don't install the COPYING file via the DOCS variable.
> * The LICENSE should be kept per ebuild in my opinion

Changes made and committed -- thanks!

There was one interesting observation while I was looking at the
license for the gtkspell module. gtkspell-2 is licensed GPL-2, but
gtkspell-3 (which is not yet released and has only recently picked up
a little steam upstream) is licensed LGPL-2.1. Based on this
gtkspell-python needs to be conditionally licensed based on which
version of gtkspell it is linked against (GPL-2 if against gtkspell-2,
LGPL-2.1 if against gtkspell-3).

Something like:

if has_version =dev-python/gtkspell-2*; then
LICENSE="GPL-2"
else
LICENSE="LGPL-2.1"
fi

There is currently *no* way to express this in an ebuild without
invalidating the cache. For now this is just a theoretical problem,
but worthy of consideration nonetheless.

Cheers!
--
Arun Raghavan
(http://nemesis.accosted.net)
v2sw5Chw4+5ln4pr6$OFck2ma4+9u8w3+1!m?l7+9GSCKi056
e6+9i4b8/9HTAen4+5g4/8APa2Xs8r1/2p5-8 hackerkey.com
--
gentoo-dev@lists.gentoo.org mailing list
 
Old 05-25-2008, 10:16 PM
Mart Raudsepp
 
Default Eclass for gnome-python* split

On L, 2008-05-24 at 10:18 +0300, Ali Polatel wrote:
> Arun Raghavan yazmış:
> > Greetings All,
>
> Hey there
>
> > I've been working on an ancient bug [1] requesting a split of the
> > gnome-python, gnome-python-extras, and gnome-python-desktop ebuilds.
>
> Good for you :P
>
> *snip*
> >
> > Feedback and comments (and even brickbats ) on the eclass are invited.
> >
>
> Attached is a patch for two minor issues with the eclass. First try to
> remove py-compile only if it exists. Second, python_mod_optimize is
> ROOT aware (since recently).

Does that mean that every python_mod_optimize user (ebuild) that used it
as was expected from python_mod_optimize is now broken for ROOT != "/"
by installing them into ${ROOT}/${ROOT}/ ?


--
Mart Raudsepp
Gentoo Developer
Mail: leio@gentoo.org
Weblog: http://planet.gentoo.org/developers/leio
 
Old 05-25-2008, 10:33 PM
Ali Polatel
 
Default Eclass for gnome-python* split

Mart Raudsepp yazmış:
> On L, 2008-05-24 at 10:18 +0300, Ali Polatel wrote:
> > Arun Raghavan yazmış:
> > > Greetings All,
> >
> > Hey there
> >
> > > I've been working on an ancient bug [1] requesting a split of the
> > > gnome-python, gnome-python-extras, and gnome-python-desktop ebuilds.
> >
> > Good for you :P
> >
> > *snip*
> > >
> > > Feedback and comments (and even brickbats ) on the eclass are invited.
> > >
> >
> > Attached is a patch for two minor issues with the eclass. First try to
> > remove py-compile only if it exists. Second, python_mod_optimize is
> > ROOT aware (since recently).
>
> Does that mean that every python_mod_optimize user (ebuild) that used it
> as was expected from python_mod_optimize is now broken for ROOT != "/"
> by installing them into ${ROOT}/${ROOT}/ ?
>
>

*fail*

Appearently python_mod_optimize is not ROOT aware (yet). I thought this
patch¹ was committed and didn't bother to check the eclass (silly me).
I'll commit it tomorrow and make sure the tree is consistent.
Join the fun if you have time :-)

¹: http://dev.gentoo.org/~hawking/tmp/python-root_awareness.diff

--
Regards,
Ali Polatel
 
Old 05-26-2008, 09:27 AM
Bo rsted Andresen
 
Default Eclass for gnome-python* split

On Saturday 24 May 2008 00:01:20 Arun Raghavan wrote:
> http://gitorious.org/projects/g-py-split/repos/mainline/blobs/g-py-split/eclass/gnome-python-common.eclass

Comments to quoted parts of the eclass below...

> G_PY_BINDINGS=${G_PY_BINDINGS:-${PN%-*}}

From the comments above it I get the impression that the wildcard is unnecessary:

G_PY_BINDINGS=${G_PY_BINDINGS:-${PN%-python}}

> RDEPEND="[...]
> =dev-python/${G_PY_PN}-base-${PV}"

This should probably at least be ~dev-python/${G_PY_PN}-base-${PV} so you don't
have to change the eclass whenever you do a revision bump to the base package.

> if hasq examples ${USE}; then

This should certainly be:

if hasq examples ${IUSE} && use examples; then

It's not clear to me whether you intended to add examples to IUSE for all
ebuilds in which case IUSE="examples" should be added to the eclass too...
Otherwise all ebuilds that use it must add it to IUSE manually.

> python_mod_optimize /usr/$(get_libdir)/python${PYVER}/site-packages/gtk-2.0

Ideally this code would make you inherit multilib explicitly too.

--
Bo Andresen
Gentoo KDE Dev
 
Old 05-26-2008, 07:01 PM
Jeroen Roovers
 
Default Eclass for gnome-python* split

On Sun, 25 May 2008 02:26:42 +0530
"Arun Raghavan" <arunisgod@gmail.com> wrote:

> if has_version =dev-python/gtkspell-2*; then
> LICENSE="GPL-2"
> else
> LICENSE="LGPL-2.1"
> fi
>
> There is currently *no* way to express this in an ebuild without
> invalidating the cache. For now this is just a theoretical problem,
> but worthy of consideration nonetheless.

LICENSE="GPL-2 LGPL-2.1" is a bit awkward, but valid, and is the
current practice for multi-licensed packages.


Kind regards,
JeR
--
gentoo-dev@lists.gentoo.org mailing list
 
Old 05-29-2008, 07:01 PM
Ali Polatel
 
Default Eclass for gnome-python* split

Ali Polatel yazmış:
> Mart Raudsepp yazmış:
> > On L, 2008-05-24 at 10:18 +0300, Ali Polatel wrote:
> > > Arun Raghavan yazmış:
> > > > Greetings All,
> > >
> > > Hey there
> > >
> > > > I've been working on an ancient bug [1] requesting a split of the
> > > > gnome-python, gnome-python-extras, and gnome-python-desktop ebuilds.
> > >
> > > Good for you :P
> > >
> > > *snip*
> > > >
> > > > Feedback and comments (and even brickbats ) on the eclass are invited.
> > > >
> > >
> > > Attached is a patch for two minor issues with the eclass. First try to
> > > remove py-compile only if it exists. Second, python_mod_optimize is
> > > ROOT aware (since recently).
> >
> > Does that mean that every python_mod_optimize user (ebuild) that used it
> > as was expected from python_mod_optimize is now broken for ROOT != "/"
> > by installing them into ${ROOT}/${ROOT}/ ?
> >
> >
>
> *fail*
>
> Appearently python_mod_optimize is not ROOT aware (yet). I thought this
> patch¹ was committed and didn't bother to check the eclass (silly me).
> I'll commit it tomorrow and make sure the tree is consistent.
> Join the fun if you have time :-)
>
> ¹: http://dev.gentoo.org/~hawking/tmp/python-root_awareness.diff
>

Done. :-)

--
Regards,
Ali Polatel
 

Thread Tools




All times are GMT. The time now is 10:35 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org