# $Id: Portfile,v 1.32 2006/03/12 22:17:18 mww Exp $ PortSystem 1.0 name python24 version 2.4.2 revision 3 set major_version 2 set minor_version 4 categories lang platforms darwin maintainers mww@opendarwin.org description An interpreted, object-oriented programming language long_description Python is an interpreted, interactive, object-oriented \ programming language. homepage http://www.python.org/ master_sites ${homepage}/ftp/python/2.4.2/ \ ftp://ftp.python.org/pub/python/2.4.2/ distname Python-${version} checksums md5 98db1465629693fc434d4dc52db93838 patchfiles patch-Makefile.pre.in \ patch-configure \ patch-Lib-site.py \ patch-Mac-OSX-Makefile \ patch-setup.py \ patch-Include-pyport.h use_bzip2 yes post-patch { cd ${worksrcpath} reinplace "s|__PREFIX__|${prefix}|g" Lib/site.py Mac/OSX/Makefile } configure.args --enable-shared \ --mandir=${prefix}/share/man \ --bindir=${prefix}/bin \ --libdir=${prefix}/lib \ --without-readline \ --enable-framework=${prefix}/Library/Frameworks \ --enable-ipv6 \ --disable-tk post-configure { cd ${worksrcpath} reinplace "s|^LIBDIR=.*|LIBDIR=${prefix}/lib|g" Makefile reinplace "s|^INCLUDEDIR=.*|INCLUDEDIR=${prefix}/include|g" Makefile reinplace "s|^CONFINCLUDEDIR=.*|CONFINCLUDEDIR=${prefix}/include|g" Makefile } test.run yes test.target test destroot.target frameworkinstall maninstall post-destroot { if { ![variant_isset puredarwin] && ![variant_isset darwin_i386]} { set framewdir ${prefix}/Library/Frameworks/Python.framework/ xinstall -m 755 -d ${destroot}${framewdir}/Versions/2.4/include system "cd ${destroot}${framewdir} \ && ln -s Versions/Current/lib Libraries" system "ln -sf ${prefix}/include/python2.4 ${destroot}${framewdir}/Versions/2.4/include/python2.4" system "cd ${destroot}${prefix}/bin \ && ln -sf ${framewdir}/Versions/2.4/bin/pydoc pydoc \ && ln -sf ${framewdir}/Versions/2.4/bin/pydoc pydoc24" system "cd ${destroot}${framewdir}/Versions/2.4/lib/python2.4 \ && ln -s ${prefix}/lib/python2.4/config config" } system "cd ${destroot}${prefix}/lib && \ ln -s libpython${major_version}.${minor_version}.dylib \ libpython${version}.dylib && \ ln -s libpython${major_version}.${minor_version}.dylib \ libpython${major_version}.dylib && \ ln -s libpython${major_version}.${minor_version}.dylib \ libpython.dylib" } platform puredarwin { configure.args-delete --enable-framework=${prefix}/Library/Frameworks configure.args-append --disable-toolbox-glue --disable-framework destroot.target install maninstall } platform macosx {} platform darwin i386 { if { [variant_isset macosx] } { # framework build chokes on OS X/ia32, too configure.args-delete --enable-framework=${prefix}/Library/Frameworks destroot.target install maninstall } } platform darwin 8 { configure.env CC=/usr/bin/gcc-4.0 CPP=/usr/bin/cpp-4.0 CXX=/usr/bin/g++-4.0 configure.args-append --with-cxx=/usr/bin/g++-4.0 }