milis/talimatname/genel/p/python3/talimat

62 lines
1.8 KiB
Plaintext
Raw Normal View History

2018-06-09 00:06:58 +02:00
# Tanım: Sonraki nesil python üst düzey betik dili
# URL: http://www.python.org
# Paketçi: milisarge
2018-08-13 21:36:54 +02:00
# Gerekler: sqlite libffi tk
2018-08-01 08:45:17 +02:00
# Grup: geliştirme
2018-06-09 00:06:58 +02:00
isim=python3
2018-08-13 21:36:54 +02:00
surum=3.7.0
2018-06-09 00:06:58 +02:00
devir=1
2018-08-13 21:36:54 +02:00
kaynak=(http://www.python.org/ftp/python/$surum/Python-$surum.tar.xz
bpo34056-always-return-bytes-from-_HackedGetData.get_data.patch
dont-make-libpython-readonly.patch)
2018-06-09 00:06:58 +02:00
derle() {
2018-08-13 21:36:54 +02:00
_pybasever=${surum%.*}
2018-06-09 00:06:58 +02:00
cd Python-$surum
2018-08-13 21:36:54 +02:00
# https://bugs.python.org/issue34056
patch -Np1 -i ../bpo34056-always-return-bytes-from-_HackedGetData.get_data.patch
2018-06-09 00:06:58 +02:00
2018-08-13 21:36:54 +02:00
# FS#45809
patch -p1 -i ../dont-make-libpython-readonly.patch
2018-06-09 00:06:58 +02:00
2018-08-13 21:36:54 +02:00
# FS#23997
2018-08-13 22:20:09 +02:00
sed -i -e "s|^#.* /usr/local/bin/python|#!/usr/bin/python3|" Lib/cgi.py
2018-06-09 00:06:58 +02:00
2018-08-13 21:36:54 +02:00
# Ensure that we are using the system copy of various libraries (expat, libffi, and libmpdec),
# rather than copies shipped in the tarball
rm -r Modules/expat
rm -r Modules/_ctypes/{darwin,libffi}*
rm -r Modules/_decimal/libmpdec
./configure --prefix=/usr \
--enable-shared \
--with-threads \
--with-computed-gotos \
--enable-optimizations \
--with-lto \
--enable-ipv6 \
--with-system-expat \
--with-dbmliborder=gdbm:ndbm \
--with-system-ffi \
--with-system-libmpdec \
--enable-loadable-sqlite-extensions \
--without-ensurepip
make
sed -i 's/^all:.*$/all: build_all/' Makefile
make DESTDIR="${PKG}" EXTRA_CFLAGS="$CFLAGS" install
install -dm755 "${PKG}"/usr/lib/python${_pybasever}/Tools/{i18n,scripts}
install -m755 Tools/i18n/{msgfmt,pygettext}.py "${PKG}"/usr/lib/python${_pybasever}/Tools/i18n/
install -m755 Tools/scripts/{README,*py} "${PKG}"/usr/lib/python${_pybasever}/Tools/scripts/
2018-06-09 00:06:58 +02:00
2018-08-13 22:20:09 +02:00
# Lisans
install -Dm644 LICENSE "${PKG}/usr/share/licenses/${isim}/LICENSE"
2018-06-09 00:06:58 +02:00
}