[47543] trunk/dports/graphics/cairo-devel/Portfile
jeremyhu at macports.org
jeremyhu at macports.org
Sat Feb 28 16:21:48 PST 2009
Revision: 47543
http://trac.macports.org/changeset/47543
Author: jeremyhu at macports.org
Date: 2009-02-28 16:21:48 -0800 (Sat, 28 Feb 2009)
Log Message:
-----------
cairo-devel: Add the AC_X_PATH workaround
Modified Paths:
--------------
trunk/dports/graphics/cairo-devel/Portfile
Modified: trunk/dports/graphics/cairo-devel/Portfile
===================================================================
--- trunk/dports/graphics/cairo-devel/Portfile 2009-03-01 00:21:35 UTC (rev 47542)
+++ trunk/dports/graphics/cairo-devel/Portfile 2009-03-01 00:21:48 UTC (rev 47543)
@@ -77,6 +77,27 @@
--with-x
# change --enable-freetype to --enable-ft starting with cairo-devel 1.9.x
+# AC_X_PATH blindly asks xmkmf where X11 is, and it always uses /usr/X11R6.
+# This block helps us link correctly and setup our pc files correctly when we
+# are +system_x11 and x11prefix is somewhere non-standard and should cause
+# AC_X_PATH to let us setup our CPPFLAGS and LDFLAGS without interference
+configure.args-append --x-include=${prefix}/include --x-lib=${prefix}/lib
+if { ![file exists ${prefix}/lib/pkgconfig/x11.pc] } {
+ pre-configure {
+ configure.cppflags-append -I${x11prefix}/include
+ configure.ldflags-append -L${x11prefix}/lib
+ }
+
+ # And this will similarly get ports that use pkgconfig to find our pkgconfig-less libX11
+ post-destroot {
+ if {![file exists ${x11prefix}/lib/pkgconfig/x11.pc]} {
+ foreach pc [glob ${destroot}${prefix}/lib/pkgconfig/*.pc] {
+ reinplace "s:-lX11:-L${prefix}/lib -L${x11prefix}/lib -lX11:g" ${pc}
+ }
+ }
+ }
+}
+
variant glitz conflicts no_x11 description {Add glitz graphics interface} {
depends_lib-append \
port:glitz
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20090228/d2fff480/attachment.html>
More information about the macports-changes
mailing list