2013-03-28 20:13:40 +00:00
|
|
|
# Template build file for 'python3'.
|
|
|
|
pkgname=python3
|
2013-11-20 06:52:19 +00:00
|
|
|
version=3.3.3
|
|
|
|
revision=1
|
2013-03-28 20:13:40 +00:00
|
|
|
wrksrc="Python-${version}"
|
|
|
|
short_desc="Interpreted, interactive, object-oriented programming language (3.x series)"
|
|
|
|
maintainer="Juan RP <xtraeme@gmail.com>"
|
|
|
|
homepage="http://www.python.org"
|
|
|
|
license="PSF"
|
|
|
|
distfiles="http://www.python.org/ftp/python/$version/Python-$version.tar.xz"
|
2013-11-20 06:52:19 +00:00
|
|
|
checksum=339275b30a1a3fef1589016bf6302c14e870f7a6fd2522bf87a6c2c6d383c685
|
2013-03-28 20:13:40 +00:00
|
|
|
|
|
|
|
makedepends="libffi-devel readline-devel gdbm-devel openssl-devel
|
2013-11-20 06:52:19 +00:00
|
|
|
expat-devel sqlite-devel bzip2-devel zlib-devel liblzma-devel"
|
2013-03-28 20:13:40 +00:00
|
|
|
|
|
|
|
pre_configure() {
|
|
|
|
sed -i -e "s|^#.* /usr/local/bin/python|#!/usr/bin/python3|" Lib/cgi.py
|
|
|
|
rm -r Modules/expat
|
|
|
|
rm -r Modules/zlib
|
|
|
|
rm -r Modules/_ctypes/{darwin,libffi}*
|
|
|
|
}
|
|
|
|
|
2013-04-08 23:49:27 +00:00
|
|
|
if [ "$CROSS_BUILD" ]; then
|
2013-03-28 20:13:40 +00:00
|
|
|
msg_error "$pkgname cannot be cross build.\n"
|
|
|
|
fi
|
|
|
|
|
|
|
|
# Native build
|
|
|
|
do_configure() {
|
|
|
|
# Force posix semaphores by default; sem_open requires /dev/shm and
|
|
|
|
# it's not mounted in chroot.
|
|
|
|
unset LD CC AR AS RANLIB
|
|
|
|
|
2013-05-26 08:41:55 +00:00
|
|
|
./configure ${configure_args} --with-threads --enable-ipv6 \
|
2013-03-28 20:13:40 +00:00
|
|
|
--with-signal-module --enable-shared --with-system-ffi \
|
|
|
|
--enable-unicode=ucs4 --with-system-expat --with-computed-gotos \
|
|
|
|
--with-system-expat --with-dbmliborder=gdbm:ndbm \
|
|
|
|
--disable-static ac_cv_posix_semaphores_enabled=yes
|
|
|
|
}
|
|
|
|
|
|
|
|
do_build() {
|
|
|
|
make ${makejobs}
|
|
|
|
}
|
|
|
|
|
|
|
|
do_install() {
|
2013-09-27 00:31:21 +00:00
|
|
|
make DESTDIR=${DESTDIR} install maninstall
|
2013-03-28 20:13:40 +00:00
|
|
|
install -Dm644 LICENSE ${DESTDIR}/usr/share/licenses/${pkgname}/LICENSE
|
|
|
|
|
2013-09-27 01:50:37 +00:00
|
|
|
rm -f ${DESTDIR}/usr/bin/2to3
|
|
|
|
|
2013-09-27 00:31:21 +00:00
|
|
|
ln -sf ../../libpython3.3m.so \
|
|
|
|
${DESTDIR}/usr/lib/python3.3/config-3.3m/libpython3.3m.so
|
2013-03-28 20:13:40 +00:00
|
|
|
}
|
2013-04-14 09:13:30 +00:00
|
|
|
|
|
|
|
python3-devel_package() {
|
2013-09-26 23:52:05 +00:00
|
|
|
depends="python3>=${version}_${revision}"
|
2013-09-17 07:11:04 +00:00
|
|
|
short_desc+=" - development files"
|
2013-04-14 09:13:30 +00:00
|
|
|
pkg_install() {
|
|
|
|
vmove "usr/bin/python*-config"
|
|
|
|
vmove usr/lib/pkgconfig
|
2013-09-26 23:52:05 +00:00
|
|
|
vmove usr/include
|
|
|
|
mkdir -p ${DESTDIR}/usr/include/python3.3m
|
|
|
|
mv ${PKGDESTDIR}/usr/include/python3.3m/pyconfig.h \
|
|
|
|
${DESTDIR}/usr/include/python3.3m
|
2013-04-14 09:13:30 +00:00
|
|
|
}
|
|
|
|
}
|