47 | | reinplace "s|__PREFIX__|${prefix}|g" ${worksrcpath}/Lib/cgi.py |
48 | | reinplace "s|/Applications/MacPython|/Applications/MacPorts/MacPython|g" \ |
49 | | Mac/Makefile.in Mac/IDLE/Makefile.in \ |
50 | | Mac/IDLE/Makefile.in Mac/Tools/Doc/setup.py \ |
51 | | Mac/PythonLauncher/Makefile.in \ |
52 | | Mac/BuildScript/build-installer.py |
53 | | reinplace "s|xargs -0 rm -r|xargs -0 rm -rf|g" \ |
54 | | Mac/PythonLauncher/Makefile.in |
| 47 | reinplace "s|__PREFIX__|${prefix}|g" ${worksrcpath}/Lib/cgi.py |
| 48 | reinplace "s|/Applications/MacPython|/Applications/MacPorts/MacPython|g" \ |
| 49 | Mac/Makefile.in Mac/IDLE/Makefile.in \ |
| 50 | Mac/IDLE/Makefile.in Mac/Tools/Doc/setup.py \ |
| 51 | Mac/PythonLauncher/Makefile.in \ |
| 52 | Mac/BuildScript/build-installer.py |
| 53 | reinplace "s|xargs -0 rm -r|xargs -0 rm -rf|g" \ |
| 54 | Mac/PythonLauncher/Makefile.in |
73 | | set framewpath ${prefix}/Library/Frameworks/Python.framework |
74 | | set framewdir ${framewpath}/Versions/${branch} |
75 | | |
76 | | foreach dir { lib include } { |
77 | | file rename ${destroot}${framewdir}/${dir}/python${branch} ${destroot}${prefix}/${dir} |
78 | | ln -s ${prefix}/${dir}/python${branch} ${destroot}${framewdir}/${dir}/python${branch} |
79 | | } |
80 | | |
81 | | file rename ${destroot}${framewdir}/lib/libpython${branch}.dylib ${destroot}${prefix}/lib |
82 | | ln -s ${prefix}/lib/libpython${branch}.dylib ${destroot}${framewdir}/lib/libpython${branch}.dylib |
83 | | |
84 | | file rename ${destroot}${prefix}/share/man/man1/python.1 ${destroot}${prefix}/share/man/man1/python${branch}.1 |
85 | | |
86 | | # delete symlinks without version suffix, use python_select instead to choose version |
87 | | foreach bin { python pythonw idle pydoc smtpd.py python-config } { |
88 | | file delete ${destroot}${prefix}/bin/${bin} |
89 | | } |
90 | | foreach bin [list python${branch} pythonw${branch} idle${branch} pydoc${branch} smtpd${branch}.py python${branch}-config] { |
91 | | file rename -force ${destroot}${framewdir}/bin/${bin} ${destroot}${prefix}/bin |
92 | | ln -s ${prefix}/bin/${bin} ${destroot}${framewdir}/bin/${bin} |
93 | | } |
94 | | |
95 | | foreach dir { Headers Resources Python Versions/Current } { |
96 | | file delete ${destroot}${framewpath}/${dir} |
97 | | } |
98 | | |
99 | | # install select file for python_select |
100 | | xinstall -m 755 -d ${destroot}${prefix}/etc/select/python |
101 | | xinstall -m 644 ${filespath}/python[string map {. {}} ${branch}] ${destroot}${prefix}/etc/select/python/ |
| 73 | set framewpath ${prefix}/Library/Frameworks/Python.framework |
| 74 | set framewdir ${framewpath}/Versions/${branch} |
| 75 | |
| 76 | foreach dir { lib include } { |
| 77 | file rename ${destroot}${framewdir}/${dir}/python${branch} ${destroot}${prefix}/${dir} |
| 78 | ln -s ${prefix}/${dir}/python${branch} ${destroot}${framewdir}/${dir}/python${branch} |
| 79 | } |
| 80 | |
| 81 | file rename ${destroot}${framewdir}/lib/libpython${branch}.dylib ${destroot}${prefix}/lib |
| 82 | ln -s ${prefix}/lib/libpython${branch}.dylib ${destroot}${framewdir}/lib/libpython${branch}.dylib |
| 83 | |
| 84 | file rename ${destroot}${prefix}/share/man/man1/python.1 ${destroot}${prefix}/share/man/man1/python${branch}.1 |
| 85 | |
| 86 | # delete symlinks without version suffix, use python_select instead to choose version |
| 87 | foreach bin { python pythonw idle pydoc smtpd.py python-config } { |
| 88 | file delete ${destroot}${prefix}/bin/${bin} |
| 89 | } |
| 90 | foreach bin [list python${branch} pythonw${branch} idle${branch} pydoc${branch} smtpd${branch}.py python${branch}-config] { |
| 91 | file rename -force ${destroot}${framewdir}/bin/${bin} ${destroot}${prefix}/bin |
| 92 | ln -s ${prefix}/bin/${bin} ${destroot}${framewdir}/bin/${bin} |
| 93 | } |
| 94 | |
| 95 | foreach dir { Headers Resources Python Versions/Current } { |
| 96 | file delete ${destroot}${framewpath}/${dir} |
| 97 | } |
| 98 | |
| 99 | # install select file for python_select |
| 100 | xinstall -m 755 -d ${destroot}${prefix}/etc/select/python |
| 101 | xinstall -m 644 ${filespath}/python[string map {. {}} ${branch}] ${destroot}${prefix}/etc/select/python/ |
111 | | # there is no SystemStubs on 10.3 |
112 | | post-patch { |
113 | | reinplace "s|-lSystemStubs||g" \ |
114 | | configure configure.in |
115 | | } |
116 | | post-configure { |
117 | | reinplace "s|-lSystemStubs||g" \ |
118 | | Makefile.pre.in Makefile.pre Makefile |
119 | | } |
120 | | # To avoid GCC incompatibility issue. See http://nxg.me.uk/note/2004/restFP/ (by ebgssth@gmail.com, ticket #13322) |
121 | | configure.ldflags-append "-lcc_dynamic" |
| 111 | # there is no SystemStubs on 10.3 |
| 112 | post-patch { |
| 113 | reinplace "s|-lSystemStubs||g" configure configure.in |
| 114 | } |
| 115 | post-configure { |
| 116 | reinplace "s|-lSystemStubs||g" Makefile.pre.in Makefile.pre Makefile |
| 117 | } |
| 118 | # To avoid GCC incompatibility issue. See http://nxg.me.uk/note/2004/restFP/ (by ebgssth@gmail.com, ticket #13322) |
| 119 | configure.ldflags-append "-lcc_dynamic" |