Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 Jun 2002 18:45:13 -0700 (PDT)
From:      Doug Barton <DougB@FreeBSD.org>
To:        Joe Marcus Clarke <marcus@FreeBSD.org>
Cc:        cvs-committers@FreeBSD.org, <cvs-all@FreeBSD.org>, <sobomax@FreeBSD.org>
Subject:   pkg-config generating bogus -I lines
Message-ID:  <20020613181722.G62909-100000@zoot.corp.yahoo.com>
In-Reply-To: <20020613165911.V2146-100000@zoot.corp.yahoo.com>

next in thread | previous in thread | raw e-mail | index | archive | help

On Thu, 13 Jun 2002, Doug Barton wrote:

> On Thu, 13 Jun 2002, Joe Marcus Clarke wrote:
>
> >   Correct the name of the gdk library in the gdk pkgconfig file.  This
> > should get xscreensaver building correctly without needing to delete
> > pkgconfig.
>
> glib also needs this fix. I actually patched my .pc files by hand with the
> same stuff you had in your patchfiles. When all 3 files were updated,
> xscreensaver compiles cleanly with pkg-config installed.

Sorry, I spoke too soon. pkg-config is generating bogus -I lines. The
xscreensaver configure program calls it as "pkg-config --cflags gtk+".
That gives the following output:

   -I/usr/local/include/glib12/glib-1.2 -I/usr/local/lib/glib/include
-I/usr/X11R6/include/gtk12/gtk-1.2 -I/usr/local/include
-I/usr/X11R6/include

Note, the glib and gtk lines have the version number appended to the
string. Here are my .pc files:

prefix=/usr/X11R6
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=/usr/X11R6/include/gtk12

Name: GDK
Description: GIMP Drawing Kit
Version: 1.2.10
Requires: glib
Libs: -L${libdir}   -L/usr/X11R6/lib -lgdk12 -lintl -lxpg4  -lXext -lX11
-lm
Cflags: -I${includedir}/gtk-1.2 -I/usr/local/include -I/usr/X11R6/include

----

prefix=/usr/X11R6
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=/usr/X11R6/include/gtk12
Name: GTK+
Description: GIMP Tool Kit
Version: 1.2.10
Requires: gdk
Libs: -L${libdir} -lgtk12
Cflags:

---

prefix=/usr/local
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=/usr/local/include/glib12

Name: GLib
Description: C Utility Library
Version: 1.2.10
Libs: -L${libdir} -lglib12
Cflags: -I${includedir}/glib-1.2 -I${libdir}/glib/include


Changing 'Cflags:' to be simply:

Cflags: -I${includedir}

in each case seems to have done the trick. At very least, the erroneous
version strings should be patched out of the .pc.in files for gdk.pc.in
and glib.pc.in.

Doug

-- 
   "We have known freedom's price. We have shown freedom's power.
      And in this great conflict, ...  we will see freedom's victory."
	- George W. Bush, President of the United States
          State of the Union, January 28, 2002

         Do YOU Yahoo!?




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020613181722.G62909-100000>