[arch-commits] Commit in python-munkres (3 files)

Maxime Gauduin alucryd at archlinux.org
Tue Jan 10 17:25:57 UTC 2017


    Date: Tuesday, January 10, 2017 @ 17:25:56
  Author: alucryd
Revision: 206609

archrelease: copy trunk to community-any

Added:
  python-munkres/repos/
  python-munkres/repos/community-any/
  python-munkres/repos/community-any/PKGBUILD
    (from rev 206608, python-munkres/trunk/PKGBUILD)

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

Copied: python-munkres/repos/community-any/PKGBUILD (from rev 206608, python-munkres/trunk/PKGBUILD)
===================================================================
--- repos/community-any/PKGBUILD	                        (rev 0)
+++ repos/community-any/PKGBUILD	2017-01-10 17:25:56 UTC (rev 206609)
@@ -0,0 +1,50 @@
+# $Id$
+# Maintainer: Maxime Gauduin <alucryd at archlinux.org>
+# Contributor: Adrian Sampson <adrian at radbox.org>
+
+pkgbase=python-munkres
+pkgname=('python-munkres' 'python2-munkres')
+pkgver=1.0.9
+pkgrel=1
+pkgdesc='Munkres algorithm for Python'
+arch=('any')
+url='https://github.com/bmc/munkres'
+license=('Apache')
+makedepends=('python-setuptools' 'python2-setuptools')
+source=("python-munkres-${pkgver}.tar.gz::https://github.com/bmc/munkres/archive/release-${pkgver}.tar.gz")
+sha256sums=('1dae30b882f409bab8d913af7bbf41877359b1ece3fa0ea31d6486a454f3493b')
+
+prepare() {
+  mv {,python-}munkres-release-${pkgver}
+  cp -r python{,2}-munkres-release-${pkgver}
+
+  cd python2-munkres-release-${pkgver}
+
+  sed 's|#!.*python$|#!/usr/bin/env python2|' -i $(grep -rl '#!.*python$')
+}
+
+build() {
+  for py in python{,2}; do
+    pushd ${py}-munkres-release-${pkgver}
+    ${py} setup.py build
+    popd
+  done
+}
+
+package_python-munkres() {
+  depends=('python')
+
+  cd python-munkres-release-${pkgver}
+
+  python setup.py install --root="${pkgdir}" --optimize='1'
+}
+
+package_python2-munkres() {
+  depends=('python2')
+
+  cd python2-munkres-release-${pkgver}
+
+  python2 setup.py install --root="${pkgdir}" --optimize='1'
+}
+
+# vim: ts=2 sw=2 et:



More information about the arch-commits mailing list