aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeo <thinkabit.ukim@gmail.com>2020-02-11 09:17:07 +0100
committerLeo <thinkabit.ukim@gmail.com>2020-02-11 09:17:07 +0100
commitb406fe9df4eb8fd64af769bac02dc05540555839 (patch)
treebad858804d95e78ac517badbfe431d139b3080a4
parent11b96bc0973073b4e3488001635e61b29a253f5d (diff)
downloadaports-b406fe9df4eb8fd64af769bac02dc05540555839.tar.gz
aports-b406fe9df4eb8fd64af769bac02dc05540555839.tar.bz2
aports-b406fe9df4eb8fd64af769bac02dc05540555839.tar.xz
community/py3-cu2qu: upgrade to 1.6.7
-rw-r--r--community/py3-cu2qu/3bd978bf0f011d8c7ee6ff21fb04815d6d80427d.patch68
-rw-r--r--community/py3-cu2qu/APKBUILD8
2 files changed, 3 insertions, 73 deletions
diff --git a/community/py3-cu2qu/3bd978bf0f011d8c7ee6ff21fb04815d6d80427d.patch b/community/py3-cu2qu/3bd978bf0f011d8c7ee6ff21fb04815d6d80427d.patch
deleted file mode 100644
index 01cf3f23a2..0000000000
--- a/community/py3-cu2qu/3bd978bf0f011d8c7ee6ff21fb04815d6d80427d.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-Fixes tests on x86; commit from upstream
-
-From 3bd978bf0f011d8c7ee6ff21fb04815d6d80427d Mon Sep 17 00:00:00 2001
-From: Cosimo Lupo <clupo@google.com>
-Date: Thu, 24 Oct 2019 12:17:34 +0100
-Subject: [PATCH] pens_test: compare float coordinates up to 12 decimal
- precision
-
-Fixes #186
----
- tests/pens_test.py | 2 +-
- tests/utils.py | 16 +++++++++++-----
- 2 files changed, 12 insertions(+), 6 deletions(-)
-
-diff --git a/tests/pens_test.py b/tests/pens_test.py
-index c861934..18e63a8 100644
---- a/tests/pens_test.py
-+++ b/tests/pens_test.py
-@@ -39,7 +39,7 @@ def convert_glyph(self, glyph, **kwargs):
- def expect_glyph(self, source, expected):
- converted = self.convert_glyph(source)
- self.assertNotEqual(converted, source)
-- if converted != expected:
-+ if not converted.approx(expected):
- print(self.diff(expected, converted))
- self.fail("converted glyph is different from expected")
-
-diff --git a/tests/utils.py b/tests/utils.py
-index 2706a71..b0d6c11 100644
---- a/tests/utils.py
-+++ b/tests/utils.py
-@@ -112,7 +112,7 @@ def __ne__(self, other):
- """Return True if 'other' glyph's outline is different from self."""
- return not (self == other)
-
-- def approx(self, other):
-+ def approx(self, other, rel_tol=1e-12):
- if hasattr(other, 'outline'):
- outline2 == other.outline
- elif hasattr(other, 'draw'):
-@@ -132,7 +132,10 @@ def approx(self, other):
- if not arg2 or not isinstance(arg2[0], tuple):
- return False
- for (x1, y1), (x2, y2) in zip(arg1, arg2):
-- if not isclose(x1, x2) or not isclose(y1, y2):
-+ if (
-+ not isclose(x1, x2, rel_tol=rel_tol) or
-+ not isclose(y1, y2, rel_tol=rel_tol)
-+ ):
- return False
- elif arg1 != arg2:
- return False
-@@ -208,9 +211,12 @@ def _repr_pen_commands(commands):
- for cmd, args, kwargs in commands:
- if args:
- if isinstance(args[0], tuple):
-- # cast float to int if there're no digits after decimal point
-- args = [tuple((int(v) if int(v) == v else v) for v in pt)
-- for pt in args]
-+ # cast float to int if there're no digits after decimal point,
-+ # and round floats to 12 decimal digits (more than enough)
-+ args = [
-+ tuple((int(v) if int(v) == v else round(v, 12)) for v in pt)
-+ for pt in args
-+ ]
- args = ", ".join(repr(a) for a in args)
- if kwargs:
- kwargs = ", ".join("%s=%r" % (k, v)
diff --git a/community/py3-cu2qu/APKBUILD b/community/py3-cu2qu/APKBUILD
index af5bff984c..92ce60b54f 100644
--- a/community/py3-cu2qu/APKBUILD
+++ b/community/py3-cu2qu/APKBUILD
@@ -1,7 +1,7 @@
# Contributor: Leo <thinkabit.ukim@gmail.com>
# Maintainer: Rasmus Thomsen <oss@cogitri.dev>
pkgname=py3-cu2qu
-pkgver=1.6.6
+pkgver=1.6.7
pkgrel=0
pkgdesc="Cubic-to-quadratic bezier curve conversion"
url="https://github.com/googlefonts/cu2qu"
@@ -10,8 +10,7 @@ license="Apache-2.0"
depends="python3 py3-fonttools py3-defcon"
makedepends="py3-setuptools python3-dev cython"
checkdepends="py3-pytest py3-coverage"
-source="$pkgname-$pkgver.tar.gz::https://github.com/googlefonts/cu2qu/archive/v$pkgver.tar.gz
- 3bd978bf0f011d8c7ee6ff21fb04815d6d80427d.patch"
+source="$pkgname-$pkgver.tar.gz::https://github.com/googlefonts/cu2qu/archive/v$pkgver.tar.gz"
builddir="$srcdir/cu2qu-$pkgver"
build() {
@@ -28,5 +27,4 @@ package() {
python3 setup.py install --prefix=/usr --root="$pkgdir"
}
-sha512sums="419ed7b822b2d5fc5237d33ba56882d27501c24c5000be23468a20f79be8af27637e8104ecaebc32898da067c55f3e1343d59c7b804da2f28765cee12def4ccf py3-cu2qu-1.6.6.tar.gz
-cc4fe15fc65bc13e1668e968890dd2c78a578b4f20385b1994c51b2d4783200f8d902c371a9f8e1ebfe7b251b5b5ad87621d11ff807d42c472bd00f095302c18 3bd978bf0f011d8c7ee6ff21fb04815d6d80427d.patch"
+sha512sums="5140db9fad305942a45faa405a70bcee389b03257889b82faa4704c8250c27c81273d28fa859701b4d05c439673887f07960f225563eb651bf5a8a93f7743b05 py3-cu2qu-1.6.7.tar.gz"