Skip to content
Permalink
Browse files

splash: Update to version 2.4.0. Use FORTRAN recipe. (https://trac.ma…

  • Loading branch information
mf2k committed Mar 7, 2014
1 parent bb9f766 commit 1d26679ea84f467c0c02eb1fa3715c5d79cdf906
Showing with 46 additions and 30 deletions.
  1. +46 −30 science/splash/Portfile
@@ -4,8 +4,7 @@
PortSystem 1.0

name splash
version 2.3.1
revision 1
version 2.4.0
categories science graphics
platforms darwin
maintainers monash.edu:daniel.price
@@ -19,21 +18,13 @@ license GPL-2+

worksrcdir ${name}

checksums rmd160 d16bc15ceb3ac2714a19653a41bb589000e32a34 \
sha256 214d3d8a95e9816a103cc05ecc7f8ad5e14c1e8ff9b65f009b1e7e5b020eedd8
checksums rmd160 981bc357a8f6b73c515d6bc9f267a6f00d28869e \
sha256 5ff612ed988dbddcf57136317347529f7cf3c85ffac99167a14db5877b7e5333

if {![variant_isset gcc44] && ![variant_isset gcc45] && ![variant_isset gcc46] && ![variant_isset gcc47]} {
default_variants +gcc47
}
default_variants +giza

use_configure no

build.args SYSTEM=gfortran \
CC="${configure.cc}" \
CFLAGS="[get_canonical_archflags cc]" \
FFLAGS="[get_canonical_archflags fc]" \
F90FLAGS="[get_canonical_archflags f90]"
build.args SYSTEM=gfortran

destroot.args PREFIX=${prefix}
use_parallel_build no
@@ -51,30 +42,55 @@ variant pgplot description {use PGPLOT as the backend graphics library} conflict
build.args-append BACKEND=pgplot
}

variant gcc47 description {build with gfortran/gcc v4.7} conflicts gcc44 gcc45 gcc46 {
depends_lib-append path:lib/libgcc/libgcc_s.1.dylib:libgcc
depends_build-append port:gcc47
build.args-append F90C=gfortran-mp-4.7 FC=gfortran-mp-4.7
}
set gcc_versions {4.5 4.6 4.7 4.8}
set default_fortran_variant +gcc48

foreach ver ${gcc_versions} {
set ver_no_dot [join [split ${ver} "."] ""]

set variant_line {variant gcc${ver_no_dot} description "build with gfortran from gcc${ver_no_dot}"}

foreach over ${gcc_versions} {
if {${ver} == ${over}} {
continue
}

variant gcc46 description {build with gfortran/gcc v4.6} conflicts gcc44 gcc45 gcc47 {
depends_lib-append path:lib/libgcc/libgcc_s.1.dylib:libgcc
depends_build-append port:gcc46
build.args-append F90C=gfortran-mp-4.6 FC=gfortran-mp-4.6
set over_no_dot [join [split ${over} "."] ""]
append variant_line " conflicts gcc${over_no_dot}"
}
append variant_line { {}}

eval $variant_line

if {[variant_isset gcc${ver_no_dot}]} {
if {${default_fortran_variant} != "+gcc${ver_no_dot}"} {
set default_fortran_variant ""
}
}
}

variant gcc45 description {build with gfortran/gcc v4.5} conflicts gcc44 gcc46 gcc47 {
depends_lib-append path:lib/libgcc/libgcc_s.1.dylib:libgcc
depends_build-append port:gcc45
build.args-append F90C=gfortran-mp-4.5 FC=gfortran-mp-4.5
if {${default_fortran_variant} != ""} {
default_variants-append "${default_fortran_variant}"
}

variant gcc44 description {build with gfortran/gcc v4.4} conflicts gcc45 gcc46 gcc47 {
depends_lib-append path:lib/libgcc/libgcc_s.1.dylib:libgcc
depends_build-append port:gcc44
build.args-append F90C=gfortran-mp-4.4 FC=gfortran-mp-4.4
foreach ver ${gcc_versions} {
set ver_no_dot [join [split ${ver} "."] ""]

if {[variant_isset gcc${ver_no_dot}]} {
depends_lib-append path:lib/libgcc/libgcc_s.1.dylib:libgcc
depends_build-append port:gcc${ver_no_dot}

configure.fc ${prefix}/bin/gfortran-mp-${ver}
configure.f77 ${prefix}/bin/gfortran-mp-${ver}
configure.f90 ${prefix}/bin/gfortran-mp-${ver}
}
}

build.args-append FC="${configure.fc}" \
CC="${configure.cc}" \
CFLAGS="[get_canonical_archflags cc]" \
FFLAGS="[get_canonical_archflags fc]"

variant hdf5 description {compiles data reads that depend on HDF5} {
build.args-append gadgethdf5 HDF5ROOT=${prefix}
depends_lib-append port:hdf5-18

0 comments on commit 1d26679

Please sign in to comment.
You can’t perform that action at this time.