# $Id: Portfile 29789 2007-10-10 07:16:12Z ryandesign@macports.org $ PortSystem 1.0 name cdf version 31 maintainers gwright@macports.org platforms darwin categories science description CDF: Common Data Format long_description \ The Common Data Format (CDF) is a self-describing data \ format for the storage and manipulation of scalar and \ multidimensional data in a platform and discipline \ independent fashion. homepage http://cdf.gsfc.nasa.gov/ master_sites ftp://rumba.gsfc.nasa.gov/pub/cdf/dist/${name}${version}/unix distfiles ${name}${version}-dist-all${extract.suffix} checksums sha1 dfef1275fb4f7966633f6e6ca331b06ee7fc48f0 depends_build port:gcc42 fetch.use_epsv no configure { } worksrcdir ${name}${version}-dist platform darwin i386 { global cdf_arch set cdf_arch i386 } platform darwin powerpc { global cdf_arch set cdf_arch ppc } patchfiles patch-Makefile build { system "make OS=macosx ENV=${cdf_arch} FORTRAN=yes FC=gfortran-mp-4.2 all" } destroot { reinplace "s|(INSTALLDIR)/bin/definitions.B|/${prefix}/bin/definitions.B|" ${worksrcpath}/Makefile reinplace "s|(INSTALLDIR)/bin/definitions.C|/${prefix}/bin/definitions.C|" ${worksrcpath}/Makefile reinplace "s|(INSTALLDIR)/bin/definitions.K|/${prefix}/bin/definitions.K|" ${worksrcpath}/Makefile system "make INSTALLDIR=${destroot}${prefix} install" } post-destroot { reinplace "s|${destroot}${prefix}|${prefix}|" ${destroot}${prefix}/bin/definitions.B reinplace "s|${destroot}${prefix}|${prefix}|" ${destroot}${prefix}/bin/definitions.C reinplace "s|${destroot}${prefix}|${prefix}|" ${destroot}${prefix}/bin/definitions.K }