Changeset 37814 for trunk/dports
- Timestamp:
- Jun 24, 2008, 9:52:54 PM (16 years ago)
- Location:
- trunk/dports/lang/python24
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/dports/lang/python24
- Property svnmerge-integrated changed
/branches/python-frameworks/dports/lang/python24 merged: 36460,36462-36463,36654,37481,37529,37811-37812
- Property svnmerge-integrated changed
-
trunk/dports/lang/python24/Portfile
r37335 r37814 3 3 PortSystem 1.0 4 4 5 name python24 6 version 2.4.5 7 revision 1 8 set major_version 2 9 set minor_version 4 10 categories lang 11 platforms darwin freebsd linux 12 maintainers nomaintainer 13 description An interpreted, object-oriented programming language 14 long_description Python is an interpreted, interactive, object-oriented \ 15 programming language. 5 name python24 6 version 2.4.5 7 revision 2 8 set major 2 9 set branch 2.4 10 categories lang 11 platforms darwin 12 maintainers nomaintainer 16 13 17 homepage http://www.python.org/ 18 master_sites ${homepage}ftp/python/${version}/ \ 19 ftp://ftp.python.org/pub/python/${version}/ 20 distname Python-${version} 21 checksums md5 750b652bfdd12675e102bbe25e5e9893 22 patchfiles patch-configure \ 23 patch-Makefile.pre.in \ 24 patch-Lib-cgi.py \ 25 patch-Lib-site.py \ 26 patch-setup.py \ 27 patch-Include-pyport.h \ 28 patch-Mac-OSX-Makefile.in \ 29 patch-Mac-OSX-IDLE-Makefile.in \ 30 patch-Mac-OSX-PythonLauncher-Makefile.in 31 #the bzip2-archive of 2.4.5 on python.org is broken (its a gzip-archive..); 32 #use_bzip2 yes 33 extract.suffix .tgz 14 description An interpreted, object-oriented programming language 15 long_description Python is an interpreted, interactive, object-oriented \ 16 programming language. 34 17 35 depends_lib port:gettext 18 homepage http://www.python.org/ 19 master_sites ${homepage}/ftp/python/${version}/ \ 20 ftp://ftp.python.org/pub/python/${version}/ \ 21 ftp://ftp.fastorama.com/mirrors/ftp.python.org/pub/python/${version}/ \ 22 ftp://ftp.python.jp/pub/python/${version}/ 36 23 37 configure.args --enable-shared \ 38 --mandir=${prefix}/share/man \ 39 --bindir=${prefix}/bin \ 40 --libdir=${prefix}/lib \ 41 --without-readline \ 42 --enable-framework=${prefix}/Library/Frameworks \ 43 --disable-tk \ 44 --enable-ipv6 24 distname Python-${version} 25 extract.suffix .tgz 26 27 checksums md5 750b652bfdd12675e102bbe25e5e9893 \ 28 sha1 927c6e93ed3ea3bee4e07eff4b0f14254dc04147 \ 29 rmd160 6c1c2905b166038fda5edb14baadbeb59acc8005 30 31 patchfiles patch-configure \ 32 patch-Makefile.pre.in \ 33 patch-Lib-cgi.py \ 34 patch-Lib-site.py \ 35 patch-setup.py \ 36 patch-Include-pyport.h \ 37 patch-Mac-OSX-Makefile.in \ 38 patch-Mac-OSX-IDLE-Makefile.in \ 39 patch-Mac-OSX-PythonLauncher-Makefile.in 40 41 depends_lib port:gettext 42 43 configure.args --enable-shared \ 44 --enable-framework=${prefix}/Library/Frameworks \ 45 --mandir=${prefix}/share/man \ 46 --without-readline \ 47 --disable-tk \ 48 --enable-ipv6 49 50 use_parallel_build no 45 51 46 52 post-patch { 47 reinplace "s|__PREFIX__|${prefix}|g" ${worksrcpath}/Lib/cgi.py48 reinplace "s|__PREFIX__|${prefix}|g" ${worksrcpath}/Lib/site.py49 reinplace "s|__PREFIX__|${prefix}|g" ${worksrcpath}/Mac/OSX/Makefile.in50 reinplace "s|__PREFIX__|${prefix}|g" ${worksrcpath}/setup.py53 reinplace "s|__PREFIX__|${prefix}|g" ${worksrcpath}/Lib/cgi.py 54 reinplace "s|__PREFIX__|${prefix}|g" ${worksrcpath}/Lib/site.py 55 reinplace "s|__PREFIX__|${prefix}|g" ${worksrcpath}/Mac/OSX/Makefile.in 56 reinplace "s|__PREFIX__|${prefix}|g" ${worksrcpath}/setup.py 51 57 } 52 58 53 build.target all libpython2.4.dylib59 build.target all libpython${branch}.dylib 54 60 55 61 # Workaround for case-sensitive file systems 56 62 post-build { 57 63 if { ![file exists ${worksrcpath}/python.exe] } { 58 ln -s python ${worksrcpath}/python.exe 64 ln -s python ${worksrcpath}/python.exe 59 65 } 60 66 } 61 67 62 test.run yes63 test.target test68 test.run yes 69 test.target test 64 70 65 destroot.target frameworkinstall maninstall 71 destroot.target frameworkinstall maninstall 72 66 73 post-destroot { 67 if { [variant_isset macosx]} { 68 set framewdir ${prefix}/Library/Frameworks/Python.framework 69 xinstall -m 755 -d ${destroot}${framewdir}/Versions/2.4/include 70 ln -s Versions/Current/lib ${destroot}${framewdir}/Libraries 71 ln -sf ${framewdir}/Versions/2.4/bin/pydoc ${destroot}${prefix}/bin/pydoc 72 ln -sf ${framewdir}/Versions/2.4/bin/pydoc ${destroot}${prefix}/bin/pydoc24 73 ln -s ${prefix}/lib/python2.4/config ${destroot}${framewdir}/Versions/2.4/lib/python2.4/config 74 ln -s ${framewdir}/Versions/2.4/lib/libpython${major_version}.${minor_version}.dylib ${destroot}${prefix}/lib/libpython${version}.dylib 75 ln -s ${framewdir}/Versions/2.4/lib/libpython${major_version}.${minor_version}.dylib ${destroot}${prefix}/lib/libpython${major_version}.${minor_version}.dylib 76 ln -s ${framewdir}/Versions/2.4/lib/libpython${major_version}.${minor_version}.dylib ${destroot}${prefix}/lib/libpython${major_version}.dylib 77 ln -s ${framewdir}/Versions/2.4/lib/libpython${major_version}.${minor_version}.dylib ${destroot}${prefix}/lib/libpython.dylib 78 } elseif { [variant_isset darwin]} { 79 ln -s libpython${major_version}.${minor_version}.dylib ${destroot}${prefix}/lib/libpython${version}.dylib 80 ln -s libpython${major_version}.${minor_version}.dylib ${destroot}${prefix}/lib/libpython${major_version}.dylib 81 ln -s libpython${major_version}.${minor_version}.dylib ${destroot}${prefix}/lib/libpython.dylib 82 } else { 83 system "cd ${destroot}${prefix}/lib && \ 84 ln -s libpython${major_version}.${minor_version}.so \ 85 libpython${version}.so && \ 86 ln -s libpython${major_version}.${minor_version}.so \ 87 libpython${major_version}.so && \ 88 ln -s libpython${major_version}.${minor_version}.so \ 89 libpython.so" 90 } 91 } 74 set framewpath ${prefix}/Library/Frameworks/Python.framework 75 set framewdir ${framewpath}/Versions/${branch} 92 76 93 # needed to trigger the variant_isset check above 94 platform macosx {} 77 foreach dir { lib include } { 78 file rename ${destroot}${framewdir}/${dir}/python${branch} ${destroot}${prefix}/${dir} 79 ln -s ${destroot}${prefix}/${dir}/python${branch} ${destroot}${framewdir}/${dir}/python${branch} 80 } 95 81 96 # delete symlinks without version suffix, use python_select instead to choose version 97 platform darwin { 98 post-destroot { 99 file delete ${destroot}${prefix}/bin/python 100 file delete ${destroot}${prefix}/bin/pythonw 101 file delete ${destroot}${prefix}/bin/idle 102 file delete ${destroot}${prefix}/bin/pydoc 103 file delete ${destroot}${prefix}/bin/smtpd.py 104 file rename ${destroot}${prefix}/share/man/man1/python.1 ${destroot}${prefix}/share/man/man1/python2.4.1 82 file rename ${destroot}${framewdir}/lib/libpython${branch}.dylib ${destroot}${prefix}/lib 83 ln -s ${destroot}${prefix}/lib/libpython${branch}.dylib ${destroot}${framewdir}/lib/libpython${branch}.dylib 84 85 file rename ${destroot}${prefix}/share/man/man1/python.1 ${destroot}${prefix}/share/man/man1/python${branch}.1 86 87 # delete symlinks without version suffix, use python_select instead to choose version 88 foreach bin { python pythonw idle pydoc smtpd.py } { 89 file delete ${destroot}${prefix}/bin/${bin} 90 } 91 foreach bin [list python${branch} pythonw${branch} idle${branch} pydoc${branch} smtpd${branch}.py] { 92 file rename -force ${destroot}${framewdir}/bin/${bin} ${destroot}${prefix}/bin 93 ln -s ${prefix}/bin/${bin} ${destroot}${framewdir}/bin/${bin} 94 } 95 96 foreach dir { Headers Resources Python Versions/Current } { 97 file delete ${destroot}${framewpath}/${dir} 98 } 105 99 106 100 # install select file for python_select 107 101 xinstall -m 755 -d ${destroot}${prefix}/etc/select/python 108 xinstall -m 644 ${filespath}/python24 ${destroot}${prefix}/etc/select/python/ 109 } 102 xinstall -m 644 ${filespath}/python[string map {. {}} ${branch}] ${destroot}${prefix}/etc/select/python/ 110 103 } 111 104 112 p latform puredarwin{113 configure.args-delete --enable-framework=${prefix}/Library/Frameworks114 configure.args-append --disable-toolbox-glue --disable-framework 115 destroot.target install maninstall 105 post-activate { 106 ui_msg "\nTo fully complete your installation and make python $branch the default, please run 107 \n\tsudo port install python_select \ 108 \n\tsudo python_select $name\n" 116 109 } 117 110 118 111 platform darwin 8 { 119 configure.args-append --with-cxx=/usr/bin/g++-4.0 112 # TODO: would configure.compiler be more appropriate? 113 configure.args-append --with-cxx=/usr/bin/g++-4.0 120 114 } 121 115 122 116 platform darwin 9 { 123 configure.cppflags-append-D__DARWIN_UNIX03117 configure.cppflags-append -D__DARWIN_UNIX03 124 118 } 125 119 126 platform freebsd { 127 configure.args-delete --enable-framework=${prefix}/Library/Frameworks 128 configure.args-append --disable-framework 129 build.target all libpython2.4.so 130 destroot.target install maninstall 131 } 120 # TODO: test if this universal variant actually works 121 # variant universal { 122 # configure.args-append --enable-universalsdk 123 # } 132 124 133 platform linux { 134 configure.args-delete --enable-framework=${prefix}/Library/Frameworks 135 configure.args-append --disable-framework 136 build.target all libpython2.4.so 137 destroot.target install maninstall 138 } 139 140 livecheck.check regex 141 livecheck.url http://www.python.org/download/releases/ 142 livecheck.regex Python (2.4.\[0-9\]+) 125 livecheck.check regex 126 livecheck.url ${homepage}download/releases/ 127 livecheck.regex Python (${branch}.\[0-9\]+)
Note: See TracChangeset
for help on using the changeset viewer.