source: trunk/dports/graphics/gimp2-devel/Portfile @ 84955

Last change on this file since 84955 was 84955, checked in by devans@…, 8 years ago

gimp2, gimp2-devel: ftp.gimp.org is temporarily down, use live gimp mirror for livecheck.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 4.9 KB
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id: Portfile 84955 2011-10-05 20:25:05Z devans@macports.org $
3
4PortSystem 1.0
5
6name            gimp2-devel
7conflicts       gimp2
8version         2.7.3
9categories      graphics
10maintainers     devans
11homepage        http://www.gimp.org/
12platforms       darwin
13
14
15description     The GNU Image Manipulation Program
16long_description \
17        The GNU Image Manipulation Program (GIMP) is a powerful \
18        tool for the preparation and manipulation of digital images. \
19        The GIMP provides the user with a wide variety of image \
20        manipulation, painting, processing, and rendering tools.
21
22#
23#  Native Mac OS X GUI (+quartz) uses 32 bit only Carbon API
24#
25
26if {[variant_isset quartz]} {
27    supported_archs i386 ppc
28}
29
30#
31# gegl is not universal
32#
33
34universal_variant  no
35
36set branch      [join [lrange [split ${version} .] 0 1] .]
37master_sites    gimp:gimp/v${branch}/
38
39checksums       sha1    bea6edc3423774ace8dd86222314f4ef2278cdd8 \
40                rmd160  5740b1b62b0fca255d0ca046477c21ab9c57a5ca
41
42distname        gimp-${version}
43
44use_bzip2       yes
45
46depends_build   port:pkgconfig \
47                port:intltool
48
49depends_lib     port:iso-codes \
50                port:gegl \
51                port:gtk2 \
52                port:libmng \
53                port:libexif \
54                port:aalib \
55                port:librsvg \
56                port:poppler \
57                port:gnome-vfs \
58                port:libgnomeui \
59                port:curl \
60                port:libwmf \
61                port:lcms \
62                port:dbus-glib
63
64patchfiles      patch-etc-gimprc.diff \
65                patch-plug-ins-twain-tw_mac.c.diff \
66                patch-app-gui-ige-mac-menu.c.diff
67
68pre-configure {
69    if {[file exists ${prefix}/lib/gtk-2.0/include/gdkconfig.h]} {
70        set gtk_not_quartz [catch {exec grep -q GDK_WINDOWING_QUARTZ ${prefix}/lib/gtk-2.0/include/gdkconfig.h}]
71        set gtk_not_x11 [catch {exec grep -q GDK_WINDOWING_X11 ${prefix}/lib/gtk-2.0/include/gdkconfig.h}]
72        if {[variant_isset quartz] && ${gtk_not_quartz}} {
73            error "+quartz variant selected, but gtk2+x11 is installed"
74        } elseif {[variant_isset x11] && ${gtk_not_x11}} {
75            error "+quartz variant is not selected, but gtk2+quartz is installed"
76        }
77    } else {
78            error "Cannot find gdkconfig.h"
79    }
80}
81
82configure.args  --build=${configure.build_arch}-apple-${os.platform}${os.version} \
83                --enable-mp \
84                --with-pdbgen \
85                --with-x \
86                --without-alsa \
87                --without-gudev \
88                --without-gvfs \
89                --without-webkit \
90                --enable-default-binary \
91                --enable-gimp-console
92
93variant python25 conflicts no_python python26 python27 description {Use python 2.5} {
94    configure.python          ${prefix}/bin/python2.5
95    depends_lib-append        port:py25-gtk
96    set python_framework      ${frameworks_dir}/Python.framework/Versions/2.5
97    configure.pkg_config_path ${python_framework}/lib/pkgconfig
98    configure.env             PATH=${python_framework}/bin:$env(PATH)
99}
100
101variant python26 conflicts no_python python25 python27 description {Use python 2.6} {
102    configure.python          ${prefix}/bin/python2.6
103    depends_lib-append        port:py26-gtk
104    set python_framework      ${frameworks_dir}/Python.framework/Versions/2.6
105    configure.pkg_config_path ${python_framework}/lib/pkgconfig
106    configure.env             PATH=${python_framework}/bin:$env(PATH)
107}
108
109variant python27 conflicts no_python python25 python26 description {Use python 2.7} {
110    configure.python          ${prefix}/bin/python2.7
111    depends_lib-append        port:py27-gtk
112    set python_framework      ${frameworks_dir}/Python.framework/Versions/2.7
113    configure.pkg_config_path ${python_framework}/lib/pkgconfig
114    configure.env             PATH=${python_framework}/bin:$env(PATH)
115}
116
117variant no_python description {Disable Python scripts and filters} {
118    configure.args-append   --disable-python
119}
120
121if {![variant_isset no_python] && ![variant_isset python25] && ![variant_isset python26]} {
122    default_variants +python27
123}
124
125variant gvfs description {Enable gvfs support} {
126    depends_lib-append      port:gvfs
127    configure.args-delete   --without-gvfs
128}
129
130variant remote description {Enable building of obsolete gimp-remote helper app} {
131    configure.args-append   --enable-gimp-remote
132}
133
134variant help_browser description {Enable Gimp help browser} {
135    depends_lib-append      port:webkit-gtk
136    configure.args-delete   --without-webkit
137}
138
139variant debug description {Enable debugging} {
140    configure.args-append  --enable-debug
141}
142
143variant quartz {
144    configure.args-delete --with-x
145    configure.args-append --without-x
146    configure.ldflags-append   -framework Carbon
147}
148
149default_variants +debug
150
151livecheck.type  regex
152livecheck.url   http://gimp.mirrors.hoobly.com/gimp/v${branch}/
153livecheck.regex "gimp-(${branch}(?:\\.\\d+)*)${extract.suffix}"
Note: See TracBrowser for help on using the repository browser.