[106227] trunk/dports/math/gnudatalanguage

takeshi at macports.org takeshi at macports.org
Sun May 19 14:14:06 PDT 2013


Revision: 106227
          https://trac.macports.org/changeset/106227
Author:   takeshi at macports.org
Date:     2013-05-19 14:14:06 -0700 (Sun, 19 May 2013)
Log Message:
-----------
gnudatalanguage: revamped for 0.9.3 using cmake. fixed a problem linking ImageMagick libraries. added python26 python27 variants. closing #39067 and #39131.

Modified Paths:
--------------
    trunk/dports/math/gnudatalanguage/Portfile

Removed Paths:
-------------
    trunk/dports/math/gnudatalanguage/files/

Modified: trunk/dports/math/gnudatalanguage/Portfile
===================================================================
--- trunk/dports/math/gnudatalanguage/Portfile	2013-05-19 20:49:58 UTC (rev 106226)
+++ trunk/dports/math/gnudatalanguage/Portfile	2013-05-19 21:14:06 UTC (rev 106227)
@@ -2,10 +2,10 @@
 # $Id$
 
 PortSystem                  1.0
+PortGroup                   cmake 1.0
 
 name                        gnudatalanguage
-version                     0.9.2
-revision                    4
+version                     0.9.3
 epoch                       1
 categories                  math science
 maintainers                 takeshi
@@ -24,13 +24,12 @@
 set gshhssrc        gshhs_${srcversion}_src.zip
 set gshhsdata       gshhs_${dataversion}.zip
 distfiles           ${gdlsrc}:gdl
-worksrcdir                  gdl-${version}
-patchfiles          patch-configure.in.diff
+worksrcdir          gdl-${version}
 
 checksums           ${gdlsrc} \
-                    md5      7178304e6737a8dca910d2c1061ff63c \
-                    sha1     0d6fe86e2971637310c6298379616b02f773e956 \
-                    rmd160   6913b358de01550256ad38c920cc461e8ef94512
+                    md5     f71f869e6c9aa99bbfdb22ecd5c88914 \
+                    sha1    a4558643645cc414041d588e375669810780a69a \
+                    rmd160  a6eed21d1a328156b794ba7a6a90e1942fa38fd7
 
 depends_lib                 port:zlib \
                             port:gsl \
@@ -51,91 +50,155 @@
                             port:pslib
 
 post-patch {
-   # add the CMSVLIB installation path
-   reinplace "s|dicom\"|dicom:${prefix}/share/cmsvlib\"|" ${worksrcpath}/src/gdl.cpp
    # Avoid using heimdal's broken fnmatch.h
    reinplace "s|<\\(fnmatch\.h\\)>|\"/usr/include/\\1\"|" ${worksrcpath}/src/file.cpp
-   reinplace "s|/usr/X11R6/lib64|${prefix}/lib|" ${worksrcpath}/src/Makefile.am
-   reinplace "s| -L/usr/X11R6/lib||" ${worksrcpath}/src/Makefile.am
    reinplace "s|\.\./gshhs|gshhs|" ${worksrcpath}/src/gshhs.cpp
 }
 
-use_autoconf                yes
-if {${configure.compiler}=="clang"} {
-    configure.compiler llvm-gcc-4.2
-}
-if {${os.major}>=9 && ${configure.compiler}=="gcc-4.0"} {
-    configure.compiler gcc-4.2
-}
-configure.env-append        LIBS=\"-lpng -lopenjpeg\"
-configure.args              --with-plplotdir=${prefix} \
-                            --with-ncursesdir=${prefix} \
-                            --with-readlinedir=${prefix} \
-                            --with-gsldir=${prefix} \
-                            --with-netcdf=${prefix} \
-                            --with-hdf=${prefix} \
-                            --with-hdf5=${prefix} \
-                            --with-grib=${prefix} \
-                            --with-Magick=${prefix} \
-                            --without-wxWidgets \
-                            --disable-dependency-tracking \
-                            --x-includes=${prefix}/include \
-                            --x-libraries=${prefix}/lib \
-                            --with-udunits=${prefix} \
-                            --with-fftw=${prefix} \
-                            --with-libproj4=${prefix} \
-                            --with-pslib=${prefix} \
-                            --with-python=no \
-                            --with-openmp=no
-configure.cppflags-delete   -I${prefix}/include
-configure.cppflags-append   -I${prefix}/include/udunits2 -I${prefix}/include
+# Compiliation of gdl.cpp stalls with clang
+compiler.blacklist      clang
 
