# -*- Mode: Tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4 # $Id$ PortSystem 1.0 name fltk categories aqua devel license LGPL platforms macosx maintainers michaelld openmaintainer description Fast Light Tool Kit Version 1.3 long_description \ FLTK (pronounced fulltick) \ is a cross-platform C++ GUI toolkit for UNIX/Linux (X11), \ Microsoft Windows, and Mac OS X. \ FLTK provides modern GUI functionality without the bloat \ and supports 3D graphics via OpenGL and \ its built-in GLUT emulation. \ FLTK is designed to be small and modular enough to be \ statically linked, but works fine as a shared library. \ FLTK also includes an excellent UI builder called FLUID \ that can be used to create applications in minutes. homepage http://www.fltk.org/ livecheck.type regexm livecheck.url ${homepage} subport fltk-devel {} if {${subport} eq ${name}} { conflicts fltk-devel # NOTE: when this release is updated fix the octave port to use it # again on 10.11. version 1.3.3 master_sites http://fltk.org/pub/fltk/${version}/ worksrcdir ${name}-${version} distname ${worksrcdir}-source checksums rmd160 a1736ec7da1ff751153e09bc5b5136d2fa95c18b \ sha256 f8398d98d7221d40e77bc7b19e761adaf2f1ef8bb0c30eceb7beb4f2273d0d97 livecheck.regex "Stable Release.*?\n.*?VERSION=(\\d+(\\.\\d+)*)'" } else { long_description ${long_description} \ This port provides snapshot released of FLTK, updated weekly to monthly. conflicts fltk version 1.3.x-r12052 checksums rmd160 1238ec1346cb756a7db530859789973d4a68f9fc \ sha256 5ce6c0d4139f871912b750097262882c2e24e73a499e12ce8280f45dff1ece00 master_sites http://fltk.org/pub/fltk/snapshots/ distname fltk-${version} use_bzip2 yes livecheck.regex "Snapshots:.*\n.*v(1\\.3\\.x-r\\d+)" } depends_lib port:jpeg \ port:libpng \ port:zlib if {${subport} eq "fltk"} { patchfiles-append \ patch-src-Makefile.release.diff \ patch-fix_LP64.release.diff \ patch-fluid-Makefile.release.diff # the following patches are already integrated into the devel version patchfiles-append \ patch-src-Fl_JPEG_Image.cxx.diff \ patch-src_fl_line_style.cxx.diff } else { patchfiles-append \ patch-src-Makefile.devel.diff \ patch-fix_LP64.devel.diff \ patch-fluid-Makefile.devel.diff } post-patch { reinplace "s|/Applications|${applications_dir}/fltk|g" \ ${worksrcpath}/fluid/Makefile \ ${worksrcpath}/test/Makefile # Disable silent rules reinplace "/^\\.SILENT:$/d" ${worksrcpath}/makeinclude.in # tell fltk's make script to create config.sub, which is required # before configure will execute properly. This command actually # runs configure through once, to create the file; we then call # configure manually with the correct arguments, which overwrites # this (and other) files to be what we want. Make sure CC is set # correctly per "using the right compiler". While this port will # work correctly without this addition, doing this allows the port # to not error out on dev's systems set up to check whether the # right compiler is being used. system -W ${worksrcpath} "CC=${configure.cc} make config.sub" } pre-configure { configure.args-append \ --with-archflags="[get_canonical_archflags]" configure.cc_archflags configure.cxx_archflags configure.objc_archflags configure.objcxx_archflags configure.ld_archflags } configure.args --enable-shared \ --disable-localjpeg \ --disable-localzlib \ --disable-localpng configure.universal_args-delete --disable-dependency-tracking post-configure { reinplace -E {s|-arch [a-z0-9_]+||g} ${worksrcpath}/fltk-config } destroot.target install install-desktop