tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Making pkg-config know about X11BASE and /usr



Hi,

I can't think of a good reason not to commit the following patch, which
allows pkg-config to find stuff from X11BASE and /usr, at least for the
user's benefit.  When pkg-config is run by pkgsrc, it can only find
stuff in the buildlink directory, so it's not affected by this patch.

Comments?

Index: Makefile
===================================================================
RCS file: /cvsroot/pkgsrc/devel/pkg-config/Makefile,v
retrieving revision 1.14
diff -u -r1.14 Makefile
--- Makefile    16 Apr 2008 22:50:43 -0000      1.14
+++ Makefile    7 Apr 2009 16:25:10 -0000
@@ -2,6 +2,7 @@
 #
 
 DISTNAME=      pkg-config-0.23
+PKGREVISION=   1
 CATEGORIES=    devel
 MASTER_SITES=  http://pkgconfig.freedesktop.org/releases/
 
@@ -38,6 +39,21 @@
 CONFIGURE_ARGS+=       glib_cv_rtldglobal_broken=no
 .endif
 
+PKGCONFIG_EXTRA_PATHS= # empty
+
+.if ${LOCALBASE} != ${X11BASE}
+PKGCONFIG_EXTRA_PATHS+=        ${X11BASE}/lib/pkgconfig
+.endif
+
+.if ${LOCALBASE} != "/usr"
+PKGCONFIG_EXTRA_PATHS+=        /usr/lib/pkgconfig
+.endif
+
+.if !empty(PKGCONFIG_EXTRA_PATHS)
+# First part of the value is taken from configure.in
+CONFIGURE_ARGS+=       
--with-pc-path='$${libdir}/pkgconfig:$${datadir}/pkgconfig:${PKGCONFIG_EXTRA_PATHS:ts:}'
+.endif
+
 # needed for fifth test case
 BUILDLINK_PASSTHRU_DIRS= /private-dep /public-dep /requires-test
 TEST_TARGET=           check

-- 
Quentin Garnier - cube%cubidou.net@localhost - cube%NetBSD.org@localhost
"See the look on my face from staying too long in one place
[...] every time the morning breaks I know I'm closer to falling"
KT Tunstall, Saving My Face, Drastic Fantastic, 2007.

Attachment: pgpvl8G6IHxqP.pgp
Description: PGP signature



Home | Main Index | Thread Index | Old Index