+configure.args-append   -DFFTW=ON \
+                        -DFFTWDIR=${prefix} \
+                        -DGRIB=ON \
+                        -DGRIBDIR=${prefix} \
+                        -DGSHHS=OFF \
+                        -DGSLDIR=${prefix} \
+                        -DHDF5=ON \
+                        -DHDF5DIR=${prefix} \
+                        -DHDF=ON \
+                        -DHDFDIR=${prefix} \
+                        -DJASPERDIR=${prefix} \
+                        -DJPEGDIR=${prefix} \
+                        -DLIBPROJ4=ON \
+                        -DLIBPROJ4DIR=${prefix} \
+                        -DMAGICK=ON \
+                        -DMAGICKDIR=${prefix} \
+                        -DImageMagick_INCLUDE_DIRS=${prefix}/include/ImageMagick-6 \
+                        -DImageMagick_Magick++_LIBRARY=${prefix}/lib/libMagick++-6.Q16.dylib \
+                        -DImageMagick_MagickCore_LIBRARY=${prefix}/lib/libMagickCore-6.Q16.dylib \
+                        -DImageMagick_MagickWand_LIBRARY=${prefix}/lib/libMagickWand-6.Q16.dylib \
+                        -DMPICH=OFF \
+                        -DNCURSESDIR=${prefix} \
+                        -DNETCDF=ON \
+                        -DNETCDFDIR=${prefix} \
+                        -DOPENMP=OFF \
+                        -DPLPLOTDIR=${prefix} \
+                        -DPSLIB=ON \
+                        -DPSLIBDIR=${prefix} \
+                        -DPYTHON=OFF \
+                        -DPYTHON_MODULE=OFF \
+                        -DREADLINE=ON \
+                        -DREADLINEDIR=${prefix} \
+                        -DUDUNITS=ON \
+                        -DUDUNITSDIR=${prefix} \
+                        -DUDUNITS_INCLUDE_DIR=${prefix}/include/udunits2 \
+                        -DWXWIDGETS=OFF \
+                        -DX11DIR=${prefix} \
+                        -DZLIBDIR=${prefix} \
+                        -DCMAKE_OSX_DEPLOYMENT_TARGET=""
+
 test.run                    yes
 test.target                 check
 
