source: trunk/dports/science/hdf4/Portfile @ 108581

Last change on this file since 108581 was 108581, checked in by takeshi@…, 7 years ago

hdf4: revamped for 4.2.9. added gcc48 variant

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 4.1 KB
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:et:sw=4:ts=4:sts=4
2# $Id: Portfile 108581 2013-07-26 23:36:43Z takeshi@macports.org $
3
4PortSystem          1.0
5
6name                hdf4
7version             4.2.9
8platforms           darwin
9categories          science
10license             NCSA
11maintainers         takeshi
12
13description         file format for storing scientific data and utilities
14long_description    ${description}
15homepage            http://www.hdfgroup.org/products/hdf4/index.html
16master_sites        ftp://ftp.hdfgroup.org/HDF/prev-releases/HDF${version}/src/ \
17                    http://www.hdfgroup.org/ftp/HDF/prev-releases/HDF${version}/src/
18distname            hdf-${version}
19use_bzip2           yes
20checksums           md5     c268a703f334ee4987fa710a0de9b9fc \
21                    sha1    c2251642e29c7acada37d5e599e68d270088e56d \
22                    rmd160  2052a35912bfe0eaa7f21b14325ebf60786d1e02
23
24depends_lib         port:zlib port:jpeg
25
26configure.args      --disable-netcdf --disable-fortran \
27                    --with-jpeg=${prefix} --enable-shared \
28                    --without-szlib
29configure.cppflags-delete   -I${prefix}/include
30configure.ldflags-delete    -L${prefix}/lib
31
32post-configure {
33# remove -arch from h4cc to fix failure of h4cc -E with +universal
34    reinplace -E {s|-arch [a-z0-9_]+||g} ${worksrcpath}/hdf/util/h4cc
35}
36
37test.run            yes
38test.target         check
39
40post-destroot {
41    file mkdir ${destroot}${prefix}/share/doc/${name}
42    file copy ${worksrcpath}/hdf/util/testfiles ${destroot}${prefix}/share/doc/${name}/samples
43    foreach f {COPYING release_notes/HISTORY.txt release_notes/RELEASE.txt} {
44        file copy ${worksrcpath}/$f ${destroot}${prefix}/share/doc/${name}/
45    }
46    foreach f {bin/ncdump bin/ncgen lib/libudport.a                   \
47             include/netcdf.h include/netcdf.inc include/netcdf.f90 \
48             share/man/man1/ncgen.1 share/man/man1/ncdump.1} {
49        file delete ${destroot}${prefix}/$f
50    }
51}
52
53variant g95 conflicts gcc43 gcc44 gcc45 gcc46 gcc47 gcc48 universal description {build with g95} {
54    configure.args-delete   --disable-fortran --enable-shared
55    depends_build-append    port:g95
56    configure.f77           ${prefix}/bin/g95
57}
58
59variant gcc43 conflicts g95 gcc44 gcc45 gcc46 gcc47 gcc48 universal description {build with gfortran 4.3} {
60    configure.args-delete   --disable-fortran --enable-shared
61    depends_build-append    port:gcc43
62    configure.f77           ${prefix}/bin/gfortran-mp-4.3
63}
64
65variant gcc44 conflicts g95 gcc43 gcc45 gcc46 gcc47 gcc48 universal description {build with gfortran 4.4} {
66    configure.args-delete   --disable-fortran --enable-shared
67    depends_build-append    port:gcc44
68    configure.f77           ${prefix}/bin/gfortran-mp-4.4
69}
70
71variant gcc45 conflicts g95 gcc43 gcc44 gcc46 gcc47 gcc48 universal description {build with gfortran 4.5} {
72    configure.args-delete   --disable-fortran --enable-shared
73    depends_build-append    port:gcc45
74    configure.f77           ${prefix}/bin/gfortran-mp-4.5
75}
76
77variant gcc46 conflicts g95 gcc43 gcc44 gcc45 gcc47 gcc48 universal description {build with gfortran 4.6} {
78    configure.args-delete   --disable-fortran --enable-shared
79    depends_build-append    port:gcc46
80    configure.f77           ${prefix}/bin/gfortran-mp-4.6
81}
82
83variant gcc47 conflicts g95 gcc43 gcc44 gcc45 gcc46 gcc48 universal description {build with gfortran 4.7} {
84    configure.args-delete   --disable-fortran --enable-shared
85    depends_build-append    port:gcc47
86    configure.f77           ${prefix}/bin/gfortran-mp-4.7
87}
88
89variant gcc48 conflicts g95 gcc43 gcc44 gcc45 gcc46 gcc47 universal description {build with gfortran 4.8} {
90    configure.args-delete   --disable-fortran --enable-shared
91    depends_build-append    port:gcc48
92    configure.f77           ${prefix}/bin/gfortran-mp-4.8
93}
94
95variant szip description {build with szip} {
96    depends_lib-append      port:szip
97    configure.args-delete   --without-szlib
98    configure.args-append   --with-szlib=${prefix}
99}
100
101livecheck.type   regex
102livecheck.url    ${homepage}
103livecheck.regex  {Release of HDF is ([0-9]+\.[0-9]+\.[0-9]+)}
Note: See TracBrowser for help on using the repository browser.