source: trunk/dports/python/py-astropy/Portfile

Last change on this file was 150613, checked in by raimue@…, 12 months ago

science/cfitsio:
Fix compatibility version in library, closes #51645
Rev-bump all direct dependents for rebuild.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.5 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: Portfile 150613 2016-07-24 08:27:35Z ryandesign@macports.org $
3
4PortSystem          1.0
5PortGroup           python 1.0
6name                py-astropy
7version             1.2
8revision            4
9maintainers         robitaille
10
11dist_subdir         ${name}/${version}
12
13categories-append   science
14description         A Community Python Library for Astronomy
15long_description    The Astropy project is a common effort to develop \
16                    a single core package for Astronomy.
17
18platforms           darwin
19license             BSD
20
21homepage            http://www.astropy.org
22master_sites        pypi:a/astropy/
23distname            astropy-${version}
24checksums           md5     3a215762e1688c7d53bd32c78e7fa67a \
25                    sha1    2fd4410b51d1e8b657ad9c101f8612fa505284f6 \
26                    rmd160  ea9dad7b5124e6a577979f6e2c1a5f9fcbf0eeed
27
28python.versions     27 33 34 35
29
30build.args-append   --use-system-cfitsio \
31                    --use-system-expat \
32                    --use-system-wcslib \
33                    --use-system-erfa
34
35if {${name} ne ${subport}} {
36
37    depends_lib-append  port:cfitsio \
38                        port:expat \
39                        port:wcslib \
40                        port:erfa \
41                        port:py${python.version}-numpy
42
43    depends_build-append \
44                        port:pkgconfig \
45                        port:py${python.version}-setuptools
46
47    # By default, astropy downloads an astropy-helpers package for setup.py.
48    # The --offline and --no-git flags prevent this and use a bundled version.
49    build.cmd  ${python.bin} setup.py --no-user-cfg --offline --no-git
50    destroot.cmd  ${python.bin} setup.py --no-user-cfg --offline --no-git
51
52    # Don't let the python portgroup create symlinks to the binaries, because
53    # the python portgroup's post-destroot block will run before ours, so the
54    # files won't have the right names yet, and the symlinks will be broken.
55    python.link_binaries no
56
57    post-destroot {
58        # Don't conflict with files installed by py-pyfits.
59        set ap_suffix -ap
60        foreach bin {fitscheck fitsdiff fitsheader volint fits2bitmap samp_hub wcslint} {
61            move ${destroot}${python.prefix}/bin/${bin} ${destroot}${python.prefix}/bin/${bin}${ap_suffix}
62            ln -s ${python.prefix}/bin/${bin}${ap_suffix} ${destroot}${prefix}/bin/${bin}${ap_suffix}${python.link_binaries_suffix}
63        }
64    }
65
66}
Note: See TracBrowser for help on using the repository browser.