-destroot.target             install-strip
-
 use_parallel_build          yes
 
 post-destroot {
-   xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name}
-   xinstall -m 644 -W ${worksrcpath} AUTHORS COPYING Doxyfile ChangeLog HACKING NEWS MAP_INSTALL PYTHON.txt README TODO ${destroot}${prefix}/share/doc/${name}
-   xinstall -m 755 -d ${destroot}${prefix}/share/${name}
-   xinstall -m 755 -d ${destroot}${prefix}/share/${name}/py
-   eval xinstall -m 644 [glob ${worksrcpath}/src/py/*.py] ${destroot}${prefix}/share/${name}/py
-   xinstall -m 755 -d ${destroot}${prefix}/share/${name}/testsuite
-   eval xinstall -m 644 [glob ${worksrcpath}/testsuite/*.pro] \
-      ${destroot}${prefix}/share/${name}/testsuite
+    xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name}
+    foreach f {AUTHORS README} {
+        file rename ${destroot}${prefix}/share/${name}/${f} \
+            ${destroot}${prefix}/share/doc/${name}/
+    }
+    xinstall -m 644 -W ${worksrcpath} COPYING ChangeLog HACKING NEWS MAP_INSTALL TODO \
+        ${destroot}${prefix}/share/doc/${name}
+    file copy ${worksrcpath}/testsuite ${destroot}${prefix}/share/${name}/
+    if {[variant_isset python25] || [variant_isset python26] || [variant_isset python27]} {
+        xinstall -m 644 ${worksrcpath}/PYTHON.txt ${destroot}${prefix}/share/doc/${name}
+        file copy ${worksrcpath}/src/py ${destroot}${prefix}/share/${name}/
+    }
+    if {[variant_isset gshhs]} {
+        xinstall -d ${destroot}${prefix}/share/gnudatalanguage/gshhs
+        foreach f [glob ${workpath}/gshhs/*.b] {
+            xinstall -m 644 ${f} ${destroot}${prefix}/share/gnudatalanguage/gshhs
+        }
+    }
 }
 
 variant mpich description {build with support for MPICH (experimental)} {
     depends_lib-append      port:mpich
-    configure.args-append   --with-mpich=${prefix} 
+    configure.args-delete   -DMPICH=OFF
+    configure.args-append   -DMPICH=ON \
+                            -DMPICHDIR=${prefix}/lib/mpich
 } 
 
 variant wxWidgets description {build with support for widgets (experimental, not functional yet)} {
     supported_archs         ppc i386
     depends_lib-append      port:wxWidgets
-    configure.args-delete   --without-wxWidgets
-    configure.args-append   --with-wxWidgets=${prefix} 
+    configure.args-delete   -DWXWIDGETS=OFF \
+    configure.args-append   -DWXWIDGETS=ON \
+                            -DWXWIDGETSDIR=${prefix}
     # http://wiki.finkproject.org/index.php/Fink:Packaging:Preparing_for_10.5#OpenGL_Bug
     #configure.env-append    LDFLAGS=\"-Wl,-dylib_file,/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib:/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib\"
 }
 
-variant python description {build with support for calling Python (2.6) from GDL (using numpy)} {
-    depends_lib-append      port:python26 \
-                            port:py26-numpy 
-    configure.args-append   --with-python=${prefix}/Library/Frameworks/Python.framework/Versions/2.6 \
-                            --enable-python_version=2.6
+if {[variant_isset python25] || [variant_isset python26] || [variant_isset python27]} {
+    configure.args-delete   -DPYTHON=OFF
+    configure.args-append   -DPYTHON=ON
 }
 
-variant openmp description {enabling of the support for multi-threaded matrix operations using OpenMP} {
-    configure.args-delete   --with-openmp=no
-    configure.args-append   --with-openmp=yes
+variant python requires python26 description {Legacy compatibility variant} {}
+
+variant python25 conflicts python26 python27 description {build with support for calling Python (2.5) from GDL (using numpy)} {
+    depends_lib-append      port:py25-numpy 
+    configure.args-append   -DPYTHONDIR=${frameworks_dir}/Python.framework/Versions/2.5 \
+                            -DPYTHONVERSION=2.5
+}
+
+variant python26 conflicts python25 python27 description {build with support for calling Python (2.6) from GDL (using numpy)} {
+    depends_lib-append      port:py26-numpy 
+    configure.args-append   -DPYTHONDIR=${frameworks_dir}/Python.framework/Versions/2.6 \
+                            -DPYTHONVERSION=2.6
+}
+
+variant python27 conflicts python25 python26 description {build with support for calling Python (2.7) from GDL (using numpy)} {
+    depends_lib-append      port:py27-numpy 
+    configure.args-append   -DPYTHONDIR=${frameworks_dir}/Python.framework/Versions/2.7 \
+                            -DPYTHONVERSION=2.7
+}
+
+if {[variant_isset gcc44] || [variant_isset gcc45] || [variant_isset gcc46] || [variant_isset gcc47]} {
+    configure.args-delete   -DOPENMP=OFF
+    configure.args-append   -DOPENMP=ON
+}
+
+variant openmp requires gcc44 description {Legacy compatibility variant} {}
+
+variant gcc44 conflicts gcc45 gcc46 gcc47 description {enabling of the support for OpenMP with gcc44} {
     configure.compiler      macports-gcc-4.4
-    depends_build-append    port:gcc44
+    depends_lib-append    port:gcc44
+# Detecting CXX compiler ABI info fails without this
+    configure.args-append   -D
 }
 
+variant gcc45 conflicts gcc44 gcc46 gcc47 description {enabling of the support for OpenMP with gcc45} {
+    configure.compiler      macports-gcc-4.5
+    depends_lib-append    port:gcc45
+# Detecting CXX compiler ABI info fails without this
+    configure.args-append   -D
+}
+
+variant gcc46 conflicts gcc44 gcc45 gcc47 description {enabling of the support for OpenMP with gcc46} {
+    configure.compiler      macports-gcc-4.6
+    depends_lib-append    port:gcc46
+# Detecting CXX compiler ABI info fails without this
+    configure.args-append   -D
+}
+
+variant gcc47 conflicts gcc44 gcc45 gcc46 description {enabling of the support for OpenMP with gcc47} {
+    configure.compiler      macports-gcc-4.7
+    depends_lib-append    port:gcc47
+}
+
 variant gshhs description {build with support for GSHHS} {
     distfiles-append        ${gshhssrc}:gshhs \
                             ${gshhsdata}:gshhs
@@ -154,14 +217,9 @@
                 unzip ${distpath}/${gshhssrc} gshhs/gshhs.h; \
                 unzip ${distpath}/${gshhsdata}"
     }
-    configure.args-append   --with-gshhs=${workpath}/gshhs
-    configure.cppflags-append   -I${workpath}/gshhs
-    post-destroot {
-        xinstall -d ${destroot}${prefix}/share/gnudatalanguage/gshhs
-        foreach f [glob ${workpath}/gshhs/*.b] {
-            xinstall -m 644 ${f} ${destroot}${prefix}/share/gnudatalanguage/gshhs
-        }
-    }
+    configure.args-delete   -DGSHHS=OFF
+    configure.args-append   -DGSHHS=ON \
+                            -DGSHHSDIR=${workpath}/gshhs
 }
 
 livecheck.regex             /gdl-(\[0-9.\]+)${extract.suffix}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20130519/7a6e0e0c/attachment.html>


More information about the macports-changes mailing list