First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 40453
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Default Assignee for Orphaned Packages <maintainer-needed@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Ervin Németh <ervin.nemeth+org.gentoo.bugs@gmail.com>
Add CC:
CC:
Remove selected CCs
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
imlib-1.9.14-r1.ebuild.patch gtk dependency patch patch Ervin Németh 2004-02-05 02:26 0000 659 bytes Details | Diff
imlib-1.9.14-r1.ebuild.patch gtk and tiff dependency patch patch Ervin Németh 2004-02-05 04:01 0000 722 bytes Details | Diff
imlib-1.9.14-r1.ebuild.patch gtk dependency patch patch Ervin Németh 2004-02-06 02:07 0000 885 bytes Details | Diff
imlib-1.9.14-r1.ebuild.diff gtk dep: --with-gtk-prefix patch patch Simone Piccinini 2004-08-26 04:16 0000 580 bytes Details | Diff
configure.in.diff add --enable-gdk and --disable-gdk to imlib-1.9.14/configure.in patch Simone Piccinini 2004-08-26 06:57 0000 888 bytes Details | Diff
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 40453 depends on: Show dependency tree
Bug 40453 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2004-02-05 02:24 0000
The ebuild file of imlib states a dependency on gtk.  It is good, so far.

However using gnome/gtk2 with sawfish for example will depend on imlib, wich will pull in gtk.  This is not good.

------- Comment #1 From Ervin Németh 2004-02-05 02:26:28 0000 -------
Created an attachment (id=24992) [details]
gtk dependency patch

This patch makes use of the "gtk" USE variable.  Imlib *can* be compiled
without gtk.

------- Comment #2 From Ervin Németh 2004-02-05 04:01:39 0000 -------
Created an attachment (id=25002) [details]
gtk and tiff dependency patch

Even better, use the tiff variable, too.  This time I didn't test whether imlib
configure fails without libtiff...

------- Comment #3 From Spider (RETIRED) 2004-02-05 10:14:27 0000 -------
A note here:
  its not enough to patch dependencies like this, You -must- also make sure that the case where:
a) I have tiff installed, USE="-tiff"  - doesn't - link to libtiff.  Because if it uses automagic (oh, I see tiff in the system, lets link to it) there is no dependency tracking and you can, and may, uninstall tiff and thereby break things that -explicitly doesn't depend- on tiff.

b) same for gtk+.


so in conclusion, doing the DEPEND/RDEPEND magic only is -bad- and broken behaviour. if you want this without gtk+ and tiff, make sure the build doesn't link them if USE="-gtk -tiff" and they are installed.  If you cannot guarantee this, the hard dependencies are rule, because even if they don't give you the fullest of choices, they guarantee a stable and functional system.


------- Comment #4 From Ervin Németh 2004-02-06 02:07:23 0000 -------
Created an attachment (id=25065) [details]
gtk dependency patch

I was irresponsible. According to the README libtiff is required for imlib. So
I removed the tiff USE variable.

Because imlib doesn't support "--without-gtk" I made the script look for
gtk-config where it isn't supposed to find it.

------- Comment #5 From Ervin Németh 2004-02-16 02:03:16 0000 -------
What do you think, Spider, is this patch mature enogh to be merged into the
portage tree?

------- Comment #6 From foser (RETIRED) 2004-02-16 03:33:49 0000 -------
it's an interesting approach.

Do you happen to know what imlib's gtk support consists of ? It should not break any applications using it like that.

------- Comment #7 From Ervin Németh 2004-02-16 06:20:47 0000 -------
I don't know really but I think if someone is using USE="-gtk" imlib should not
force gtk anyway.

