[80345] trunk/dports/science/emos/Portfile
takeshi at macports.org
takeshi at macports.org
Sun Jul 10 01:04:17 PDT 2011
Revision: 80345
http://trac.macports.org/changeset/80345
Author: takeshi at macports.org
Date: 2011-07-10 01:04:15 -0700 (Sun, 10 Jul 2011)
Log Message:
-----------
emos: updated for 000382
Modified Paths:
--------------
trunk/dports/science/emos/Portfile
Modified: trunk/dports/science/emos/Portfile
===================================================================
--- trunk/dports/science/emos/Portfile 2011-07-10 06:02:24 UTC (rev 80344)
+++ trunk/dports/science/emos/Portfile 2011-07-10 08:04:15 UTC (rev 80345)
@@ -4,8 +4,7 @@
PortSystem 1.0
name emos
-version 000371
-revision 1
+version 000382
platforms darwin
maintainers takeshi
license LGPL
@@ -14,23 +13,21 @@
homepage http://www.ecmwf.int/products/data/software/interpolation.html
master_sites http://www.ecmwf.int/products/data/software/download/software_files/
distname ${name}_${version}
-checksums md5 b09e27923b256e73ac90467a333a508c \
- sha1 75debc150de3f010aec7eace6a65aad9986321da \
- rmd160 4853e460ca6d0257a6e0e9c1b0f845bf95b0b846
+checksums md5 cfca587da4dda8b615dfdc3d0fdac080 \
+ sha1 450bd27956a7496740a6ef4349f44e015d6525fa \
+ rmd160 892cf38b1d207caea53e495c9f84c94bae989613
long_description \
The Interpolation library (EMOSLIB) includes Interpolation software \
and GRIB, BUFR, CREX encoding/decoding routines.
+depends_build port:grib_api
+
post-patch {
reinplace "s:^void \\*memcpy://void *memcpy:" ${worksrcpath}/gribex/gdecode.h
reinplace "s: | O_LARGEFILE::" ${worksrcpath}/interpolation/sharedlib.c
reinplace "s:`cat .list/bufrtables`:bufrtables/*.TXT:" ${worksrcpath}/install
+ reinplace "s:xf:xpf:" ${worksrcpath}/install
}
-#pre-configure {
-# if [variant_isset g95] {
-# reinplace "s:GBITMAP, ::" ${worksrcpath}/gribex/gribex.F
-# }
-#}
if {${os.endian}=="little"} {
set fendian -DLITTLE_ENDIAN
@@ -52,16 +49,17 @@
close $f
file copy -force ${worksrcpath}/Makefile.in ${worksrcpath}/Makefile
reinplace "s:reals:R64:" ${worksrcpath}/Makefile
- foreach d {gribex pbio bufrdc bufrtables crexdc interpolation fft} {
+ reinplace "s:glue:grib_api_merging:" ${worksrcpath}/Makefile
+ foreach d {gribex pbio bufrdc bufrtables crexdc interpolation fft grib_api_merging} {
file copy -force ${worksrcpath}/${d}/Makefile.in ${worksrcpath}/${d}/Makefile
reinplace "s:reals:R64:" ${worksrcpath}/${d}/Makefile
reinplace "s:arch:linux:" ${worksrcpath}/${d}/Makefile
- reinplace "s:depl:emos:" ${worksrcpath}/${d}/Makefile
+ reinplace "s:depl:${name}:" ${worksrcpath}/${d}/Makefile
reinplace "s:\$(ARCH)\$(CNAME)\$(R64)\$(A64):site:" ${worksrcpath}/${d}/Makefile
}
+ reinplace "s:I\$(GRIB_API_PATH):I${prefix}:" ${worksrcpath}/grib_api_merging/Makefile
reinplace "s:`cat -s .r64`:R64:" ${worksrcpath}/install
- reinplace "s:`cat -s .emos`:${destroot}${prefix}/lib/${name}; \
-mkdir -p ${destroot}${prefix}/lib/${name}:" ${worksrcpath}/install
+ reinplace "s:`cat -s .emos`:${destroot}${prefix}/lib/${name}:" ${worksrcpath}/install
}
post-build {
@@ -69,7 +67,7 @@
foreach d {gribex pbio bufrdc bufrtables crexdc interpolation fft} {
reinplace "s:R64 = R64:R64 =:" ${worksrcpath}/${d}/Makefile
}
- if {[variant_isset gcc43]} {
+ if {[variant_isset gcc43] || [variant_isset gcc44] || [variant_isset gcc45]} {
reinplace "s:-fdefault-real-8 -fdefault-double-8 ::" ${worksrcpath}/config/config.site
} else {
reinplace "s:-r8 ::" ${worksrcpath}/config/config.site
@@ -77,47 +75,58 @@
system "cd ${worksrcpath}; make clean; make"
}
-destroot.cmd ${worksrcpath}/install
-destroot.target ""
-destroot.destdir ""
-
-post-destroot {
- reinplace "s:R64=R64:R64=:" ${worksrcpath}/install
+destroot {
+ xinstall -m 755 -d ${destroot}${prefix}/lib/${name}
+ xinstall -m 755 -d ${destroot}${prefix}/lib/${name}/bin
system "cd ${worksrcpath}; ./install"
- system "ln -s emos/libemosR64.a ${destroot}${prefix}/lib/libemosR64.a"
- system "ln -s emos/libemos.a ${destroot}${prefix}/lib/libemos.a"
+ xinstall -m 644 ${worksrcpath}/lib${name}.a ${destroot}${prefix}/lib/${name}
+ foreach f {bufr2txt_tables bufr_split_tables txt2bufr_tables} {
+ xinstall -m 755 ${worksrcpath}/bufrtables/${f} ${destroot}${prefix}/lib/${name}/bin
+ }
+ system "ln -s ${name}/lib${name}R64.a ${destroot}${prefix}/lib/lib${name}R64.a"
+ system "ln -s ${name}/lib${name}.a ${destroot}${prefix}/lib/lib${name}.a"
+ system "cd ${destroot}${prefix}/lib/${name}; \
+ for d in bufrtables crextables gribtables gribtemplates land_sea_mask; do \
+ chmod 755 \$d; \
+ find \$d -type f -print | xargs chmod 644; \
+ done; \
+ find gribtables -type d -print | xargs chmod 755"
}
use_parallel_build no
-if {![variant_isset gcc43]} {
+if {![variant_isset gcc43] && ![variant_isset gcc45] && ![variant_isset g95]} {
default_variants +gcc44
}
universal_variant no
-variant gcc43 conflicts gcc44 description {builds fortran interface with gfortran 4.3} {
+variant gcc43 conflicts gcc44 gcc45 description {builds fortran interface with gfortran 4.3} {
depends_build-append port:gcc43
- configure.args-delete --disable-fortran
configure.compiler macports-gcc-4.3
configure.fflags-append -fdefault-real-8 -fdefault-double-8 -fcray-pointer -fno-second-underscore -DPOINTER_64 -DINTEGER_IS_INT -Dlinux -Dgfortran
configure.cflags-append -DPOINTER_64 -DINTEGER_IS_INT
}
-variant gcc44 conflicts gcc43 description {builds fortran interface with gfortran 4.4} {
+variant gcc44 conflicts gcc43 gcc45 description {builds fortran interface with gfortran 4.4} {
depends_build-append port:gcc44
- configure.args-delete --disable-fortran
configure.compiler macports-gcc-4.4
configure.fflags-append -fdefault-real-8 -fdefault-double-8 -fcray-pointer -fno-second-underscore -DPOINTER_64 -DINTEGER_IS_INT -Dlinux -Dgfortran
configure.cflags-append -DPOINTER_64 -DINTEGER_IS_INT
}
-#variant g95 conflicts gcc43 gcc44 universal description {builds fortran interface with g95} {
-# depends_build-append port:g95
-# configure.args-delete --disable-fortran
-# configure.fc ${prefix}/bin/g95
-# configure.fflags-append -r8 -fsloppy-char -fno-second-underscore -DUSE_NO_POINTERS -DINTEGER_IS_INT -Dlinux
-# configure.cflags-append -DPOINTER_64 -DINTEGER_IS_INT
-#}
+variant gcc45 conflicts gcc43 gcc44 description {builds fortran interface with gfortran 4.5} {
+ depends_build-append port:gcc45
+ configure.compiler macports-gcc-4.5
+ configure.fflags-append -fdefault-real-8 -fdefault-double-8 -fcray-pointer -fno-second-underscore -DPOINTER_64 -DINTEGER_IS_INT -Dlinux -Dgfortran
+ configure.cflags-append -DPOINTER_64 -DINTEGER_IS_INT
+}
+variant g95 conflicts gcc43 gcc44 universal description {builds fortran interface with g95} {
+ depends_build-append port:g95
+ configure.fc ${prefix}/bin/g95
+ configure.fflags-append -r8 -fsloppy-char -fno-second-underscore -DUSE_NO_POINTERS -DINTEGER_IS_INT -Dlinux
+ configure.cflags-append -DPOINTER_64 -DINTEGER_IS_INT
+}
+
livecheck.type regex
livecheck.url ${homepage}
-livecheck.regex {Latest Emos library ([0-9][0-9][0-9][0-9][0-9][0-9])}
+livecheck.regex {([0-9][0-9][0-9][0-9][0-9][0-9]),}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20110710/44883959/attachment-0001.html>
More information about the macports-changes
mailing list