New Ticket     Wiki     Browse Source     Timeline     Roadmap     Ticket Reports     Search

Ticket #17062: patch-gimp2-Portfile-quartz.diff

File patch-gimp2-Portfile-quartz.diff, 1.9 KB (added by devans@…, 4 years ago)

Modified patch for Portfile

  • Portfile

     
    9494configure.python    ${prefix}/bin/python2.5 
    9595configure.args  --enable-mp \ 
    9696                --with-pdbgen \ 
     97                --with-x \ 
    9798                --without-dbus \ 
    9899                --without-hal \ 
    99100                --without-alsa \ 
     
    120121    configure.args-delete   --without-webkit 
    121122} 
    122123 
     124if {[variant_isset no_x11]} { 
     125    default_variants    +quartz 
     126} 
     127 
     128if {![variant_isset quartz]} { 
     129    default_variants    +x11 
     130} 
     131 
     132pre-fetch { 
     133    if {![variant_isset quartz] && ![variant_isset x11]} { 
     134        error "Either +x11 or +quartz is required" 
     135    } 
     136} 
     137 
     138pre-configure { 
     139    if {[file exists ${prefix}/lib/gtk-2.0/include/gdkconfig.h]} { 
     140        set gtk_not_quartz [catch {exec grep -q GDK_WINDOWING_QUARTZ ${prefix}/lib/gtk-2.0/include/gdkconfig.h}] 
     141        set gtk_not_x11 [catch {exec grep -q GDK_WINDOWING_X11 ${prefix}/lib/gtk-2.0/include/gdkconfig.h}]  
     142        if {[variant_isset quartz] && ${gtk_not_quartz}} {  
     143            error "+quartz variant selected, but gtk2+x11 is installed" 
     144        } elseif {[variant_isset x11] && ${gtk_not_x11}} { 
     145                error "+x11 variant selected, but gtk2+quartz is installed" 
     146        } 
     147    } else { 
     148            error "Cannot find gdkconfig.h" 
     149    } 
     150} 
     151 
     152variant quartz requires no_x11 conflicts x11 description {Enable Quartz rendering} { 
     153    configure.env-append   LDFLAGS="-framework Carbon" 
     154} 
     155 
     156variant x11 conflicts quartz description {Enable rendering in X11 (default)} { 
     157} 
     158 
     159variant no_x11 description {Build without X Windows support} { 
     160    configure.args-delete --with-x 
     161    configure.args-append --without-x 
     162} 
     163 
    123164livecheck.check regex 
    124165livecheck.url   http://www.gimp.org/downloads/ 
    125166livecheck.regex "gimp-(${branch}(?:\\.\\d+)*)${extract.suffix}"