------- Comment #8 From Spider (RETIRED) 2004-02-16 15:51:00 0000 -------
well, the problem isn't as much "force or not" as "what breaks due to expecting
imlib+gdk-pixbuf" , since gdk-pixbuf is the loader-code for PNG, jpeg and
others (those it doesn't have native support for) , thats why things sorta. As
i recall gdk was used for fallback rendering when it didn't find anything.

I do like the approach though, creative.

------- Comment #9 From Hanno Boeck 2004-03-12 03:29:22 0000 -------
Please note that there is a --disable-gtktest-switch to imlib, which should
also be disabled when USE="-gtk" is set.

Beside that, I really think this fix is important to get into the tree, because
at the moment, it's impossible to build kde without installing gtk-1.2.

------- Comment #10 From Boris 2004-05-27 05:16:09 0000 -------
The econf_args="--with-gtk-prefix=/dev/null" did not work for me, but replacing
it with econf_args="--disable-gtktest-switch" worked great.

------- Comment #11 From Carsten Lohrke 2004-08-15 15:08:35 0000 -------
*** Bug 60361 has been marked as a duplicate of this bug. ***

------- Comment #12 From Carsten Lohrke 2004-08-15 15:09:56 0000 -------
I didn't really looked into the code, but may it be, that gtk is not optional?
If gtk-test is performed or not is not of interest and the GTK_CONFIG variable
seems to be set via --with-gtk-exec-prefix. I testet --without and =/dev/null,
but with USE=-gtk the ebuild fails always. 

------- Comment #13 From Urs Hunkeler 2004-08-17 09:31:44 0000 -------
On my sparc64 at least imlib won't compile without gtk (USE="-gtk"). 

------- Comment #14 From Edwin van Ouwerkerk Moria 2004-08-18 15:15:14 0000 -------
same on my amd64 system. /etc/make.conf has USE="-gtk", but I have to add
media-libs/imlib gtk in /etc/portage/packages.use in order to get imlib to
build.

------- Comment #15 From Paul Thompson 2004-08-19 16:10:54 0000 -------
Just a 'me too' that the prepending '/dev/null' results in a compilation
failure with USE="-gtk". The build thinks it finds gtk, then later blows
up because it cant find the gdk headers: (see the 'yes' at the end)

checking for gtk-config... /dev/null/bin/gtk-config
checking for GTK - version >= 1.2.1... ./configure: line 1: /dev/null/bin/gtk-config: Not a directory
./configure: line 1: /dev/null/bin/gtk-config: Not a directory
./configure: line 1: /dev/null/bin/gtk-config: Not a directory
./configure: line 1: /dev/null/bin/gtk-config: Not a directory
./configure: line 1: /dev/null/bin/gtk-config: Not a directory
yes
^^^

I am on x86 arch. And gtk is installed. Now, if I take the 
'--disable-gtktest' out of the econf_args line, then it ends with
'no', and complains about the test failing, but goes on and builds
without the gtk stuff.

To clarify, 'use gtk || econf_args="--with-gtk-prefix=/dev/null"'
seems to work. Of course, then 'xzgv' fails to build because it
depends on a gtk-ified imlib.....;) So, at this point, one wonders
how many of imlibs clients actually need gtk support...

------- Comment #16 From Carsten Lohrke 2004-08-20 08:07:28 0000 -------
*** Bug 61022 has been marked as a duplicate of this bug. ***

------- Comment #17 From Roman Gaufman 2004-08-20 08:14:53 0000 -------
Why does emerge -vp imlib list there are no use flags for imlib but enabling
the gtk use flag for it fixes the problems?

------- Comment #18 From Andrej Kacian (RETIRED) 2004-08-21 13:36:05 0000 -------
Because the flag is not listed in IUSE variable.

The ebuild as it is now is broken for USE="-gtk". Further look into imlib's configure.in reveals that gtk-1.2 is mandatory.

------- Comment #19 From Zoltan Mezei 2004-08-21 15:30:37 0000 -------
This configure flag:
econf_args="--with-gtk-prefix=/dev/null"
causes imlib not to compile for me. Though if i remove it imlib works perfectly without gtk.

------- Comment #20 From Carsten Lohrke 2004-08-22 15:47:04 0000 -------
*** Bug 61281 has been marked as a duplicate of this bug. ***

------- Comment #21 From Carsten Lohrke 2004-08-23 15:18:33 0000 -------
*** Bug 61421 has been marked as a duplicate of this bug. ***

------- Comment #22 From Simone Piccinini 2004-08-26 03:30:57 0000 -------
the macro invloved (configure.in):
AM_PATH_GTK([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])

if gtk is not installed GDB_IMLIB will be set to "" because gtk-config was
not found and gdk_imlib won't be built.

This macro:

 * Determines the location of GTK using gtk-config, which is either
   found in the user's path, or from the environment variable GTK_CONFIG

 * Tests the installed libraries to make sure that there version
   is later than MINIMUM-VERSION. (A default version will be used
   if not specified)

 * If the required version was found, sets the GTK_CFLAGS [...] and then
   executes ACTION-IF-FOUND.

 * If the required version was not found, sets GTK_CFLAGS and GTK_LIBS
   to empty strings, and executes ACTION-IF-NOT-FOUND.

but if gtk is installed (and so gtk-config exists) and we don't want to build gdk_imlib: --with-gtk-prefix="" or any other path with bin subdir not /dev/null if we want to follow that approach.

sorry for my bad english

------- Comment #23 From Simone Piccinini 2004-08-26 04:16:02 0000 -------
Created an attachment (id=38234) [details]
gtk dep: --with-gtk-prefix patch

