diff options
author | Stuart Cardall <developer@it-offshore.co.uk> | 2017-02-27 20:52:48 +0000 |
---|---|---|
committer | William Pitcock <nenolod@dereferenced.org> | 2017-02-27 21:07:03 +0000 |
commit | f545df0dbccab1e92e362591da8525f1c65faf3d (patch) | |
tree | 76cd3ebfa3c3b373d9d844182d53934458ae3a4f /testing/py-yuicompressor | |
parent | 68d29786911e3b4dfec5dd5556e8f3d7422d6d11 (diff) | |
download | aports-f545df0dbccab1e92e362591da8525f1c65faf3d.tar.bz2 aports-f545df0dbccab1e92e362591da8525f1c65faf3d.tar.xz |
testing/py-yuicompressor: fix binary symlinks
Diffstat (limited to 'testing/py-yuicompressor')
-rw-r--r-- | testing/py-yuicompressor/APKBUILD | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/testing/py-yuicompressor/APKBUILD b/testing/py-yuicompressor/APKBUILD index a3852ef8f2..ab185d8da3 100644 --- a/testing/py-yuicompressor/APKBUILD +++ b/testing/py-yuicompressor/APKBUILD @@ -3,7 +3,7 @@ pkgname=py-yuicompressor _pkgname=${pkgname/py-/} pkgver=2.4.8 -pkgrel=0 +pkgrel=1 pkgdesc="YUI Compressor is a JavaScript and CSS minifier written in Java." url="https://pypi.python.org/pypi/yuicompressor" arch="noarch" @@ -21,7 +21,12 @@ build() { } package() { - mkdir -p "$pkgdir" + mkdir -p "$pkgdir"/usr/bin + + # Create unsuffixed symlinks for executables from py3 subpackage. + local name; for name in yuicompressor; do + ln -s $name-3 "$pkgdir"/usr/bin/$name || return 1 + done } _py2() { @@ -34,11 +39,17 @@ _py3() { _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" + + # Add version suffix to executable files. + local path; for path in "$subpkgdir"/usr/bin/*; do + mv "$path" "$path-$pyver" || return 1 + done } sha512sums="8e5dc2d2a4bea68961cbccad0cf6c5411f607f75b1b1b6f351560d6fa9862a124a5d277f7bf8b62261439e45fd32441cd4555b7c902b6bc48df3d5357e43505e py-yuicompressor-2.4.8.tar.gz" |