Ticket #50374: Portfile-wgrib2.diff
File Portfile-wgrib2.diff, 2.5 KB (added by dstrubbe (David Strubbe), 9 years ago) |
---|
-
Portfile
62 62 build.args "-f makefile \ 63 63 zlib=\"\" plib=\"\" jlib=\"\" h5lib=\"\" n4lib=\"\" " 64 64 65 set gcc_versions {4.3 4.4 4.5 4.6 4.7 4.8 4.9} 66 set fsymbol "" 67 if {[fortran_variant_isset]} { 68 set iip "-I${ip}" 69 set libs "${lg2c} ${lgctpc} ${lipolate}" 70 build.args-append USE_IPOLATES=1 71 if {[variant_isset g95]} { 72 set fsymbol -DG95 73 configure.fc ${prefix}/bin/g95 74 set libs "${libs} -lf95" 65 pre-build { 66 set fsymbol "" 67 if {[fortran_variant_isset]} { 68 set iip "-I${ip}" 69 set libs "${lg2c} ${lgctpc} ${lipolate} ${compilers.libfortran}" 70 build.args-append USE_IPOLATES=1 71 if {[variant_isset g95]} { 72 set fsymbol -DG95 73 } else { 74 set fsymbol -DGFORTRAN 75 build.args-append USE_OPENMP=1 76 } 77 build.env FC=\"${configure.fc}\" \ 78 F90=\"${configure.fc}\" \ 79 FFLAGS=\"${configure.fflags}\" 75 80 } else { 76 set fsymbol -DGFORTRAN 77 build.args-append USE_OPENMP=1 78 foreach ver ${gcc_versions} { 79 set ver_no_dot [join [split ${ver} "."] ""] 80 if {[variant_isset gcc${ver_no_dot}]} { 81 configure.fc ${prefix}/bin/gfortran-mp-${ver} 82 set libs "${libs} -L${prefix}/lib/gcc${ver_no_dot} -lgfortran" 83 } 84 } 81 set iip "" 82 set libs "${lg2c} ${lgctpc}" 85 83 } 86 build.env FC=\"${configure.fc}\" \ 87 F90=\"${configure.fc}\" \ 88 FFLAGS=\"${configure.fflags}\" 89 } else { 90 set iip "" 91 set libs "${lg2c} ${lgctpc}" 84 build.env-append LDFLAGS=\"${libs} ${configure.ldflags} -lpng -ljasper -lnetcdf\" \ 85 CC=\"${configure.cc}\" \ 86 CPPFLAGS=\"${fsymbol} ${configure.cppflags}\" \ 87 CFLAGS=\"${cflags}\" 88 build.args-append iip=\"${iip}\" 92 89 } 93 build.env-append LDFLAGS=\"${libs} ${configure.ldflags} -lpng -ljasper -lnetcdf\" \94 CC=\"${configure.cc}\" \95 CPPFLAGS=\"${fsymbol} ${configure.cppflags}\" \96 CFLAGS=\"${cflags}\"97 build.args-append iip=\"${iip}\"98 90 99 91 destroot { 100 92 xinstall -m 644 ${g2c}/grib2.h ${destroot}${prefix}/include