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

Last change on this file was 140960, checked in by michaelld@…, 2 years ago

qt4 various: change qt_dir to ${prefix}/libexec/qt4 to allow for a parallel install with qt5; rev-bump dependencies that are known to work with this change. Addresses the primary issue of #44193. Will address secondary issues down the road.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.3 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 140960 2015-10-06 20:13:45Z ryandesign@macports.org $
3
4PortSystem          1.0
5PortGroup           python 1.0
6
7name                py-pyqwt
8version             5.2.0
9revision            11
10
11platforms           macosx
12categories-append   devel
13maintainers         michaelld openmaintainer
14license             GPL-2+
15
16description         PyQwt is a set of Python bindings for the Qwt 5 toolkit
17long_description    PyQwt is a set of Python bindings for the Qwt C++ class library which extends \
18                    the Qt framework with widgets for scientific and engineering applications. It \
19                    provides a widget to plot 2-dimensional data and various widgets to display \
20                    and control bounded or unbounded floating point values. \
21                    PyQwt version 5 is compatible with Qwt version 5 only.
22
23homepage            http://pyqwt.sourceforge.net
24master_sites        sourceforge:pyqwt
25distname            PyQwt-${version}
26dist_subdir         python
27
28checksums           md5     fcd6c6029090d473dcc9df497516eae7 \
29                    sha1    797f37c63dec660272f6a8ccfd16a017df0ad640 \
30                    rmd160  e4c8a63d623d974cd500e29fbc62255746ca7feb
31
32# Note that python 3.1 is apparently supported but the dependencies need to be added first
33python.versions     27
34
35if {${name} ne ${subport}} {
36
37    use_configure      yes
38
39    # Can use either py*-pyqt4 or py*-pyqt4-devel.
40    depends_lib-append path:share/py${python.version}-sip/PyQt4:py${python.version}-pyqt4 \
41                       port:py${python.version}-numpy \
42                       port:py${python.version}-sip
43
44    worksrcdir         ${worksrcdir}/configure
45   
46    configure.cmd      ${prefix}/bin/python${python.branch} configure.py
47    configure.pre_args -I ${prefix}/include -I ${prefix}/include/qwt -I ${prefix}/include/python${python.branch} -L ${prefix}/lib --disable-numarray --disable-numeric
48    configure.universal_args-delete --disable-dependency-tracking
49
50    build.target
51    build.cmd          make
52    destroot.cmd       make install
53    destroot.destdir   DESTDIR=${destroot}
54
55    # depend on the QWT5 library, but default to 5.2.  This port is
56    # does not work with Qwt 6 (any longer; not sure if it ever did).
57    depends_lib-append  path:lib/libqwt.5.dylib:qwt52
58
59    post-configure {
60
61        # fix compiler
62
63        reinplace "s@CC = .*@CC = ${configure.cc}@" \
64            ${worksrcpath}/qwt5qt4/Makefile ${worksrcpath}/iqt5qt4/Makefile
65        reinplace "s@CXX = .*@CXX = ${configure.cxx}@" \
66            ${worksrcpath}/qwt5qt4/Makefile ${worksrcpath}/iqt5qt4/Makefile
67        reinplace "s@LINK = .*@LINK = ${configure.cxx}@" \
68            ${worksrcpath}/qwt5qt4/Makefile ${worksrcpath}/iqt5qt4/Makefile
69
70        # if not universal, try removing all arch flags from the
71        # Makefiles.  If Python is installed as +universal, these will
72        # do the trick; if Python is installed as -universal, then
73        # these will do no harm.
74
75        if {![variant_isset universal]} {
76            reinplace "s@-arch \[^ \]*@@g" ${worksrcpath}/qwt5qt4/Makefile
77            reinplace "s@-arch \[^ \]*@@g" ${worksrcpath}/iqt5qt4/Makefile
78        }
79    }
80}
81
82livecheck.type  regex
83livecheck.url   ${homepage}
84livecheck.regex PyQwt-(\[0-9\.\]+)\.tar\.gz
Note: See TracBrowser for help on using the repository browser.