diff options
author | Leo <thinkabit.ukim@gmail.com> | 2019-08-27 22:41:28 -0300 |
---|---|---|
committer | Leo <thinkabit.ukim@gmail.com> | 2019-08-28 14:37:56 -0300 |
commit | b42bff67f2fc532fc9f7ae48967e05667f6fabcb (patch) | |
tree | e1937cd5f5be02144b7fcdefc47b4b5773d59eec /community/libwacom | |
parent | b65cdca87b96f9ab305c175f54b76eebe6a391fa (diff) | |
download | aports-b42bff67f2fc532fc9f7ae48967e05667f6fabcb.tar.bz2 aports-b42bff67f2fc532fc9f7ae48967e05667f6fabcb.tar.xz |
community/libwacom: upgrade to 1.0
Diffstat (limited to 'community/libwacom')
-rw-r--r-- | community/libwacom/APKBUILD | 25 | ||||
-rw-r--r-- | community/libwacom/disable-tests.patch | 33 | ||||
-rw-r--r-- | community/libwacom/fix-parsing-of-matching-strings-when-using-musl.patch | 47 |
3 files changed, 45 insertions, 60 deletions
diff --git a/community/libwacom/APKBUILD b/community/libwacom/APKBUILD index 6fa2b9078b..16aafeb8f1 100644 --- a/community/libwacom/APKBUILD +++ b/community/libwacom/APKBUILD @@ -1,34 +1,33 @@ # Contributor: Ivan Tham <pickfire@riseup.net> # Maintainer: Ivan Tham <pickfire@riseup.net> pkgname=libwacom -pkgver=0.33 +pkgver=1.0 pkgrel=0 pkgdesc="Library to help implement Wacom tablet settings" url="https://github.com/linuxwacom/libwacom/wiki" arch="all" license="MIT" -makedepends="libgudev-dev libxml2-dev glib-dev" -checkdepends="bash findutils" +makedepends="librsvg-dev gtk+2.0-dev glib-dev libgudev-dev meson" +checkdepends="bash findutils diffutils" subpackages="$pkgname-dev $pkgname-doc" source="https://github.com/linuxwacom/libwacom/releases/download/libwacom-$pkgver/libwacom-$pkgver.tar.bz2 - fix-parsing-of-matching-strings-when-using-musl.patch + disable-tests.patch " build() { - ./configure --prefix=/usr --disable-static - make + meson \ + --prefix=/usr \ + . output + ninja -C output } check() { - make check + ninja -C output test } package() { - make DESTDIR="$pkgdir" install - install -dm755 "$pkgdir"/usr/lib/udev/rules.d/ - tools/generate-udev-rules - > "$pkgdir"/usr/lib/udev/rules.d/65-libwacom.rules + DESTDIR="$pkgdir" ninja -C output install } -sha512sums="de4d9cf3b5f4d87a159ba8ee617bafce9d13b67dc23d9dc67efd57317b0df2079dd0de328bc800de47f14ee49ea82bb842e34297cef23ba336c1ddca3afa826d libwacom-0.33.tar.bz2 -5f3f87e21b94ece374e994f1daafc911baf7efa1dfad9e2ef41d86a9422a0d778525fffde775235aa8f8ea8d12e3d7130caf1981353a990784af9b0c0ddf8aa1 fix-parsing-of-matching-strings-when-using-musl.patch" +sha512sums="43a8098ed06c86edc647d6a6b0ee0b465bcb6089df77fd361909271aaf5f18ae2fecfa34062fd4a9fdee6983ff1303b99636485ebde6a75a669307bd19c2b313 libwacom-1.0.tar.bz2 +2d15058bc985b3f70dd1784fceefe86bedb50e269b1b981d101d0c284ec1650de7a2f53d0b7474cc719d44aa54c1879b2d0c09ac717f4408c09178b74b7a141e disable-tests.patch" diff --git a/community/libwacom/disable-tests.patch b/community/libwacom/disable-tests.patch new file mode 100644 index 0000000000..b102859582 --- /dev/null +++ b/community/libwacom/disable-tests.patch @@ -0,0 +1,33 @@ +diff --git a/meson.build b/meson.build +index 6584c86..9368567 100644 +--- a/meson.build ++++ b/meson.build +@@ -392,13 +392,6 @@ test('svg-layout-exists', + args: [meson.source_root()], + suite: ['all']) + +-# meson requires that we specify all files one-by-one, so let's add a test +-# that we can't forget about that. +-test('data-files-in-meson.build', +- find_program('data/check-data-in-meson.build.sh'), +- args: [meson.source_root()], +- suite: ['all']) +- + ############### tools ########################### + + executable('libwacom-list-local-devices', +@@ -533,13 +526,6 @@ if get_option('tests') + message('valgrind not found, disabling valgrind test suite') + endif + +- test_deprecated = executable('test-deprecated', +- 'test/test-deprecated.c', +- dependencies: [dep_libwacom, dep_dl], +- include_directories: [includes_src], +- c_args: tests_cflags, +- install: false) +- test('test-deprecated', test_deprecated, suite: ['all']) + endif + + # This is a non-optional test + diff --git a/community/libwacom/fix-parsing-of-matching-strings-when-using-musl.patch b/community/libwacom/fix-parsing-of-matching-strings-when-using-musl.patch deleted file mode 100644 index 26ce1229c4..0000000000 --- a/community/libwacom/fix-parsing-of-matching-strings-when-using-musl.patch +++ /dev/null @@ -1,47 +0,0 @@ -From ef7229064e88dfea3889c7d6cba80c1edc70470b Mon Sep 17 00:00:00 2001 -From: Jason Gerecke <jason.gerecke@wacom.com> -Date: Wed, 17 Jul 2019 10:55:08 -0700 -Subject: [PATCH] Fix parsing of match strings when using musl - -Several tests fail when running on a system with the musl libc library -with the error "Duplicate match of 'usb:256c:006e' on device 'Huion H420'". -The root cause appears to be musl's handling of '%63c' in our format string. -Specifically, unlike glibc which interprets this to mean "read up to 63 -characters", musl interprets it as "read exactly 63 characters". - -This commit tweaks our format string to extract the first three required -fields and probe (with ':%n') to see if more data follows. In such a case -we can directly strdup the remainder of the string. - -Ref: https://github.com/linuxwacom/libwacom/issues/85 -Signed-off-by: Jason Gerecke <jason.gerecke@wacom.com> ---- - libwacom/libwacom-database.c | 13 ++++++------- - 1 file changed, 6 insertions(+), 7 deletions(-) - -diff --git a/libwacom/libwacom-database.c b/libwacom/libwacom-database.c -index 61572ec..c34a4f6 100644 ---- a/libwacom/libwacom-database.c -+++ b/libwacom/libwacom-database.c -@@ -147,14 +147,13 @@ make_match_string (const char *name, WacomBusType bus, int vendor_id, int produc - static gboolean - match_from_string(const char *str, WacomBusType *bus, int *vendor_id, int *product_id, char **name) - { -- int rc = 1; -- char busstr[64], namestr[64]; -+ int rc = 1, len = 0; -+ char busstr[64]; - -- memset(namestr, 0, sizeof(namestr)); -- -- rc = sscanf(str, "%63[^:]:%x:%x:%63c", busstr, vendor_id, product_id, namestr); -- if (rc == 4) { -- *name = g_strdup(namestr); -+ rc = sscanf(str, "%63[^:]:%x:%x:%n", busstr, vendor_id, product_id, &len); -+ if (len > 0) { -+ /* Grumble grumble scanf handling of %n */ -+ *name = g_strdup(str+len); - } else if (rc == 3) { - *name = NULL; - } else { - |