-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
/
Portfile
105 lines (88 loc) · 3.97 KB
/
Portfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
# -*- 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
PortSystem 1.0
PortGroup python 1.0
name py-sip
version 6.8.3
revision 0
epoch 1
categories-append devel
license {GPL-2 GPL-3 PSF}
maintainers {michaelld @michaelld} {reneeotten @reneeotten} openmaintainer
description A Python bindings generator for C/C++ libraries
long_description SIP is a tool that makes it very easy to create \
Python bindings for C and C++ libraries. It was \
originally developed to create PyQt, the Python \
bindings for the Qt toolkit, but can be used to \
create bindings for any C or C++ library.
homepage https://www.riverbankcomputing.com/software/sip/
checksums rmd160 07127bf251f9a8b58447cd4ce4169b37d3dbc786 \
sha256 888547b018bb24c36aded519e93d3e513d4c6aa0ba55b7cc1affbd45cf10762c \
size 987656
python.versions 35 36 37 38 39 310 311 312
foreach pver {37 38 39 310 311 312} {
subport py${pver}-sip-devel {
version 6.8.1.dev2311302116
master_sites https://www.riverbankcomputing.com/pypi/packages/sip
epoch 0
revision 0
checksums rmd160 295f07e60682763c78dc7823d0a57117e8e114c1 \
sha256 64076f1a20fba16726ef3e69b5015aeb1c5526c6d7ec3e83c4516854493e0bc5 \
size 1129175
conflicts py${pver}-sip
}
subport py${pver}-sip {
conflicts py${pver}-sip-devel
}
}
if {${name} ne ${subport}} {
if {${python.version} == 35} {
version 5.5.0
revision 1
checksums rmd160 fe56e4f7617fcc8aad3c63e10b19996f58ba44dc \
sha256 5d024c419b30fea8a6de8c71a560c7ab0bc3c221fbfb14d55a5b865bd58eaac5 \
size 1108126
} elseif {${python.version} == 36} {
version 6.5.1
revision 1
checksums rmd160 6dcf12ef1007812e9a2fff0483fbdaf423311282 \
sha256 204f0240db8999a749d638a987b351861843e69239b811ec3d1881412c3706a6 \
size 1197925
} else {
# Pure python as of 6.8.0
platforms {darwin any}
supported_archs noarch
depends_lib-append \
port:py${python.version}-ply
# 'ScopedName' object has no attribute 'replace'
patchfiles-append \
patch-ScopedName-str-conversion.diff
}
depends_lib-append \
port:py${python.version}-packaging \
port:py${python.version}-setuptools
if {${python.version} < 38} {
depends_lib-append \
port:py${python.version}-importlib-metadata
}
if {${python.version} <= 36} {
depends_lib-append \
port:py${python.version}-toml
} elseif {${python.version} < 311} {
depends_lib-append \
port:py${python.version}-tomli
}
post-destroot {
xinstall -d ${destroot}${prefix}/share/doc
file copy ${worksrcpath}/doc ${destroot}${prefix}/share/doc/${subport}
xinstall -m 0644 -W ${worksrcpath} LICENSE LICENSE-GPL2 LICENSE-GPL3 NEWS README ChangeLog \
${destroot}${prefix}/share/doc/${subport}
system "${python.bin} ${python.libdir}/compileall.py ${destroot}${prefix}"
system "${python.bin} -O ${python.libdir}/compileall.py ${destroot}${prefix}"
}
notes "${subport} is available under a PSF license with one addition: \n
4. Licensee may not use SIP to generate Python bindings for any C or
C++ library for which bindings are already provided by Riverbank. \n
GPL-2 or GPL-3 licenses are also available. For details see
${prefix}/share/doc/${subport}/LICENSE \[-GPL2 -GPL3\]\n\n"
livecheck.type none
}