[94819] trunk/dports/science/wgrib2/Portfile
takeshi at macports.org
takeshi at macports.org
Sat Jun 30 06:46:11 PDT 2012
Revision: 94819
https://trac.macports.org/changeset/94819
Author: takeshi at macports.org
Date: 2012-06-30 06:46:09 -0700 (Sat, 30 Jun 2012)
Log Message:
-----------
wgrib2: revamped for 1.9.6a. added gcc46 and gcc47 variants
Modified Paths:
--------------
trunk/dports/science/wgrib2/Portfile
Modified: trunk/dports/science/wgrib2/Portfile
===================================================================
--- trunk/dports/science/wgrib2/Portfile 2012-06-30 13:07:16 UTC (rev 94818)
+++ trunk/dports/science/wgrib2/Portfile 2012-06-30 13:46:09 UTC (rev 94819)
@@ -4,8 +4,7 @@
PortSystem 1.0
name wgrib2
-version 1.9.3a
-revision 2
+version 1.9.6a
platforms darwin
maintainers takeshi
categories science
@@ -15,10 +14,11 @@
distname ${name}_nolib.tgz.v${version}
extract.suffix
set version_g2clib 1.2.1
+set iplib iplib.2012
worksrcdir grib2/g2clib-${version_g2clib}
-checksums md5 6e9b8f6611ee50908497cb89ca1f2387 \
- sha1 a9cd93a6d7b35267692f7f17322e4413b5940696 \
- rmd160 0cfeb2e5123bc81531f4fffea55252b797def83b
+checksums md5 c9d383552210070c5df3115a806c0f66 \
+ sha1 7ce6f34677b73d32f1504f86fac31184c6c611e9 \
+ rmd160 e7627292152c74251e684d2529adbe382a8c138e
homepage http://www.cpc.noaa.gov/products/wesley/wgrib2/
long_description \
wgrib2 is a swiss army knife for grib2 files. \
@@ -60,53 +60,83 @@
post-build {
system "ranlib ${worksrcpath}/libgrib2c.a"
if {[variant_isset g95]} {
- system "cd ${workpath}/grib2/iplib; \
+ system "cd ${workpath}/grib2/${iplib}; \
make \
- F90=${prefix}/bin/g95;
+ FC=${prefix}/bin/g95 \
FFLAGS=${configure.fflags}"
set fsymbol DEFS=-DG95
- set flibs "-L../iplib -lipolate -lf95"
+ set flibs "-L../${iplib} -lipolate -lf95"
} elseif {[variant_isset gcc44]} {
- system "cd ${workpath}/grib2/iplib; \
+ system "cd ${workpath}/grib2/${iplib}; \
make \
- F90=${prefix}/bin/gfortran-mp-4.4;
+ FC=${prefix}/bin/gfortran-mp-4.4 \
FFLAGS=${configure.fflags}"
set fsymbol DEFS=-DGFORTRAN
- set flibs "-L../iplib -lipolate -L${prefix}/lib/gcc45 -lgfortran"
+ set flibs "-L../${iplib} -lipolate -L${prefix}/lib/gcc44 -lgfortran"
} elseif {[variant_isset gcc45]} {
- system "cd ${workpath}/grib2/iplib; \
+ system "cd ${workpath}/grib2/${iplib}; \
make \
- F90=${prefix}/bin/gfortran-mp-4.5;
+ FC=${prefix}/bin/gfortran-mp-4.5 \
FFLAGS=${configure.fflags}"
set fsymbol DEFS=-DGFORTRAN
- set flibs "-L../iplib -lipolate -L${prefix}/lib/gcc45 -lgfortran"
+ set flibs "-L../${iplib} -lipolate -L${prefix}/lib/gcc45 -lgfortran"
+ } elseif {[variant_isset gcc46]} {
+ system "cd ${workpath}/grib2/${iplib}; \
+ make \
+ FC=${prefix}/bin/gfortran-mp-4.6 \
+ FFLAGS=${configure.fflags}"
+ set fsymbol DEFS=-DGFORTRAN
+ set flibs "-L../${iplib} -lipolate -L${prefix}/lib/gcc46 -lgfortran"
+ } elseif {[variant_isset gcc47]} {
+ system "cd ${workpath}/grib2/${iplib}; \
+ make \
+ FC=${prefix}/bin/gfortran-mp-4.7 \
+ FFLAGS=${configure.fflags}"
+ set fsymbol DEFS=-DGFORTRAN
+ set flibs "-L../${iplib} -lipolate -L${prefix}/lib/gcc47 -lgfortran"
} else {
set fsymbol ""
set flibs ""
}
- system "cd ${workpath}/grib2/${name}; \
+ system "cd ${workpath}/grib2; \
+ tar zxvf gctpc20.tar.Z; \
+ cd ${workpath}/grib2/gctpc/source; \
+ make -f ${workpath}/grib2/makefile.gctpc \
+ CC=\"${configure.cc}\" \
+ CPPFLAGS=\"${cppflags}\" \
+ CFLAGS=\"${cflags}\" \
+ LDFLAGS=\"-L${prefix}/lib ${ldflags}\"; \
+ cd ${workpath}/grib2/${name}; \
make -f makefile ${name} \
CC=\"${configure.cc}\" \
${fsymbol} \
- CFLAGS=\"-I../g2clib-${version_g2clib} -I${prefix}/include ${cppflags} ${cflags}\" \
- LDFLAGS=\"-L../g2clib-${version_g2clib} -L${prefix}/lib ${ldflags} \
- -lgrib2c -ljasper -lpng -lnetcdf -lhdf5_hl -lhdf5 -lz -lcurl -lidn -lssl -lcrypto ${flibs}\" "
+ CFLAGS=\"-I../g2clib-${version_g2clib} -I../gctpc/source ${cppflags} ${cflags}\" \
+ LDFLAGS=\"-L../g2clib-${version_g2clib} -L../gctpc/source ${ldflags} \
+ -lgeo -lgrib2c -ljasper -lpng -lnetcdf -lhdf5_hl -lhdf5 -lz -lcurl -lidn -lssl -lcrypto ${flibs}\" "
}
destroot {
- xinstall -m 755 ${worksrcpath}/grib2.h ${destroot}${prefix}/include
+ xinstall -m 644 ${worksrcpath}/grib2.h ${destroot}${prefix}/include
xinstall -m 755 ${worksrcpath}/libgrib2c.a ${destroot}${prefix}/lib
xinstall -m 755 ${worksrcpath}/../${name}/${name} ${destroot}${prefix}/bin
}
-variant g95 conflicts gcc44 gcc45 description {build iplib with g95 (alpha)} {
+variant g95 conflicts gcc44 gcc45 gcc46 gcc47 description {build iplib with g95 (alpha)} {
depends_build-append port:g95
}
-variant gcc44 conflicts g95 gcc45 description {build iplib with gcc44 (alpha)} {
+variant gcc44 conflicts g95 gcc45 gcc46 gcc47 description {build iplib with gcc44 (alpha)} {
depends_build-append port:gcc44
}
-variant gcc45 conflicts g95 gcc44 description {build iplib with gcc45 (alpha)} {
+variant gcc45 conflicts g95 gcc44 gcc46 gcc47 description {build iplib with gcc45 (alpha)} {
depends_build-append port:gcc45
}
+
+variant gcc46 conflicts g95 gcc44 gcc45 gcc47 description {build iplib with gcc45 (alpha)} {
+ depends_build-append port:gcc46
+}
+
+variant gcc47 conflicts g95 gcc44 gcc45 gcc46 description {build iplib with gcc45 (alpha)} {
+ depends_build-append port:gcc47
+}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20120630/5b6f25a5/attachment.html>
More information about the macports-changes
mailing list