[arch-commits] Commit in python-virtualenv/repos (testing-any testing-any/PKGBUILD)

Felix Yan felixonmars at archlinux.org
Thu Feb 16 17:10:50 UTC 2017


    Date: Thursday, February 16, 2017 @ 17:10:49
  Author: felixonmars
Revision: 289066

archrelease: copy trunk to testing-any

Added:
  python-virtualenv/repos/testing-any/
  python-virtualenv/repos/testing-any/PKGBUILD
    (from rev 289065, python-virtualenv/trunk/PKGBUILD)

----------+
 PKGBUILD |   49 +++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 49 insertions(+)

Copied: python-virtualenv/repos/testing-any/PKGBUILD (from rev 289065, python-virtualenv/trunk/PKGBUILD)
===================================================================
--- testing-any/PKGBUILD	                        (rev 0)
+++ testing-any/PKGBUILD	2017-02-16 17:10:49 UTC (rev 289066)
@@ -0,0 +1,49 @@
+# $Id$
+# Maintainer: Dan McGee <dan at archlinux.org>
+# Contributor: Daniele Paolella <dp at mcrservice.it>
+
+pkgname=('python-virtualenv' 'python2-virtualenv')
+pkgver=15.1.0
+pkgrel=1
+pkgdesc="Virtual Python Environment builder"
+url="https://virtualenv.pypa.io/"
+arch=('any')
+license=('MIT')
+makedepends=('python' 'python2')
+replaces=('virtualenv')
+conflicts=('virtualenv')
+source=("https://pypi.io/packages/source/v/virtualenv/virtualenv-$pkgver.tar.gz")
+md5sums=('44e19f4134906fe2d75124427dc9b716')
+sha256sums=('02f8102c2436bb03b3ee6dede1919d1dac8a427541652e5ec95171ec8adbc93a')
+
+package_python-virtualenv() {
+  depends=('python')
+
+  cd "$srcdir/virtualenv-$pkgver"
+  LANG='en_US.UTF-8' python3 setup.py build
+  LANG='en_US.UTF-8' python3 setup.py install --prefix=/usr --root="$pkgdir"
+
+  # link to a version with 3 suffix as well
+  ln "$pkgdir/usr/bin/virtualenv" "$pkgdir/usr/bin/virtualenv3"
+
+  install -D -m644 LICENSE.txt \
+    "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+}
+
+package_python2-virtualenv() {
+  depends=('python2')
+
+  cd "$srcdir/virtualenv-$pkgver"
+
+  # should report this upstream as still not fixed...
+  sed -i "s|#!/usr/bin/env python$|#!/usr/bin/env python2|" virtualenv.py
+
+  python2 setup.py build
+  python2 setup.py install --prefix=/usr --root="$pkgdir"
+
+  # move this "old" version out of the way
+  mv "$pkgdir/usr/bin/virtualenv" "$pkgdir/usr/bin/virtualenv2"
+
+  install -D -m644 LICENSE.txt \
+    "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+}



More information about the arch-commits mailing list