[114581] trunk/dports/graphics/gimp2-devel

devans at macports.org devans at macports.org
Tue Dec 10 10:02:36 PST 2013


Revision: 114581
          https://trac.macports.org/changeset/114581
Author:   devans at macports.org
Date:     2013-12-10 10:02:36 -0800 (Tue, 10 Dec 2013)
Log Message:
-----------
gimp2-devel: new development version of gimp2 based on a snapshort of recent git master.

Modified Paths:
--------------
    trunk/dports/graphics/gimp2-devel/Portfile

Added Paths:
-----------
    trunk/dports/graphics/gimp2-devel/files/
    trunk/dports/graphics/gimp2-devel/files/patch-etc-gimprc.diff
    trunk/dports/graphics/gimp2-devel/files/patch-plug-ins-twain-tw_mac.c.diff
    trunk/dports/graphics/gimp2-devel/files/patch-revert-commit-7ef45be8902a4b7403d1d1736ca4f7c95b6449a8.diff

Modified: trunk/dports/graphics/gimp2-devel/Portfile
===================================================================
--- trunk/dports/graphics/gimp2-devel/Portfile	2013-12-10 17:47:56 UTC (rev 114580)
+++ trunk/dports/graphics/gimp2-devel/Portfile	2013-12-10 18:02:36 UTC (rev 114581)
@@ -2,16 +2,17 @@
 # $Id$
 
 PortSystem 1.0
+PortGroup  compiler_blacklist_versions 1.0
 
 name            gimp2-devel
-version         2.7.5
-
-replaced_by     gimp2
-
-license         {GPL-3 LGPL}
+set git_name    gimp
+set git_commit  8707701bee03db9a67350685adfe1ec85211aef7
+conflicts       gimp2 gimp3-devel
+version         2.9.1
+revision        20131209
+license         GPL-3+
 categories      graphics
 maintainers     devans
-homepage        http://www.gimp.org/
 platforms       darwin
 
 description     The GNU Image Manipulation Program
@@ -19,15 +20,199 @@
 	The GNU Image Manipulation Program (GIMP) is a powerful \
 	tool for the preparation and manipulation of digital images. \
 	The GIMP provides the user with a wide variety of image \
-	manipulation, painting, processing, and rendering tools.
+	manipulation, painting, processing, and rendering tools. \
+    This is the development version leading to a future 2.10 release \
+    branch based on a recent snapshot of upstream git master.
 
-distfiles
-universal_variant   no
+homepage        http://www.gimp.org/
+master_sites    https://git.gnome.org/browse/${git_name}/snapshot/
 
+distname        ${git_name}-${git_commit}
+
+checksums       rmd160  638c80952b7d9e698a452dd4a9caa8431ce67357 \
+                sha256  4c292476972f3ec4afa5a044e3b95d1793f4ad2d416932e59e06b43472f8b4af
+
+depends_build   port:pkgconfig \
+                port:autoconf \
+                port:automake \
+                port:libtool \
+                port:intltool \
+                port:gtk-doc
+
+depends_lib     port:desktop-file-utils \
+                port:iso-codes \
+                port:babl-devel \
+                port:gegl-devel \
+                port:atk \
+                port:gtk2 \
+                port:fontconfig \
+                port:freetype \
+                port:tiff \
+                port:jpeg \
+                port:zlib \
+                port:bzip2 \
+                port:ghostscript \
+                port:libpng \
+                port:libmng \
+                port:gexiv2 \
+                port:aalib \
+                port:xpm \
+                port:librsvg \
+                port:poppler \
+                port:curl \
+                port:libwmf \
+                port:jasper \
+                port:lcms \
+                port:dbus-glib \
+                port:libxml2 \
+                port:libxslt \
+                port:xorg-libXcursor \
+                port:xorg-libXmu \
+                port:xorg-libXext \
+                port:xorg-libXfixes
+
+depends_run     path:share/gimp/2.0/help:gimp-help-en
+
+platform darwin {
+    set cxx_stdlib {}
+
+    if {[info exists configure.cxx_stdlib] &&
+        ${configure.cxx_stdlib} ne {} &&
+        [string match *clang* ${configure.cxx}]} {
+        set cxx_stdlib ${configure.cxx_stdlib}
+    } elseif {[string match *clang* ${configure.cxx}] &&
+              ${os.major} >= 13} {
+        set cxx_stdlib libc++
+    } else {
+        set cxx_stdlib libstdc++
+    }
+}
+
+patchfiles      patch-etc-gimprc.diff \
+                patch-plug-ins-twain-tw_mac.c.diff \
+                patch-revert-commit-7ef45be8902a4b7403d1d1736ca4f7c95b6449a8.diff
+
+platform darwin 9 {
+    post-patch {
+        reinplace "s|-export-symbols-regex.*||g" ${worksrcpath}/plug-ins/pygimp/Makefile.am
+        reinplace "s|-export-symbols-regex.*||g" ${worksrcpath}/plug-ins/pygimp/Makefile.in
+    }
+}
+
+compiler.blacklist-append {gcc-4.2 >= 5646}
+
 pre-configure {
-        ui_error "The GIMP 2.8 branch has been released and there is, as yet,  no new development release available."
-        ui_error "Consequently this port has been temporarily replaced by port 'gimp2'.  Please install that port instead."
-        return -code error
+    if {[file exists ${prefix}/lib/gtk-2.0/include/gdkconfig.h]} {
+        set gtk_not_quartz [catch {exec grep -q GDK_WINDOWING_QUARTZ ${prefix}/lib/gtk-2.0/include/gdkconfig.h}]
+        set gtk_not_x11 [catch {exec grep -q GDK_WINDOWING_X11 ${prefix}/lib/gtk-2.0/include/gdkconfig.h}]
+        if {[variant_isset quartz] && ${gtk_not_quartz}} {
+            error "+quartz variant selected, but gtk2+x11 is installed. Install gtk2+quartz."
+        } elseif {![variant_isset quartz] && ${gtk_not_x11}} {
+            error "+quartz variant is not selected, but gtk2+quartz is installed. Install gtk2+x11."
+        }
+    } else {
+            error "Cannot find gdkconfig.h"
+    }
 }
 
