1 | # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:et:sw=4:ts=4:sts=4 |
---|
2 | # $Id: Portfile 34382 2008-02-22 23:37:41Z mww@macports.org $ |
---|
3 | |
---|
4 | PortSystem 1.0 |
---|
5 | |
---|
6 | ####################################################################################################### |
---|
7 | # PortGroup python26 1.0 |
---|
8 | ####################################################################################################### |
---|
9 | # Can be removed once MacPorts 1.7.0 is released |
---|
10 | if {![info exists frameworks_dir]} { |
---|
11 | set frameworks_dir ${prefix}/Library/Frameworks |
---|
12 | } |
---|
13 | |
---|
14 | set python.bin ${prefix}/bin/python2.6 |
---|
15 | set python.lib ${frameworks_dir}/Python.framework/Versions/2.6/Python |
---|
16 | set python.pkgd ${frameworks_dir}/Python.framework/Versions/2.6/lib/python2.6/site-packages |
---|
17 | set python.include ${frameworks_dir}/Python.framework/Versions/2.6/include/python2.6 |
---|
18 | |
---|
19 | categories python |
---|
20 | |
---|
21 | dist_subdir python |
---|
22 | |
---|
23 | depends_lib port:python26 |
---|
24 | |
---|
25 | use_configure no |
---|
26 | |
---|
27 | build.cmd ${python.bin} setup.py --no-user-cfg |
---|
28 | build.target build |
---|
29 | |
---|
30 | destroot.cmd ${python.bin} setup.py --no-user-cfg |
---|
31 | destroot.destdir --prefix=${frameworks_dir}/Python.framework/Versions/2.6 --root=${destroot} |
---|
32 | configure.pkg_config_path ${frameworks_dir}/Python.framework/Versions/2.6/lib/pkgconfig |
---|
33 | |
---|
34 | set env(PATH) "${prefix}/Library/Frameworks/Python.framework/Versions/2.6/bin:$env(PATH)" |
---|
35 | |
---|
36 | pre-destroot { |
---|
37 | xinstall -d -m 755 ${destroot}${prefix}/share/doc/${name}/examples |
---|
38 | } |
---|
39 | ####################################################################################################### |
---|
40 | |
---|
41 | name py26-tkinter |
---|
42 | version 2.6 |
---|
43 | set branch [join [lrange [split ${version} .] 0 1] .] |
---|
44 | categories python graphics |
---|
45 | platforms darwin |
---|
46 | maintainers mcalhoun openmaintainer |
---|
47 | description Python bindings to the Tk widget set |
---|
48 | long_description ${description} |
---|
49 | |
---|
50 | homepage http://www.python.org/doc/current/library/tkinter.html |
---|
51 | master_sites http://www.python.org/ftp/python/${version}/ |
---|
52 | |
---|
53 | dist_subdir python26 |
---|
54 | distname Python-${version} |
---|
55 | extract.suffix .tgz |
---|
56 | |
---|
57 | checksums md5 d16d29a77db2cd3af882a591f431a403 \ |
---|
58 | sha1 d7fd08304b66cb4020786a7ee5aa452235046ecd \ |
---|
59 | rmd160 b44d5cc7efa198b21f41e43e1d28af60875f0a4e |
---|
60 | |
---|
61 | depends_lib-append port:tcl port:tk |
---|
62 | |
---|
63 | worksrcdir ${worksrcdir}/Modules |
---|
64 | |
---|
65 | extract.post_args "| tar -xf - ${distname}/Modules/_tkinter.c \ |
---|
66 | ${distname}/Modules/tkappinit.c" |
---|
67 | post-extract { |
---|
68 | file copy ${filespath}/setup.py ${worksrcpath} |
---|
69 | } |
---|
70 | |
---|
71 | configure { |
---|
72 | reinplace "s|__VERSION__|${version}|g" ${worksrcpath}/setup.py |
---|
73 | reinplace "s|__PREFIX__|${prefix}|g" ${worksrcpath}/setup.py |
---|
74 | } |
---|
75 | |
---|
76 | livecheck.check regex |
---|
77 | livecheck.url http://www.python.org/download/releases/ |
---|
78 | livecheck.regex Python (${branch}(?:\\.\\d+))* |
---|