diff options
author | Daniel Wilhelm | 2016-12-02 15:16:46 +0100 |
---|---|---|
committer | Daniel Wilhelm | 2016-12-07 15:26:35 +0100 |
commit | f883d70c573abb6cfdc66c701fcd6c9b0217ade1 (patch) | |
tree | 64c2e94e28766eceb676d5e988085b33b80e4eba | |
parent | 3496cceb9d90177bde4a3e12e02504b1697d4c9f (diff) | |
download | aur-python-pyvcloud.tar.gz |
fix: do not copy source into destination directory
if makepkg is executed multiple times, the source directory
will not be copied into the existing destination directory anymore
-rw-r--r-- | PKGBUILD | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -18,12 +18,13 @@ source=("https://github.com/vmware/pyvcloud/archive/$pkgver.tar.gz") sha256sums=('962b4b3808fa032508544508210d6e0e5b985ae4935ec63ae93313f3c5be07ca') prepare() { - cp -a $_pkgname{,-py2}-$pkgver + test -d "$srcdir"/$_pkgname-py2-$pkgver || mkdir "$srcdir"/$_pkgname-py2-$pkgver + cp -a "$srcdir"/$_pkgname{-$pkgver/.,-py2-$pkgver/} find $_pkgname-$pkgver/pyvcloud -name \*.py -exec \ - sed -i "s:^#!.*bin.*python:#!/usr/bin/env python3:" {} + + sed -i "s:^#!.*bin.*python$:#!/usr/bin/env python3:" {} + find $_pkgname-py2-$pkgver/pyvcloud -name \*.py -exec \ - sed -i "s:^#!.*bin.*python:#!/usr/bin/env python2:" {} + + sed -i "s:^#!.*bin.*python$:#!/usr/bin/env python2:" {} + } package_python-pyvcloud() { |