commit dfe1efb43ef5bcbd3f319347f8c0c1418848d5e6
Author: Jakub Bogusz <[email protected]>
Date:   Fri May 1 21:17:34 2020 +0200

    - updated to 1.1.10
    - added json-c patch (fixes build with json-c 0.14)

 libu2f-host-json-c.patch | 29 +++++++++++++++++++++++++++++
 libu2f-host.spec         |  8 +++++---
 2 files changed, 34 insertions(+), 3 deletions(-)
---
diff --git a/libu2f-host.spec b/libu2f-host.spec
index 927c464..7a0e6cf 100644
--- a/libu2f-host.spec
+++ b/libu2f-host.spec
@@ -6,12 +6,13 @@
 Summary:       Yubico Universal 2nd Factor (U2F) Host C Library
 Summary(pl.UTF-8):     Biblioteka C hosta Universal 2nd Factor (U2F) Yubico
 Name:          libu2f-host
-Version:       1.1.6
+Version:       1.1.10
 Release:       1
 License:       LGPL v2.1+ (library and tool), GPL v3+ (tests)
 Group:         Libraries
 Source0:       
https://developers.yubico.com/libu2f-host/Releases/%{name}-%{version}.tar.xz
-# Source0-md5: 2af0c9df26e290bb35b7f154b835ce8c
+# Source0-md5: 7664b0d5c9940bdefc934dce15db1baf
+Patch0:                %{name}-json-c.patch
 URL:           https://developers.yubico.com/libu2f-host/
 BuildRequires: gtk-doc >= 1.1
 BuildRequires: help2man
@@ -65,7 +66,7 @@ Summary:      API documentation for libu2f-host library
 Summary(pl.UTF-8):     Dokumentacja API biblioteki libu2f-host
 License:       LGPL v2.1+
 Group:         Documentation
-%if "%{_rpmversion}" >= "5"
+%if "%{_rpmversion}" >= "4.6"
 BuildArch:     noarch
 %endif
 
@@ -77,6 +78,7 @@ Dokumentacja API biblioteki libu2f-host.
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
 %configure \
diff --git a/libu2f-host-json-c.patch b/libu2f-host-json-c.patch
new file mode 100644
index 0000000..91f0e2a
--- /dev/null
+++ b/libu2f-host-json-c.patch
@@ -0,0 +1,29 @@
+--- libu2f-host-1.1.10/u2f-host/u2fmisc.c.orig 2019-02-22 12:31:45.000000000 
+0100
++++ libu2f-host-1.1.10/u2f-host/u2fmisc.c      2020-05-01 20:57:50.617146077 
+0200
+@@ -30,7 +30,7 @@
+ #define u2fh_json_object_object_get(obj, key, value) 
json_object_object_get_ex(obj, key, &value)
+ #else
+ typedef int json_bool;
+-#define u2fh_json_object_object_get(obj, key, value) (value = 
json_object_object_get(obj, key)) == NULL ? (json_bool)FALSE : (json_bool)TRUE
++#define u2fh_json_object_object_get(obj, key, value) (value = 
json_object_object_get(obj, key)) == NULL ? (json_bool)0 : (json_bool)1
+ #endif
+ 
+ static void
+@@ -114,7 +114,7 @@
+   if (debug)
+     fprintf (stderr, "JSON: %s\n", json_object_to_json_string (jo));
+ 
+-  if (u2fh_json_object_object_get (jo, "appId", k) == FALSE)
++  if (u2fh_json_object_object_get (jo, "appId", k) == 0)
+     return U2FH_JSON_ERROR;
+ 
+   app_id = json_object_get_string (k);
+@@ -390,7 +390,7 @@
+   if (debug)
+     fprintf (stderr, "JSON: %s\n", json_object_to_json_string (jo));
+ 
+-  if (u2fh_json_object_object_get (jo, key, k) == FALSE)
++  if (u2fh_json_object_object_get (jo, key, k) == 0)
+     return U2FH_JSON_ERROR;
+ 
+   urlb64 = json_object_get_string (k);
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/libu2f-host.git/commitdiff/dfe1efb43ef5bcbd3f319347f8c0c1418848d5e6

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to