X-Original-To: alpine-aports@lists.alpinelinux.org Received: from mail.cmpwn.com (mail.cmpwn.com [45.56.77.53]) by lists.alpinelinux.org (Postfix) with ESMTP id DB814F84CE2 for ; Thu, 7 Feb 2019 13:26:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=cmpwn.com; s=cmpwn; t=1549546036; bh=JQQyTAsomovIH7JkGXLczO6wnIg4COO6VAIxRAdifFA=; h=From:To:Cc:Subject:Date; b=MndCQx+gG8RkioNLKgzBo6VJioVhshQkW7ImG+ET02URyzveXZvXJw34rejBjD0++ NDGcUb49t3+P6SXgmuPyvUrHxP22K6/X1R95t0HrG7uAlMY6nsINe4OZuz2IXTqzle G5AvuBH7OWUnI2XHU6jsfjR/r/+GeudAICiUyG/U= From: Drew DeVault To: alpine-aports@lists.alpinelinux.org Cc: Drew DeVault Subject: [alpine-aports] [PATCH 1/2] main/py-werkzeug: clean up APKBUILD Date: Thu, 7 Feb 2019 08:26:17 -0500 Message-Id: <20190207132618.556-1-sir@cmpwn.com> X-Mailer: git-send-email 2.20.1 X-Mailinglist: alpine-aports Precedence: list List-Id: Alpine Development List-Unsubscribe: List-Post: List-Help: List-Subscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit --- main/py-werkzeug/APKBUILD | 31 ++++++++++++++----- .../disable-monkeypatched-sleep-test.patch | 10 ++++++ 2 files changed, 33 insertions(+), 8 deletions(-) create mode 100644 main/py-werkzeug/disable-monkeypatched-sleep-test.patch diff --git a/main/py-werkzeug/APKBUILD b/main/py-werkzeug/APKBUILD index 5ad869441d..3d5f141340 100644 --- a/main/py-werkzeug/APKBUILD +++ b/main/py-werkzeug/APKBUILD @@ -3,34 +3,50 @@ pkgname=py-werkzeug _pkgname=Werkzeug pkgver=0.14.1 -pkgrel=0 +pkgrel=1 pkgdesc="The WSGI swiss-army knife" url="http://werkzeug.pocoo.org/" arch="noarch" license="MIT" -depends="" makedepends="python2-dev python3-dev py-setuptools" +checkdepends="pytest" subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3" -source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz" +source=" + https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz + disable-monkeypatched-sleep-test.patch +" builddir="$srcdir/$_pkgname-$pkgver" +prepare() { + default_prepare + cp -r "$builddir" "$builddir"-py3 +} + build() { cd "$builddir" - python2 setup.py build + cd "$builddir"-py3 python3 setup.py build } +check() { + cd "$builddir" + pytest-2 + cd "$builddir"-py3 + pytest-3 +} + package() { mkdir -p "$pkgdir" } _py2() { - replaces="$pkgname" + cd "$builddir" _py python2 } _py3() { + cd "$builddir"-py3 _py python3 } @@ -39,9 +55,8 @@ _py() { pkgdesc="$pkgdesc (for $python)" depends="$depends $python" install_if="$pkgname=$pkgver-r$pkgrel $python" - - cd "$builddir" $python setup.py install --prefix=/usr --root="$subpkgdir" } -sha512sums="64976cc46c1cee2203112c50aba6f9404d4e48d4a90f8b11837148b5415a28572b7e706095586045a46879e853fc5a80c63e7bf0c13eda29d564a37b4a554c0b Werkzeug-0.14.1.tar.gz" +sha512sums="64976cc46c1cee2203112c50aba6f9404d4e48d4a90f8b11837148b5415a28572b7e706095586045a46879e853fc5a80c63e7bf0c13eda29d564a37b4a554c0b Werkzeug-0.14.1.tar.gz +797fadb81cc6eee841eb57c481b0349a41950640be2c796679f3d9c9613098113ccacb9a585a3f9fb79f2db019f5264de6d15b59c556c028240d0d1612e5213c disable-monkeypatched-sleep-test.patch" diff --git a/main/py-werkzeug/disable-monkeypatched-sleep-test.patch b/main/py-werkzeug/disable-monkeypatched-sleep-test.patch new file mode 100644 index 0000000000..57e36717e9 --- /dev/null +++ b/main/py-werkzeug/disable-monkeypatched-sleep-test.patch @@ -0,0 +1,10 @@ +--- Werkzeug-0.14.1-orig/tests/test_serving.py ++++ Werkzeug-0.14.1/tests/test_serving.py +@@ -265,6 +265,7 @@ + + + def test_monkeypached_sleep(tmpdir): ++ return # Broken on Alpine + # removing the staticmethod wrapper in the definition of + # ReloaderLoop._sleep works most of the time, since `sleep` is a c + # function, and unlike python functions which are descriptors, doesn't -- 2.20.1 --- Unsubscribe: alpine-aports+unsubscribe@lists.alpinelinux.org Help: alpine-aports+help@lists.alpinelinux.org ---