------- Comment #24 From foser (RETIRED) 2004-08-26 05:54:29 0000 -------
well, ok i looked at it again. The breaking 'fix' which was discussed but not
tested & approved by spider or me (but thats alright i guess because we aren't
the official maintainers) was introduced by hanno. So with that i assume he
took maintenance (although it's not noted in metadata as it should be) ? Hanno,
please fix the obviously broken hack that seems unneeded anyway, just disabling
the test should be enough on gtk1-less systems. As for a 'hard' switch,
resetting the gtk path (what the initial patch tried to do) doesn't seem to
work.

Anyway, the reasons for our hesitation is that imlib without gtk+ exposes a
much smaller API and this -iirc- used to give problems with basic gnome
applications/libs that unconditionally depend on this extened api. So it's not
so much the question if the switch is in theory possible or that it is in
practice a wise thing to apply. On the other hand the amount of recent KDE
users vs oldskool gnome users maybe justifies having the flag.

@ comment 22 : you just concat two strings, it's a happy coincidence that it
does what you intended to do & it still doesn't do what it is supposed to do.

------- Comment #25 From foser (RETIRED) 2004-08-26 05:54:46 0000 -------
*** Bug 60961 has been marked as a duplicate of this bug. ***

------- Comment #26 From Hanno Boeck 2004-08-26 06:19:35 0000 -------
I've now switched back to the old behaviour, sorry for causing so much trouble.
I'll probably add a -r2-ebuild if I find a really working way to make the gtk-support optional.

------- Comment #27 From Simone Piccinini 2004-08-26 06:54:44 0000 -------
yes,but "" with /bin/gtk-config = "/bin/gtk-config" is a valid path,if you have
/bin directory ;) but the file not exists, while concat "/dev/null" to
"/bin/gtk-config" ="/dev/null/bin/gtk-config" is not a valid path.
i attach a simple patch for imlib/configure.in which add --enable/disable-gdk
options to configure

------- Comment #28 From Simone Piccinini 2004-08-26 06:57:38 0000 -------
Created an attachment (id=38241) [details]
add --enable-gdk and --disable-gdk to imlib-1.9.14/configure.in

------- Comment #29 From Simone Piccinini 2004-08-26 07:03:08 0000 -------
(From update of attachment 38241 [details])
sorry: AC_MSG_RESULT() inverted yes/no

------- Comment #30 From P.L.Hayes 2005-01-04 03:55:01 0000 -------
Bug #60961 is /not/ a duplicate of this bug. That bug is about giflib/libungif.
The imlib ebuild has a dependency on giflib but won't build properly unless
libungif is installed. 

I'd been having unrelated problems with both giflib and libungif and happened
to notice that libimlib-gif was actually linked with libungif - not libgif.
Since I've just successfully rebuilt imlib with *only* libungif installed, I'd
say the ebuild's dependency should be changed to libungif. The imlib configure
script doesn't look for libgif and it doesn't provide any options to use it
instead of libungif either. No doubt it /could/ use libgif but it's not set up
to do so at the moment, so it's README is rather misleading. 

------- Comment #31 From P.L.Hayes 2005-03-25 02:10:45 0000 -------
Please ignore the 2nd paragraph of comment #30.

------- Comment #32 From Leonardo Boshell (RETIRED) 2005-05-30 23:50:23 0000 -------
Nice work Simone. I've recently committed an ebuild for imlib-1.9.15, including
your patch to enable/disable Gdk and hence making the gtk+-1.2 dependency
optional. This ebuild is hardmasked for testing, so please do try it out. A
couple of things to review:

a) It should not install /usr/lib/pkgconfig/imlibgdk.pc if Gdk support is disabled.

b) The tests for -ljpeg, -tiff, -lpng, etc. are unnecessary if Gdk support is
disabled (and therefore those dependencies should be optional too).

Apart from that, this ebuild will remain hardmasked until we fully test the
result of installing imlib without the libimlib-* and libgdk_imlib* libraries.

P.L.Hayes, if the bug you mention is not a duplicate, please mention it in that
bug, and make sure to explain your reasons and the current state of the problem
so we can re-open it.

Thanks.

------- Comment #33 From Leonardo Boshell (RETIRED) 2005-06-30 17:28:12 0000 -------
*** Bug 82310 has been marked as a duplicate of this bug. ***

------- Comment #34 From Carsten Lohrke 2005-07-30 14:39:56 0000 -------
*** Bug 100817 has been marked as a duplicate of this bug. ***

------- Comment #35 From Gilles Dartiguelongue 2006-06-20 10:20:22 0000 -------
Another bug with no status update. What's the status here ?

------- Comment #36 From Jakub Moc (RETIRED) 2006-10-31 04:25:02 0000 -------
# Leonardo Boshell <leonardop@gentoo.org> (31 May 2005)
# Masked for testing, it includes an experimental patch to make Gtk+
# dependency optional. See bug #40453.
=media-libs/imlib-1.9.15

Zzzzz... Maybe it's tested enough, so someone could unmask it?

------- Comment #37 From Stefan Briesenick 2006-10-31 10:52:40 0000 -------
yes, please, it's just working!

------- Comment #38 From Jakub Moc (RETIRED) 2007-01-19 21:50:42 0000 -------
(In reply to comment #37)
> yes, please, it's just working!

Feel free, gnome herd doesn't want this anymore... 

------- Comment #39 From Samuli Suominen 2007-02-05 22:18:33 0000 -------
Fixed teh ebuild and unmasked it.

First Last Prev Next    No search results available      Search page      Enter new bug