comparison python/python2/python2.sh @ 1216:6710613b88b9

misc: remove build function
author David Demelier <markand@malikania.fr>
date Wed, 29 Sep 2021 13:49:32 +0200
parents c9592a9a949b
children 57dc83a39b13
comparison
equal deleted inserted replaced
1215:3214f7fed454 1216:6710613b88b9
38 with_ipv6="--enable-ipv6" 38 with_ipv6="--enable-ipv6"
39 else 39 else
40 with_ipv6="--disable-ipv6" 40 with_ipv6="--disable-ipv6"
41 fi 41 fi
42 42
43 build() 43 rm -rf Python-$PKGVERSION
44 { 44 tar xvf Python-$PKGVERSION.tar.xz
45 rm -rf Python-$PKGVERSION 45 cd Python-$PKGVERSION
46 tar xvf Python-$PKGVERSION.tar.xz
47 cd Python-$PKGVERSION
48 46
49 CC="$CC" \ 47 CC="$CC" \
50 CFLAGS="$CFLAGS" \ 48 CFLAGS="$CFLAGS" \
51 LDFLAGS="$LDFLAGS" \ 49 LDFLAGS="$LDFLAGS" \
52 LIBS="$LIBS" \ 50 LIBS="$LIBS" \
53 ./configure \ 51 ./configure \
54 --build=$CBUILD \ 52 --build=$CBUILD \
55 --host=$CHOST \ 53 --host=$CHOST \
56 --target=$CTARGET \ 54 --target=$CTARGET \
57 --prefix=/. \ 55 --prefix=/. \
58 --enable-shared \ 56 --enable-shared \
59 --with-system-expat \ 57 --with-system-expat \
60 --with-system-ffi \ 58 --with-system-ffi \
61 $with_ipv6 59 $with_ipv6
62 make 60 make
63 make DESTDIR=$DESTDIR altinstall maninstall 61 make DESTDIR=$DESTDIR altinstall maninstall
64 ln -sf python2.7 $DESTDIR/bin/python2 62 ln -sf python2.7 $DESTDIR/bin/python2
65 63
66 # Avoid conflicts with Python 3. 64 # Avoid conflicts with Python 3.
67 rm -f $DESTDIR/bin/2to3 65 rm -f $DESTDIR/bin/2to3
68 mv $DESTDIR/bin/smtpd.py $DESTDIR/bin/smtpd.py2.7 66 mv $DESTDIR/bin/smtpd.py $DESTDIR/bin/smtpd.py2.7
69 mv $DESTDIR/bin/idle $DESTDIR/bin/idle2.7 67 mv $DESTDIR/bin/idle $DESTDIR/bin/idle2.7
70 mv $DESTDIR/bin/pydoc $DESTDIR/bin/pydoc2.7 68 mv $DESTDIR/bin/pydoc $DESTDIR/bin/pydoc2.7
71 69
72 cd .. 70 cd ..
73 rm -rf Python-$PKGVERSION 71 rm -rf Python-$PKGVERSION
74 }