+configure.cmd   ./autogen.sh
+
+configure.args  --build=${configure.build_arch}-apple-${os.platform}${os.version} \
+                --enable-mp \
+                --with-pdbgen \
+                --with-x \
+                --x-includes=${prefix}/include \
+                --x-libraries=${prefix}/lib \
+                --disable-silent-rules \
+                --without-alsa \
+                --without-gvfs \
+                --without-gudev \
+                --without-webkit \
+                --without-mac-twain
+
+# --without-mac-twain:
+#     Leopard's 64bit Carbon is missing QuitApplicationEventLoop
+#     It doesn't build any more anyways:
+#         https://trac.macports.org/ticket/35168
+
+variant python26 conflicts no_python python27 description {Use python 2.6} {
+    configure.python          ${prefix}/bin/python2.6
+    depends_lib-append        port:py26-pygtk
+    set python_framework      ${frameworks_dir}/Python.framework/Versions/2.6
+    configure.pkg_config_path ${python_framework}/lib/pkgconfig
+    configure.env             PATH=${python_framework}/bin:$env(PATH)
+}
+
+variant python27 conflicts no_python python26 description {Use python 2.7} {
+    configure.python          ${prefix}/bin/python2.7
+    depends_lib-append        port:py27-pygtk
+    set python_framework      ${frameworks_dir}/Python.framework/Versions/2.7
+    configure.pkg_config_path ${python_framework}/lib/pkgconfig
+    configure.env             PATH=${python_framework}/bin:$env(PATH)
+}
+
+variant no_python description {Disable Python scripts and filters} {
+    configure.args-append   --disable-python
+}
+
+if {![variant_isset no_python] && ![variant_isset python26]} {
+    default_variants +python27
+}
+
+variant gvfs description {Enable GIO/gvfs support} {
+    depends_lib-append      port:gvfs
+    configure.args-delete   --without-gvfs
+}
+
+variant remote description {Enable building of obsolete gimp-remote helper app} {
+    configure.args-append   --enable-gimp-remote
+}
+
+variant debug description {Enable debugging} {
+    configure.args-append  --enable-debug
+}
+
+variant quartz {
+    depends_lib-delete    port:xorg-libXcursor \
+                          port:xorg-libXmu \
+                          port:xorg-libXext \
+                          port:xorg-libXfixes \
+                          port:xpm
+    depends_lib-append    port:gtk-osx-application
+    configure.args-delete --with-x \
+                          --x-includes=${prefix}/include \
+                          --x-libraries=${prefix}/lib
+    configure.args-append --without-x
+    configure.ldflags-append   -framework Carbon
+
+#
+# if variant is +quartz lcms plugin uses 32 bit only Carbon API
+#
+
+    if {${build_arch} eq "x86_64" || ${build_arch} eq "ppc64"} {
+        configure.args-append --without-lcms
+    }
+}
+
+#
+# set default variants
+#
+
+variant help_browser description {Enable Gimp help browser} {
+    configure.args-delete   --without-webkit
+
+    if {${cxx_stdlib} == "libstdc++"} {
+            depends_lib-append path:lib/pkgconfig/webkit-1.0.pc:webkit-gtk-2.0
+    } else {
+            depends_lib-append path:lib/pkgconfig/webkit-1.0.pc:webkit-gtk
+    }
+}
+
+default_variants +help_browser
+
+post-activate {
+    system "${prefix}/bin/gtk-update-icon-cache -f -t ${prefix}/share/icons/hicolor"
+    system "${prefix}/bin/update-desktop-database ${prefix}/share/applications"
+}
+
 livecheck.type  none

