Ticket #34066: Portfile.diff

File Portfile.diff, 4.0 KB (added by florian@…, 12 years ago)

Portfile patch

  • Portfile

    old new  
    55
    66name                gmt4
    77version             4.5.8
     8revision            1
    89categories          science
    910platforms           darwin
    10 maintainers         takeshi
    11 license             LGPL-3
    12 description         the generic mapping tools
     11maintainers         eprofs.de:florian \
     12                    takeshi
     13license             GPL-2
     14description         The Generic Mapping Tools
    1315long_description GMT is an open source collection of ~65 tools  \
    1416    for manipulating geographic and Cartesian data sets and     \
    1517    producing Encapsulated PostScript File (EPS) illustrations  \
     
    2729                    ftp://mirror.geosci.usyd.edu.au/pub/gmt \
    2830                    ftp://gmt.mirror.ac.za/pub/gmt
    2931use_bzip2           yes
    30 set gshhsversion    2.2.0
    31 set gmtsrc          gmt-${version}.tar.bz2
    32 set gshhs           gshhs-${gshhsversion}.tar.bz2
    33 distfiles           ${gmtsrc} ${gshhs}
    34 checksums           ${gmtsrc} \
     32set nameprefix      gmt
     33distname            ${nameprefix}-${version}
     34set dfile_gmt_gpl   ${distname}${extract.suffix}
     35set dfile_gmt_nogpl ${nameprefix}-${version}-non-gpl${extract.suffix}
     36distfiles           ${dfile_gmt_gpl} \
     37                    ${dfile_gmt_nogpl}
     38patchfiles          patch-bugfixes-r9794.diff \
     39                    patch-bugfixes-r9816.diff \
     40                    patch-gmt_shore_c.diff
     41
     42checksums           ${dfile_gmt_gpl} \
    3543                    md5     8a3fa928bcb8a82ebaed68d62ba8f1ba \
    3644                    sha1    823783c1abc9a7e0493c35661e516d4f607fff17 \
    3745                    rmd160  faa58f8c35a4e00f5a9515066b90e08a940cb0d6 \
    38                     ${gshhs} \
    39                     md5     db98bff37adc0d51fdf0ffa3834d45ad \
    40                     sha1    786d58b9a335d3bacb37f40f21ee3bfbb424cd10 \
    41                     rmd160  aa744b2fdcdf849cc5c4abce97f1d29f4cdc20a4
     46                    ${dfile_gmt_nogpl} \
     47                    md5     b929d3287cf7bb67f52bc29b6903b1b4 \
     48                    sha1    d383d480d46229ba142d64c55a4ede4fb14f0196 \
     49                    rmd160  e420fa50d388227eb4147ef3a363459c8720408f
    4250
    4351worksrcdir          GMT${version}
    4452
    45 depends_lib         port:netcdf
     53depends_lib         port:netcdf \
     54                    port:gshhg-gmt-nc4
    4655
    4756destroot.target     install-all
    4857use_parallel_build  no
    4958universal_variant   no
    50 
    51 post-extract {
    52     # move GSHHS coastlines to worksrcpath
    53     system "mv ${workpath}/share/coast ${worksrcpath}/share && rmdir ${workpath}/share"
    54     system "mv ${workpath}/{LICENSE.TXT,README.TXT} ${worksrcpath}/share/coast"
    55 }
     59default_variants    +gdal
    5660
    5761configure.pre_args          --prefix=${prefix}/lib/${name}
    5862configure.args              --datarootdir=${prefix}/share/${name} \
     
    6771configure.ldflags-delete    -L${prefix}/lib
    6872
    6973post-destroot {
     74    ln -s ../lib/${name}/bin/GMT ${destroot}${prefix}/bin/${name}
     75    ln -s ../lib/${name}/bin/GMT ${destroot}${prefix}/bin/${nameprefix}
    7076    ln -s ../doc/${name} ${destroot}${prefix}/share/${name}/doc
    7177    ln -s ../../share/doc/${name}/man ${destroot}${prefix}/lib/${name}/man
    7278    ln -s ../../share/${name}/include ${destroot}${prefix}/lib/${name}/include
    7379    ln -s ../../share/${name} ${destroot}${prefix}/lib/${name}/share
     80    # add location of files from port gshhg-gmt-nc4 to coastline.conf:
     81    system "echo ${prefix}/share/gshhg-gmt-nc4 \
     82        > ${destroot}${prefix}/share/${name}/conf/coastline.conf"
    7483}
    7584
    7685variant octave description {compiles Octave interface} {
     
    8796    configure.args-append   --enable-triangle
    8897}
    8998
     99variant xgrid description {enable xGridEdit} {
     100    depends_lib-append      lib:libXaw:xorg-libXaw
     101    configure.args-append   --enable-xgrid
     102}
     103
    90104livecheck.type      regex
    91 livecheck.url       http://gmt.soest.hawaii.edu/gmt/gmt_home.html
    92 livecheck.regex     {Current version is [^0-9 ]*([0-9]+\.[0-9]+\.[0-9]+)}
     105livecheck.url       ${homepage}/gmt/gmt_home.html
     106livecheck.regex     {Current version[^0-9]*([0-9]+\.[0-9]+\.[0-9]+)}