On Fri, 2003-10-24 at 10:58, Chris Cannam wrote:
> On Friday 24 October 2003 09:15, John Anderson wrote:
> > Is there a file pkg.m4 in /usr/share/aclocal? If not, where is it?
> 
> No, I don't have it anywhere.  pkg-config simply isn't installed here; 
> there is no vestige of it anywhere.  ("Here" is a SuSE 8.2 system with 
> a reasonably complete set of development packages.  I imagine 
> pkg-config probably is on the SuSE CDs, but they don't seem keen to 
> install it.

Probably because you don't have gnome installed? Most of the gnome libs
use pkg-config.

> Of course I can easily work around this myself by just 
> installing the thing, it's the wacky error message I don't like.)

The contents of pkg.m4 (ie PKG_CHECK_MODULES) will always be in
aclocal.m4 for a distribution, provided the distribution-maker has
pkg-config installed. Then it's only necessary to find out if the
pkg-config executable exists. This is one way of doing it. If it doesn't
exist, you could also check for jack without using pkg-config. For this
patch, the configure just stops. The error message could be more
friendly.

If jack.pc is not found in any of the specified locations, an error
message will be displayed and the configure will continue with
with_jack="no".

I 'spose you could also have a --with-jack=/opt/some_place_for_jack type
option, if you want to stay away from pkg-config.

Index: configure.in.in
===================================================================
RCS file: /cvsroot/rosegarden/rosegarden/configure.in.in,v
retrieving revision 1.56
diff -u -r1.56 configure.in.in
--- configure.in.in     23 Oct 2003 11:01:35 -0000      1.56
+++ configure.in.in     24 Oct 2003 09:59:44 -0000
@@ -71,8 +71,13 @@
  
   dnl only use JACK when jack/jack.h is found
   if test "$with_jack" = "yes"; then
-     export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
+     export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig
      PKG_CHECK_MODULES(JACK,jack >= 0.77.0,,[with_jack="no"])
+
+     dnl this relies on PKG_CHECK_MODULES not setting JACK_PKG_ERRORS when
+     dnl pkg-config is not found
+     if test $with_jack == "no" && test -z $JACK_PKG_ERRORS; then
+        dnl this happens when pkg-config is not found
+        AC_MSG_ERROR([pkg-config not found])
+     fi
   fi
  
   if test "$with_jack" = "yes"; then




-------------------------------------------------------
This SF.net email is sponsored by: The SF.net Donation Program.
Do you like what SourceForge.net is doing for the Open
Source Community?  Make a contribution, and help us add new
features and functionality. Click here: http://sourceforge.net/donate/
_______________________________________________
Rosegarden-devel mailing list
[EMAIL PROTECTED] - use the link below to unsubscribe
https://lists.sourceforge.net/lists/listinfo/rosegarden-devel

Reply via email to