Gentoo Archives: gentoo-user

From: Jure Varlec <exzombie@×××××××××××××××.net>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Unwanted dependecies
Date: Fri, 23 Jun 2006 16:22:23
Message-Id: 200606231751.27273.exzombie@exzombie.homeip.net
In Reply to: Re: [gentoo-user] Unwanted dependecies by "Bo Ørsted Andresen"
1 Thank you for replying. I see now that I should clarify further what is
2 bothering me, as you didn't quite see my point. I guess it got lost in the
3 noise. No more stories then :)
4
5 >Remember USE flags are for *optional* dependencies. Mandatory dependencies
6 >will remain no matter what USE flags you set.
7
8 I understand. That is not the problem.
9
10 >How did you determine that? Did the ebuild inherit any eclasses and did you
11 >look in those? Also make sure you have >=gentoolkit-0.2.2.
12
13 Gentoolkit is 0.2.2. After equery, I took a look at the ebuild.
14 As for the eclasses, I must admit I'm still not too comfortable with them,
15 which is what I was actually referring to when I said I need to understand
16 portage better. It's a shame really considering that I've been using gentoo
17 for two-and-a-half years. I need to get spanked ;) . But as far as I
18 understand it (and from what I can see looking at the eclasses) they are
19 merely collections of useful shell functions which devs can use when writing
20 ebuilds.
21
22 Anyway, to get rid of unnecessary confusion, I will give you an example
23 package which I remember, and whose ebuild is simple enough so that it does
24 not include any complicated inherits. In fact, it is short enough to be
25 included in this mail.
26
27 > # Copyright 1999-2006 Gentoo Foundation
28 > # Distributed under the terms of the GNU General Public License v2
29 > # $Header: /var/cvsroot/gentoo-x86/media-gfx/gqview/gqview-2.0.1.ebuild,v
30 > 1.8 2006/02/21 21:31:07 mr_bones_ Exp $
31 >
32 > DESCRIPTION="A GTK-based image browser"
33 > HOMEPAGE="http://gqview.sourceforge.net/"
34 > SRC_URI="mirror://sourceforge/gqview/${P}.tar.gz"
35 >
36 > LICENSE="GPL-2"
37 > SLOT="0"
38 > KEYWORDS="alpha amd64 ia64 ppc ppc64 sparc x86"
39 > IUSE=""
40 >
41 > RDEPEND=">=x11-libs/gtk+-2.4.0
42 > virtual/libintl"
43 >
44 > DEPEND="${RDEPEND}
45 > sys-devel/gettext"
46 >
47 > src_install() {
48 > make DESTDIR="${D}" install || die "make install failed"
49 > # leave README uncompressed because the program reads it
50 > dodoc AUTHORS ChangeLog TODO
51 > rm -f "${D}/usr/share/doc/${PF}/COPYING"
52 > }
53
54 As you can see, it does not inherit anything, and does not depend on anything
55 gnomish. However, when I checked with equery, it definitely depended on
56 something which I didn't need/want (sorry, I can't remember what it was,
57 probably gconf or some such), although the ebuild specifies no such
58 dependency, not even indirectly (through gtk+ etc.) After I removed the
59 unwanted dep and remerged gqview, it did not pull the removed "dependency"
60 back in, and no longer depends on it.
61
62 The same applies for dependencies which were disabled through use flags, such
63 as this snip (from openoffice):
64
65 > gnome? ( >=x11-libs/gtk+-2.4
66 >
67 > >=gnome-base/gnome-vfs-2.6
68 > >=gnome-base/gconf-2.0 )
69
70 In this case, It depended on gnome-vfs and gconf, even when the gnome USE flag
71 was disabled. After I removed the offending packages and recompiled
72 openoffice, the dependecy is gone.
73 Note: you might remember I wrote that oo.org used to be compiled with
74 USE="eds", which pulls these in along with other stuff indirectly through
75 gnome-extra/evolution-data-server. It was the reason these libs were
76 installed in the first place. The dependency problem I'm describing, however,
77 is independent from that and was present even after I recompiled oo.org
78 without "eds".
79
80 I hope this helped you better understand what is bothering me. It's not that
81 I'm particularly against having those libs installed and wouldn't mind to
82 keep them if they were hard deps of something I needed, but I'm kind of
83 frustrated when packages depend on things I told them not to depend on
84 through USE flags. It means I cant test a package with a hard dep on a lib
85 because in case I emerge something while that lib is installed, I'll never
86 know if it will choose to depend on that lib, which in turn would mean that
87 after I remove the lib, I need to recompile stuff, once more. In the past two
88 weeks, I recompiled openoffice 4 times, which is 3 times more than I'm
89 normally willing to do it. This is not to say I would be less frustrated if
90 only small packages were affected :)
91
92 Looking at oo.org ebuild again and I see that it uses use_enable function in
93 the call to ./configure. So why the heck did it depend on gconf and gnome-vfs
94 when it was obviously told not to? And even more confusing: how did equery
95 know about this dependency?
96
97 *Sigh*
98 I hope I'm missing something here. Because if these are bugs, there's quite a
99 few. Sadly, I removed all the temporary lists of packages I removed and
100 rebuilt, so I have nothing to report now. Stupid me.
101
102 Jure

Replies

Subject Author
Re: [gentoo-user] Unwanted dependecies Neil Bothwick <neil@××××××××××.uk>
Re: [gentoo-user] Unwanted dependecies "Bo Ørsted Andresen" <bo.andresen@××××.dk>