After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 160698 - libgnomeprint requires libgnomecups
libgnomeprint requires libgnomecups
Status: RESOLVED FIXED
Product: GARNOME
Classification: Deprecated
Component: general
unspecified
Other Linux
: High normal
: ---
Assigned To: GARNOME Maintainers
garnome list
: 160697 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2004-12-07 14:47 UTC by James Ogley
Modified: 2005-07-05 10:43 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch to add libgnomecups dependency to libgnomeprint (433 bytes, patch)
2004-12-07 14:48 UTC, James Ogley
none Details | Review
Patch to add deps for libgnomecups to libgnomeprint as needed. (298 bytes, patch)
2004-12-08 04:52 UTC, Bob Kashani
none Details | Review
Changed patch to run before configure. (302 bytes, patch)
2004-12-08 17:42 UTC, Bob Kashani
none Details | Review
patch to alter libgnomeprint/Makefile LIBDEPS (359 bytes, patch)
2004-12-08 22:57 UTC, Karsten Bräckelmann
none Details | Review

Description James Ogley 2004-12-07 14:47:07 UTC
libgnomeprint in GARNOME 2.9.2 requires libgnomecups, attaching patch to include
it as a dep from the geektoys directory
Comment 1 James Ogley 2004-12-07 14:48:08 UTC
Created attachment 34586 [details] [review]
Patch to add libgnomecups dependency to libgnomeprint
Comment 2 Karsten Bräckelmann 2004-12-07 18:29:25 UTC
libgnomeprint does not necessarily depend on libgnomecups -- only, if you are
using CUPS, AFAIK. Thus, as it isn't always a dependency and aslibgnomecups
isn't part of the official GNOME D&DP, the dependency should not be hard coded
into the Makefiles.

On the other hand, a lot of folks seem to have issues with this...

NOTABUG ?
Comment 3 Karsten Bräckelmann 2004-12-07 18:38:51 UTC
*** Bug 160697 has been marked as a duplicate of this bug. ***
Comment 4 Karsten Bräckelmann 2004-12-07 18:45:04 UTC
Confirmed now.

Anyway, not sure if this is valid bug or not.
Comment 5 Raul Acevedo 2004-12-07 18:46:23 UTC
This should be fixed, but by using a shell command in the Makefile to determine
if CUPS is being used.  Is this possible?
Comment 6 Karsten Bräckelmann 2004-12-07 20:32:07 UTC
Should be possible by checking 'cups-config', just like libgnomecups's configure
does. A patch should go in to platform/libgnomeprint/Makefile, altering it's
dependencies.

I will check this later today.
Comment 7 Karsten Bräckelmann 2004-12-07 22:46:13 UTC
Assuming libgnomeprint depends on lignomecups if (and only if) CUPS is used, and
assuming determining whether cups is available or not can be done by
cups-config, this line added after the CONFIGURE_ARGS line in
libgnomeprint/Makefile will add the dependency:

CONFIGURE_ARGS += $(shell if test -e "`which cups-config 2> /dev/null`"; then \
  echo path/cups; \
fi )

However, cups-config is needed by lignomecups for building, but it is provided
by libcups2-devel RPM on my system. Thus the above should fail, if CUPS is used,
libgnomecups is needed, but the devel package isn't installed yet. (Which means,
you get the very same error as before. This will add the dependency
automagically only, if the devel package is installed already.)

There should be a better solution...
Comment 8 Bob Kashani 2004-12-08 04:52:24 UTC
Created attachment 34617 [details] [review]
Patch to add deps for libgnomecups to libgnomeprint as needed.
Comment 9 Bob Kashani 2004-12-08 17:42:01 UTC
Created attachment 34635 [details] [review]
Changed patch to run before configure.

Changed patch to run before configure instead of fetch.
Comment 10 Karsten Bräckelmann 2004-12-08 22:55:54 UTC
Doh! I sure meant to alter LIBDEPS rather than CONFIGURE_ARGS.

IMHO it is cleaner, to use the given LIBDEPS than to bypass the structure used
in every other Garnome Makefile and start calling sub makes on our own...

My patch implements this.


Note on comment #9: Without redirecting error messages by 'which' a pretty ugly
error message will be displayed if cups-config isn't installed. Which should be
avoided, as not using CUPS is not an error.

The caveat in comment #7 applies anyway. Is checking for cups-config really the
way to go?
Comment 11 Karsten Bräckelmann 2004-12-08 22:57:47 UTC
Created attachment 34642 [details] [review]
patch to alter libgnomeprint/Makefile LIBDEPS
Comment 12 Bob Kashani 2004-12-09 01:03:19 UTC
Comment on attachment 34635 [details] [review]
Changed patch to run before configure.

Yes, Karsten piping the error output of `which` to /dev/null would be cleaner
but since it has no effect on the functionality it's not really needed. :-) But
cleaner is always better.

Anyway, I like your patch better and it's actually cleaner since it uses
LIBDEPS.

As to whether checking for cups-config is the best solution: I think the best
solution would be if pkg-config checked to see if both cups devel and
libgnomecups were present before trying to build cups support into
libgnomeprint.
Comment 13 Karsten Bräckelmann 2004-12-09 02:06:05 UTC
On my system pkg-config doesn't know about cups, and 'cups-config --libs' does
its duty. Due to this shortage and as libgnomeprint uses cups-config itself, I
came up with this idea in the first place.

Anyway, I still don't know, if this is correct in all cases.
Comment 14 Paul Drain 2005-01-24 05:09:38 UTC
OK, a test for this was included in both branches of GARNOME -- can I get a show
of hands if this is still broken for anyone except my one Red Hat 9 box?

Tempted to mark this as FIXED, just to get a 0% outstanding report on the patch
dilligence rant that Luis posted to d-d-l ... but i'll NEEDINFO it instead, for
now -- just incase.

Comment 15 Karsten Bräckelmann 2005-01-25 19:41:40 UTC
Sure, WORKSFORME. :-)

Anyway, getting the impression I'm talking to myself here. No one ever responded
to my caveat in comment #7, so yet again.

'cups-config' is needed by lignomecups for building and the patch actually
checks for this -- however, it is provided by libcups2-devel RPM on my system.
Thus the patch will fail, if CUPS is used and libgnomecups is needed, but the
devel package is *not* installed yet.

The patch does not determine, if CUPS is used, but rather if the devel package
is installed. It will fail like any other devel requirement, which is not met
when building Garnome.
Comment 16 Karsten Bräckelmann 2005-07-04 17:16:15 UTC
*poke*

Seems my patch works fine, no additional reports/complaints or new bugs.
Can we finally close this bug as FIXED?
Comment 17 Stef van der Made 2005-07-04 19:01:08 UTC
the fix works fine thanks
Comment 18 Karsten Bräckelmann 2005-07-05 10:43:39 UTC
Thanks Stef. :)

OK, going ahead then and finally closing FIXED.