[arch-commits] Commit in python/trunk (PKGBUILD)

Felix Yan felixonmars at archlinux.org
Sat Dec 24 08:57:30 UTC 2016


    Date: Saturday, December 24, 2016 @ 08:57:29
  Author: felixonmars
Revision: 284550

upgpkg: python 3.6.0-1

Modified:
  python/trunk/PKGBUILD

----------+
 PKGBUILD |   45 +++++++++++++++++----------------------------
 1 file changed, 17 insertions(+), 28 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2016-12-24 08:49:23 UTC (rev 284549)
+++ PKGBUILD	2016-12-24 08:57:29 UTC (rev 284550)
@@ -6,16 +6,15 @@
 # Contributor: Jason Chu <jason at archlinux.org>
 
 pkgname=python
-pkgver=3.5.2
-pkgrel=3
-_pybasever=3.5
+pkgver=3.6.0
+pkgrel=1
+_pybasever=3.6
 pkgdesc="Next generation of the python high-level scripting language"
 arch=('i686' 'x86_64')
 license=('custom')
 url="http://www.python.org/"
 depends=('expat' 'bzip2' 'gdbm' 'openssl' 'libffi' 'zlib')
-makedepends=('tk' 'sqlite' 'valgrind' 'bluez-libs' 'mpdecimal')
-checkdepends=('gdb' 'xorg-server-xvfb')
+makedepends=('tk' 'sqlite' 'valgrind' 'bluez-libs' 'mpdecimal' 'llvm' 'gdb' 'xorg-server-xvfb')
 optdepends=('python-setuptools'
             'python-pip'
             'sqlite'
@@ -22,15 +21,14 @@
             'mpdecimal: for decimal'
             'xz: for lzma'
             'tk: for tkinter')
-options=('!makeflags')
 provides=('python3')
 replaces=('python3')
 source=("https://www.python.org/ftp/python/${pkgver%rc*}/Python-${pkgver}.tar.xz"{,.asc}
         dont-make-libpython-readonly.patch)
-sha1sums=('4843aabacec5bc0cdd3e1f778faa926e532794d2'
+sha1sums=('18ebf7d726782967d967dc00e3aa08b334fbdd5c'
           'SKIP'
           'c22b24324b8e53326702de439c401d97927ee3f2')
-validpgpkeys=('97FC712E4C024BBEA48A61ED3A5CA953F73C700D')  # Larry Hastings <larry at hastings.org>
+validpgpkeys=('0D96DF4D4110E5C43FBFB17F2D347EA6AA65421D')  # Ned Deily (Python release signing key) <nad at python.org>
 
 prepare() {
   cd Python-${pkgver}
@@ -57,6 +55,8 @@
               --enable-shared \
               --with-threads \
               --with-computed-gotos \
+              --enable-optimizations \
+              --with-lto \
               --enable-ipv6 \
               --with-system-expat \
               --with-dbmliborder=gdbm:ndbm \
@@ -65,30 +65,26 @@
               --enable-loadable-sqlite-extensions \
               --without-ensurepip
 
-  make EXTRA_CFLAGS="$CFLAGS"
+  LC_CTYPE=en_US.UTF-8 xvfb-run make EXTRA_CFLAGS="$CFLAGS"
 }
 
 check() {
-  # Failures:
-  # test_distutils: because of our EXTRA_CFLAGS
-  # test_socket
+  # test_gdb is expected to fail with LTO
 
-  # Hacks:
-  # test_tk: xvfb-run
-  # test_unicode_file: LC_CTYPE=en_US.utf-8
-  # test_gdb: SHELL=/bin/sh
-
   cd Python-${pkgver}
-  SHELL=/bin/sh \
   LD_LIBRARY_PATH="${srcdir}/Python-${pkgver}":${LD_LIBRARY_PATH} \
-  LC_CTYPE=en_US.utf-8 xvfb-run \
-    "${srcdir}/Python-${pkgver}/python" -m test.regrtest -v -uall || warning "Expected failure"
+  LC_CTYPE=en_US.UTF-8 xvfb-run \
+    "${srcdir}/Python-${pkgver}/python" -m test.regrtest -v -uall -x test_gdb
 }
 
 package() {
   cd Python-${pkgver}
-  make DESTDIR="${pkgdir}" EXTRA_CFLAGS="$CFLAGS" install maninstall
 
+  # Hack to avoid building again
+  sed -i 's/^all:.*$/all: build_all/' Makefile
+
+  make DESTDIR="${pkgdir}" EXTRA_CFLAGS="$CFLAGS" install
+
   # Why are these not done by default...
   ln -s python3               "${pkgdir}"/usr/bin/python
   ln -s python3-config        "${pkgdir}"/usr/bin/python-config
@@ -96,18 +92,11 @@
   ln -s pydoc3                "${pkgdir}"/usr/bin/pydoc
   ln -s python${_pybasever}.1 "${pkgdir}"/usr/share/man/man1/python.1
 
-  # Fix FS#22552
-  ln -sf ../../libpython${_pybasever}m.so \
-    "${pkgdir}/usr/lib/python${_pybasever}/config-${_pybasever}m/libpython${_pybasever}m.so"
-
   # some useful "stuff" FS#46146
   install -dm755 "${pkgdir}"/usr/lib/python${_pybasever}/Tools/{i18n,scripts}
   install -m755 Tools/i18n/{msgfmt,pygettext}.py "${pkgdir}"/usr/lib/python${_pybasever}/Tools/i18n/
   install -m755 Tools/scripts/{README,*py} "${pkgdir}"/usr/lib/python${_pybasever}/Tools/scripts/
 
-  # Clean-up reference to build directory
-  sed -i "s|$srcdir/Python-${pkgver}:||" "$pkgdir/usr/lib/python${_pybasever}/config-${_pybasever}m/Makefile"
-
   # License
   install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
 }



More information about the arch-commits mailing list