diff options
author | Leo <thinkabit.ukim@gmail.com> | 2019-09-07 23:08:07 -0300 |
---|---|---|
committer | Leo <thinkabit.ukim@gmail.com> | 2019-09-07 23:08:44 -0300 |
commit | 7d3ffdea5c31d16ff37f6969261fcc44191681ad (patch) | |
tree | 961cda95d42b06926fb33456710550e1299e667f /community/py3-yuicompressor | |
parent | 4f80f4e21bfcd57346350c0add5a8e459695d761 (diff) | |
download | aports-7d3ffdea5c31d16ff37f6969261fcc44191681ad.tar.bz2 aports-7d3ffdea5c31d16ff37f6969261fcc44191681ad.tar.xz |
community/py3-yuicompressor: drop py2
Diffstat (limited to 'community/py3-yuicompressor')
-rw-r--r-- | community/py3-yuicompressor/APKBUILD | 51 |
1 files changed, 16 insertions, 35 deletions
diff --git a/community/py3-yuicompressor/APKBUILD b/community/py3-yuicompressor/APKBUILD index cad9d86ef9..72f3f3ccfd 100644 --- a/community/py3-yuicompressor/APKBUILD +++ b/community/py3-yuicompressor/APKBUILD @@ -1,54 +1,35 @@ # Contributor: Stuart Cardall <developer@it-offshore.co.uk> # Maintainer: Stuart Cardall <developer@it-offshore.co.uk> -pkgname=py-yuicompressor -_pkgname=${pkgname#py-} +pkgname=py3-yuicompressor +_pkgname=yuicompressor pkgver=2.4.8 -pkgrel=2 +pkgrel=3 pkgdesc="YUI Compressor is a JavaScript and CSS minifier written in Java." url="https://pypi.python.org/pypi/yuicompressor" arch="noarch" -license="BSD" -depends="openjdk8-jre-base" -makedepends="python2-dev python3-dev py-setuptools" -subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3" +license="BSD-3-Clause" +depends="openjdk8-jre-base python3" +makedepends="py3-setuptools" source="$pkgname-$pkgver.tar.gz::https://github.com/sprat/yuicompressor/archive/$pkgver.tar.gz" builddir="$srcdir/$_pkgname-$pkgver" +replaces="py-yuicompressor" # Backwards compatibility +provides="py-yuicompressor=$pkgver-r$pkgrel" # Backwards compatibility + build() { - cd "$builddir" - python2 setup.py build python3 setup.py build } package() { - mkdir -p "$pkgdir"/usr/bin - - # Create unsuffixed symlink for executable from py3 subpackage. - ln -s yuicompressor-3 "$pkgdir"/usr/bin/yuicompressor -} - -_py2() { - _py python2 -} - -_py3() { - _py python3 -} - -_py() { - local python="$1" - local pyver="${1:6:1}" - pkgdesc="$pkgdesc (for $python)" - depends="$depends $python" ## remove if arch isn't noarch - install_if="$pkgname=$pkgver-r$pkgrel $python" - - cd "$builddir" - $python setup.py install --prefix=/usr --root="$subpkgdir" + python3 setup.py install --prefix=/usr --root="$pkgdir" # Add version suffix to executable files. - local path; for path in "$subpkgdir"/usr/bin/*; do - mv "$path" "$path-$pyver" + local path; for path in "$pkgdir"/usr/bin/*; do + mv "$path" "$path"-3 done + + # Create unsuffixed symlink for executable from py3 subpackage. + ln -s yuicompressor-3 "$pkgdir"/usr/bin/yuicompressor } -sha512sums="8e5dc2d2a4bea68961cbccad0cf6c5411f607f75b1b1b6f351560d6fa9862a124a5d277f7bf8b62261439e45fd32441cd4555b7c902b6bc48df3d5357e43505e py-yuicompressor-2.4.8.tar.gz" +sha512sums="8e5dc2d2a4bea68961cbccad0cf6c5411f607f75b1b1b6f351560d6fa9862a124a5d277f7bf8b62261439e45fd32441cd4555b7c902b6bc48df3d5357e43505e py3-yuicompressor-2.4.8.tar.gz" |