Added: trunk/dports/graphics/gimp2-devel/files/patch-etc-gimprc.diff
===================================================================
--- trunk/dports/graphics/gimp2-devel/files/patch-etc-gimprc.diff	                        (rev 0)
+++ trunk/dports/graphics/gimp2-devel/files/patch-etc-gimprc.diff	2013-12-10 18:02:36 UTC (rev 114581)
@@ -0,0 +1,11 @@
+--- etc/gimprc.orig	2012-04-02 16:28:33.000000000 -0700
++++ etc/gimprc	2012-07-10 08:55:00.000000000 -0700
+@@ -689,6 +689,8 @@
+ # 
+ # (dock-window-hint utility)
+ 
++(dock-window-hint utility)
++
+ # Sets the pixel format to use for mouse pointers.  Possible values are
+ # bitmap and pixbuf.
+ # 

Added: trunk/dports/graphics/gimp2-devel/files/patch-plug-ins-twain-tw_mac.c.diff
===================================================================
--- trunk/dports/graphics/gimp2-devel/files/patch-plug-ins-twain-tw_mac.c.diff	                        (rev 0)
+++ trunk/dports/graphics/gimp2-devel/files/patch-plug-ins-twain-tw_mac.c.diff	2013-12-10 18:02:36 UTC (rev 114581)
@@ -0,0 +1,15 @@
+--- plug-ins/twain/tw_mac.c.orig	2012-03-12 12:18:11.000000000 -0700
++++ plug-ins/twain/tw_mac.c	2012-07-10 08:57:29.000000000 -0700
+@@ -192,10 +192,12 @@
+ 
+   /* Voodoo magic fix inspired by java_swt launcher */
+   /* Without this the icon setting doesn't work about half the time. */
++#ifndef __LP64__
+   CGrafPtr p = BeginQDContextForApplicationDockTile();
+   EndQDContextForApplicationDockTile(p);
+ 
+   SetApplicationDockTileImage (icon);
++#endif
+ }
+ 
+ int

Added: trunk/dports/graphics/gimp2-devel/files/patch-revert-commit-7ef45be8902a4b7403d1d1736ca4f7c95b6449a8.diff
===================================================================
--- trunk/dports/graphics/gimp2-devel/files/patch-revert-commit-7ef45be8902a4b7403d1d1736ca4f7c95b6449a8.diff	                        (rev 0)
+++ trunk/dports/graphics/gimp2-devel/files/patch-revert-commit-7ef45be8902a4b7403d1d1736ca4f7c95b6449a8.diff	2013-12-10 18:02:36 UTC (rev 114581)
@@ -0,0 +1,49 @@
+--- app/core/gimp-user-install.c.orig	2013-12-06 12:09:34.000000000 -0800
++++ app/core/gimp-user-install.c	2013-12-06 12:10:57.000000000 -0800
+@@ -34,10 +34,6 @@
+ #include <unistd.h>
+ #endif
+ 
+-#ifdef PLATFORM_OSX
+-#include <AppKit/AppKit.h>
+-#endif
+-
+ #include <gio/gio.h>
+ #include <glib/gstdio.h>
+ 
+@@ -152,35 +148,6 @@
+ 
+   user_install_detect_old (install, gimp_directory ());
+ 
+-#ifdef PLATFORM_OSX
+-  /* The config path on OSX has for a very short time frame (2.8.2 only)
+-     been "~/Library/GIMP". It changed to "~/Library/Application Support"
+-     in 2.8.4 and was in the home folder (as was other UNIX) before. */
+-
+-  if (! install->old_dir)
+-    {
+-      gchar             *dir;
+-      NSAutoreleasePool *pool;
+-      NSArray           *path;
+-      NSString          *library_dir;
+-
+-      pool = [[NSAutoreleasePool alloc] init];
+-
+-      path = NSSearchPathForDirectoriesInDomains (NSLibraryDirectory,
+-                                                  NSUserDomainMask, YES);
+-      library_dir = [path objectAtIndex:0];
+-
+-      dir = g_build_filename ([library_dir UTF8String],
+-                              GIMPDIR, GIMP_USER_VERSION, NULL);
+-
+-      [pool drain];
+-
+-      user_install_detect_old (install, dir);
+-      g_free (dir);
+-    }
+-
+-#endif
+-
+   if (! install->old_dir)
+     {
+       /* if the default XDG-style config directory was not found, try
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20131210/cd2eb28f/attachment-0001.html>


More information about the macports-changes mailing list