CRUX-ARM : Home

Home :: Documentation :: Download :: Development :: Community :: Ports :: Packages :: Bugs :: Links :: About :: Donors
ldb: updated to 2.1.4
[ports/opt-arm64.git] / python / Pkgfile
CommitLineData
046fd99f
VM
1# Description: Python interpreter, version 2.7
2# URL: http://www.python.org
3# Maintainer: Juergen Daubert, jue at crux dot nu
4# Arch Maintainer: CRUX-ARM System Team, devel at crux-arm dot nu
5# Depends on: db gdbm openssl bzip2 zlib sqlite3
6
7name=python
470e2f20 8version=2.7.18
6f49a221 9release=2
046fd99f
VM
10source=(http://www.python.org/ftp/$name/$version/Python-$version.tar.xz \
11 pyconfig.h)
12
13build () {
14 cd Python-$version
15
6f49a221
VM
16 # remove 2to3, we use the one from python3
17 rm -r Lib/lib2to3
18
19 # remove tests
20 rm -r Lib/{bsddb,ctypes,email,lib-tk,sqlite3,unittest}/test
21 rm -r Lib/{{distutils,json}/tests,idlelib/idle_test,test}
22
046fd99f
VM
23 ./configure --prefix=/usr \
24 --enable-shared \
25 --with-threads \
26 --enable-ipv6
27
28 make
29 make -j1 DESTDIR=$PKG install
30
31 # fix issue with man-page symlink
32 ln -sf python2.7.1 $PKG/usr/share/man/man1/python.1
33
34 ln -sf python2.7 $PKG/usr/bin/python
35 ln -s python2.7 $PKG/usr/lib/python
36 ln -s python2.7 $PKG/usr/include/python
37 ln -s /usr/lib/libpython2.7.so $PKG/usr/lib/python2.7/config/libpython2.7.so
38
6f49a221
VM
39 rm $PKG/usr/bin/2to3
40 rm $PKG/usr/lib/python/{distutils,site-packages}/README
046fd99f
VM
41 rm $PKG/usr/lib/python/idlelib/{ChangeLog,{NEWS,README,TODO}.txt}
42 rm $PKG/usr/lib/python/ctypes/macholib/README.ctypes
43
44 mv $PKG/usr/include/python2.7/pyconfig{,-64}.h
45 install -m 0644 $SRC/pyconfig.h $PKG/usr/include/python2.7/
46}