[103155] trunk/dports/gnome/gtk2/Portfile

ryandesign at macports.org ryandesign at macports.org
Sat Feb 16 03:06:55 PST 2013


Revision: 103155
          https://trac.macports.org/changeset/103155
Author:   ryandesign at macports.org
Date:     2013-02-16 03:06:55 -0800 (Sat, 16 Feb 2013)
Log Message:
-----------
gtk2: use require_active_variants; deprecate no_x11 variant

Modified Paths:
--------------
    trunk/dports/gnome/gtk2/Portfile

Modified: trunk/dports/gnome/gtk2/Portfile
===================================================================
--- trunk/dports/gnome/gtk2/Portfile	2013-02-16 10:55:17 UTC (rev 103154)
+++ trunk/dports/gnome/gtk2/Portfile	2013-02-16 11:06:55 UTC (rev 103155)
@@ -2,6 +2,7 @@
 # $Id$
 
 PortSystem          1.0
+PortGroup           active_variants 1.1
 PortGroup           muniversal 1.0
 PortGroup           xcodeversion 1.0
 
@@ -71,14 +72,6 @@
     if {![variant_isset quartz] && ![variant_isset x11]} {
         error "Either +x11 or +quartz is required"
     }
-
-    if {[variant_isset quartz]} {
-        if {![file exists ${prefix}/include/cairo/cairo-quartz.h]} {
-            error "cairo must be built with the +quartz variant enabled."
-        }
-    } elseif {![file exists ${prefix}/include/cairo/cairo-xlib.h]} {
-        error "cairo must be built without the +no_x11 variant."
-    }
 }
 
 use_parallel_build  yes
@@ -107,7 +100,7 @@
 }
 
 platform darwin 8 {
-    if {[variant_isset quartz] || [variant_isset no_x11]} {
+    if {[variant_isset quartz] || ![variant_isset x11]} {
         configure.ldflags-append  -framework Cocoa -framework Carbon
     }
 
@@ -192,20 +185,17 @@
     }
 }
 
-variant no_x11 description {Disable X11 support} {
-    pre-fetch {
-        if {[file exists ${prefix}/lib/libpangox-1.0.dylib]} {
-            ui_error "Please install pango without the x11 variant, by running 'port install pango -x11'."
-            error "pango must be installed with the x11 variant disabled"
-        }
-    }
-}
+variant quartz conflicts x11 {
+    require_active_variants cairo quartz
+    require_active_variants pango quartz
 
-variant quartz requires no_x11 conflicts x11 {
     configure.args-append   --with-gdktarget=quartz
 }
 
-variant x11 conflicts quartz {
+variant x11 conflicts quartz no_x11 {
+    require_active_variants cairo x11
+    require_active_variants pango x11
+
     depends_lib-append \
         port:xorg-libXi \
         port:xorg-libXrandr \
@@ -219,6 +209,8 @@
                                --x-include=${prefix}/include --x-lib=${prefix}/lib
 }
 
+variant no_x11 conflicts x11 description {Legacy compatibility variant} {}
+
 livecheck.type  regex
 livecheck.url   ftp://ftp.gnome.org/pub/gnome/sources/gtk+/${branch}/
 livecheck.regex {LATEST-IS-(\d+(?:\.\d+)*)}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20130216/a89ef26a/attachment.html>


More information about the macports-changes mailing list