source: trunk/dports/python/py-nio/Portfile

Last change on this file was 147494, checked in by mmoll@…, 16 months ago

hdf5: update to version 1.10.0, bump revision of ports that depend on hdf5 and need to be rebuilt. closes #51062

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.6 KB
Line 
1# -*- 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
2# $Id: Portfile 147494 2016-04-05 20:52:07Z ryandesign@macports.org $
3
4PortSystem          1.0
5PortGroup python    1.0
6PortGroup compilers 1.0
7
8name                py-nio
9version             1.3.0b1
10revision            5
11categories-append   science
12platforms           darwin
13license             PyNIO
14maintainers         petr openmaintainer
15
16description         Python I/O library for scientific data formats
17long_description \
18    PyNIO is a Python package that allows read and/or write access to \
19    a variety of data formats using an interface modeled on netCDF. \
20    PyNIO is composed of a C library called libnio along with a Python module \
21    based on and with an interface similar to the Scientific.IO.NetCDF module \
22    written by Konrad Hinsen.
23
24homepage            http://www.pyngl.ucar.edu/Nio.shtml
25distname            PyNIO-${version}
26
27master_sites        "https://www.earthsystemgrid.org/download/fileDownload.htm?logicalFileId=e328ec94-306e-11df-8e89-00c0f03d5b7c&dummy="
28
29checksums           md5     c881b552cf914549f46d65a61f2d8cb0 \
30                    sha1    288b70d83828e1cb99d3d7c61bd32b5c406c8b1a \
31                    rmd160  b33d00041783ba259ae95f772c7fde0cf37d7303
32
33python.versions     26 27
34
35if {${name} ne ${subport}} {
36    depends_lib-append  port:szip port:zlib \
37                        port:jpeg port:jasper port:libpng \
38                        port:hdf4 port:hdfeos port:hdf5 port:netcdf \
39                        port:ncarg \
40                        port:py${python.version}-numpy
41
42    # ncarg is not universal, thus py-nio is neither
43    universal_variant   no
44
45    patch {
46        reinplace "s|__init__(obj)|__init__()|" ${worksrcpath}/Nio.py
47    }
48
49    build.env-append    HAS_GRIB2=1  GRIB2_PREFIX=${prefix} \
50                        HAS_HDFEOS=1 HDFEOS_PREFIX=${prefix} \
51                        HAS_NETCDF4=1 NETCDF4_PREFIX=${prefix} \
52                        NCARG_ROOT=${prefix} CC=${configure.cc}
53
54    destroot.env        NCARG_ROOT=${prefix}
55
56    compilers.choose    fc f77 f90
57    compilers.setup     require_fortran -dragonegg
58
59    if {[gcc_variant_isset]} {
60        build.env-append    F2CLIBS=gfortran \
61                            F2CLIBS_PREFIX=${prefix}/lib/[gcc_variant_name]
62    } else {
63        # g95
64        configure.fflags-append -fno-second-underscore
65
66        build.env-append    F2CLIBS=f95 \
67                            F2CLIBS_PREFIX=${prefix}/lib/
68    }
69
70   livecheck.type   none
71} else {
72    livecheck.type  regex
73    livecheck.url   http://www.pyngl.ucar.edu/Download/
74    livecheck.regex {of PyNIO is ([0-9]\.[0-9]\.[0-9]+)}
75}
Note: See TracBrowser for help on using the repository browser.