source: trunk/dports/science/healpix/Portfile @ 91025

Last change on this file since 91025 was 91025, checked in by aronnax@…, 7 years ago

healpix: address ryandesign's comments

File size: 2.7 KB
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id$
3
4PortSystem          1.0
5
6name                healpix
7version             2.20a
8categories          science
9maintainers         aronnax
10description         Hierarchical Equal Area isoLatitude Pixelization of a sphere
11long_description    Software for pixelization, hierarchical indexation, synthesis, \
12                    analysis, and visualization of data on the sphere.
13homepage            http://healpix.jpl.nasa.gov/
14platforms           darwin
15master_sites        sourceforge:project/${name}/Healpix_${version}
16worksrcdir          Healpix_${version}
17distname            Healpix_${version}_2011Feb09
18
19checksums           md5     e4d534505cd91cfea60719f620584b2f \
20                    sha1    f7a0fdab8e9fcfdf81e3e5e9a7d18912203d3803 \
21                    rmd160  e15b14262591a679764665d4d1774c38786a7a00
22
23universal_variant   yes
24
25depends_lib         port:cfitsio
26
27patchfiles          patch-src-cxx-cxxsupport-arr.h.diff
28use_configure       no
29
30# Find a compiler that supports OpenMP.  Courtesy of Adam Mercer.
31if {${configure.compiler} == "clang"} {
32   configure.compiler llvm-gcc-4.2
33}
34
35if {${configure.compiler} == "gcc-4.0"} {
36   configure.compiler gcc-4.2
37   if {![file executable ${configure.cc}]} {
38       depends_build-append port:apple-gcc42
39       configure.compiler apple-gcc-4.2
40   }
41}
42
43build.post_args-append \
44                    HEALPIX_TARGET=osx \
45                    BINDIR=${worksrcpath}/bin \
46                    LIBDIR=${worksrcpath}/lib \
47                    INCDIR=${worksrcpath}/include \
48                    EXTERNAL_CFITSIO=yes \
49                    CFITSIO_INCDIR=${prefix}/include \
50                    CFITSIO_LIBDIR=${prefix}/lib \
51                    CFITSIO_EXT_LIB=${prefix}/lib/libcfitsio.a \
52                    CFITSIO_EXT_INC=${prefix}/include \
53                    CC="${configure.cc} [get_canonical_archflags cc]" \
54                    CL="${configure.cc} [get_canonical_archflags ld]" \
55                    CXX="${configure.cxx} [get_canonical_archflags cxx]" \
56                    CXXL="${configure.cxx} [get_canonical_archflags ld]"
57
58build {
59    system -W ${worksrcpath}/src/cxx "${build.cmd} [join ${build.post_args}]"
60    system -W ${worksrcpath}/src/C/subs "${build.cmd} static install AR=\"ar -rsv\" [join ${build.post_args}]"
61}
62
63post-build {
64    # This file is just a copy of ${worksrcpath}/lib/libhpxgif.a
65    # and conflicts with port:giflib.
66    file delete ${worksrcpath}/lib/libgif.a
67}
68
69destroot {
70    eval xinstall [glob ${worksrcpath}/include/*] ${destroot}${prefix}/include
71    eval xinstall [glob ${worksrcpath}/lib/*] ${destroot}${prefix}/lib
72    eval xinstall [glob ${worksrcpath}/bin/*] ${destroot}${prefix}/bin
73}
Note: See TracBrowser for help on using the repository browser.