From 716d393b20099e9933a04938b4beca8b438e8123 Mon Sep 17 00:00:00 2001 From: Alessio Sergi Date: Wed, 29 Jul 2015 01:19:17 +0200 Subject: [PATCH] python-sqlparse: update to 0.1.16 --- srcpkgs/python-sqlparse/template | 41 ++++++++++++++------------------ 1 file changed, 18 insertions(+), 23 deletions(-) diff --git a/srcpkgs/python-sqlparse/template b/srcpkgs/python-sqlparse/template index 2c1a3149e43..5816e5c0a35 100644 --- a/srcpkgs/python-sqlparse/template +++ b/srcpkgs/python-sqlparse/template @@ -1,6 +1,6 @@ # Template file for 'python-sqlparse' pkgname=python-sqlparse -version=0.1.15 +version=0.1.16 revision=1 noarch=yes wrksrc="sqlparse-${version}" @@ -13,35 +13,29 @@ maintainer="Alessio Sergi " homepage="https://github.com/andialbrecht/sqlparse" license="BSD" distfiles="${PYPI_SITE}/s/sqlparse/sqlparse-${version}.tar.gz" -checksum=ce92c9f134b1cd461a27c502197464b5f245261ad0fbb26d7bf659f28a5c11b2 - -post_extract() { - cp -a ${wrksrc} /tmp/python2.7-build - cp -a ${wrksrc} /tmp/python3.4-build - mv /tmp/python{2.7,3.4}-build ${wrksrc} -} +checksum=678c6c36ca4b01405177da8b84eecf92ec92c9f6c762396c965bb5d305f20f81 pre_build() { - cd ${wrksrc}/python3.4-build + cp -a ${wrksrc} /tmp/${pkgname#*-}-2.7 + cp -a ${wrksrc} /tmp/${pkgname#*-}-3.4 + mv /tmp/${pkgname#*-}-{2.7,3.4} ${wrksrc} + + cd ${pkgname#*-}-3.4 mv bin/sqlformat{,3} - sed -i 's,#!/usr/bin/env python,&3.4,' bin/sqlformat3 - sed -i "s,'bin/sqlformat','bin/sqlformat3'," setup.py + sed -i 's,\(bin/sqlformat\),\13,' setup.py } - do_build() { - cd ${wrksrc}/python2.7-build - python setup.py build - - cd ${wrksrc}/python3.4-build - python3.4 setup.py build + for pyver in $python_versions; do + cd ${wrksrc}/${pkgname#*-}-${pyver} + python${pyver} setup.py build + done } - do_install() { - cd ${wrksrc}/python2.7-build - python setup.py install --root=${DESTDIR} - - cd ${wrksrc}/python3.4-build - python3.4 setup.py install --root=${DESTDIR} + for pyver in $python_versions; do + cd ${wrksrc}/${pkgname#*-}-${pyver} + python${pyver} setup.py install --root=${DESTDIR} + done + vlicense COPYING LICENSE } python3.4-sqlparse_package() { @@ -53,5 +47,6 @@ python3.4-sqlparse_package() { pkg_install() { vmove usr/bin/sqlformat3 vmove usr/lib/python3.4 + vlicense COPYING LICENSE } }