# -*- 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 PortSystem 1.0 PortGroup compiler_blacklist_versions 1.0 name gimp2-devel conflicts gimp2 gimp3-devel set git_name gimp set git_commit 47a4d210ca27a1a5de6aa1e8a90e2158ad96b033 set git_date 20191108 version 2.10.15-${git_date} license GPL-3+ categories graphics maintainers {devans @dbevans} platforms darwin description The GNU Image Manipulation Program long_description 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. \ This is an unstable maintenance version leading to a future stable release. homepage http://www.gimp.org/ master_sites https://gitlab.gnome.org/GNOME/${git_name}/-/archive/${git_commit}/ distname ${git_name}-${git_commit} use_bzip2 yes checksums rmd160 f8c59674fc8c91c7630e27c82cf715ecc3724f0e \ sha256 9dcb5b2ae14ddf1d222c05571d95a609b69942adbe0e5c8d82eda967d6214869 \ size 82620110 set perl_version 5.28 depends_build port:pkgconfig \ port:appstream-glib \ port:autoconf \ port:automake \ port:libtool \ port:intltool \ port:gtk-doc \ port:perl${perl_version} depends_lib port:desktop-file-utils \ port:iso-codes \ port:babl-devel \ port:gegl-devel \ port:atk \ port:gdk-pixbuf2 \ port:glib-networking \ port:gtk2 \ port:fontconfig \ port:freetype \ port:tiff \ port:jpeg \ port:zlib \ port:bzip2 \ port:ghostscript \ port:libpng \ port:libmng \ port:openexr \ port:openjpeg \ port:gexiv2 \ port:aalib \ port:xpm \ port:librsvg \ port:poppler \ port:curl \ port:libwmf \ port:libmypaint \ port:mypaint-brushes \ port:lcms2 \ port:dbus-glib \ port:libxml2 \ port:libxslt \ port:xdg-utils \ port:xorg-libXcursor \ port:xorg-libXmu \ port:xorg-libXext \ port:xorg-libXfixes depends_run port:gimp-help-en # libgimpwidgets/gimpwidgetsmarshal.h can be referenced by a parallel # build before it is created use_parallel_build no # gcc-4.2 5493 and 5666.3_13: gimpcpuaccel.c:180: error: can't find a register in class 'BREG' while reloading 'asm' # redefinition of typedef is invalid in C [-Wtypedef-redefinition] (#50329) # as of version 2.10.0 requires a C++14 compatible compiler to configure compiler.cxx_standard 2014 compiler.blacklist-append *gcc-3.* *gcc-4.* {clang < 700} patchfiles patch-configure.ac.diff \ patch-etc-gimprc.in.diff \ patch-quartz-32bit.diff if {${os.platform} eq "darwin" && ${os.major} < 11} { # avoid Cursor type conflict between X11 and Quickdraw # error: typedef redefinition with different types ('struct Cursor' vs 'XID' (aka 'unsigned long')) # not an issue on 10.7 and later patchfiles-append \ patch-x11-widgets-fix.diff } pre-configure { 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.perl ${prefix}/bin/perl${perl_version} configure.env CC_FOR_BUILD=${configure.cc} if {[vercmp $xcodeversion 4.3] < 0 && [string match "*macports*" ${configure.compiler}]} { # Xcode 4.2 fails with load commands in the newer toolchain depends_build-append port:cctools configure.env-append \ AR=${prefix}/bin/ar \ RANLIB=${prefix}/bin/ranlib } configure.cmd ./autogen.sh configure.args --build=${configure.build_arch}-apple-${os.platform}${os.version} \ --enable-mp \ --with-bug-report-url=https://guide.macports.org/#project.tickets \ --with-pdbgen \ --with-x \ --x-includes=${prefix}/include \ --x-libraries=${prefix}/lib \ --disable-silent-rules \ --disable-python \ --without-alsa \ --without-gudev \ --without-libheif \ --without-webkit \ ac_cv_path_INTLTOOL_PERL=${configure.perl} # keep empty GIMP font directory # silences warning message on startup: # GIMP-Message: Some fonts failed to load: # - /opt/local/share/gimp/2.0/fonts/ destroot.keepdirs ${destroot}${prefix}/share/gimp/2.0/fonts variant python27 description {Build with python plugin support using python 2.7} { configure.args-delete --disable-python 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-append PATH=${python_framework}/bin:$env(PATH) } 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-gtk2 configure.args-delete --with-x \ --x-includes=${prefix}/include \ --x-libraries=${prefix}/lib configure.args-append --without-x } # # set default variants # default_variants +python27 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