From f9e803f573a3cd12b5b05abc712ae488c3129964 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Jul 25 2019 22:08:39 +0000 Subject: libratbag 0.9.906 --- diff --git a/0001-Use-python3-embed-as-dependency-on-Python-3.8.patch b/0001-Use-python3-embed-as-dependency-on-Python-3.8.patch deleted file mode 100644 index acf3683..0000000 --- a/0001-Use-python3-embed-as-dependency-on-Python-3.8.patch +++ /dev/null @@ -1,39 +0,0 @@ -From 1329f3ed35e2f7c2d20b92b4df9a2f24123c7575 Mon Sep 17 00:00:00 2001 -From: Peter Hutterer -Date: Wed, 17 Jul 2019 12:46:58 +1000 -Subject: [PATCH libratbag] Use python3-embed as dependency on Python 3.8 - -Python 3.8 no longer links to libpython, resulting in undefined references to -Python API. - -But it provides a python3-embed.pc now, so let's try using that first and only -fall back on the normal case if that fails. - -See https://github.com/mesonbuild/meson/issues/5629 ---- - meson.build | 8 +++++++- - 1 file changed, 7 insertions(+), 1 deletion(-) - -diff --git a/meson.build b/meson.build -index 468bdfa3..34804919 100644 ---- a/meson.build -+++ b/meson.build -@@ -549,8 +549,14 @@ swig_gen = generator( - '@INPUT@'], - ) - -+# From python 3.8 we neeed python3-embed -+dep_python3 = dependency('python3-embed', required: false) -+if not dep_python3.found() -+ dep_python3 = dependency('python3') -+endif -+ - wrapper_deps = [ -- dependency('python3'), -+ dep_python3, - dep_libratbag, - dep_libshared, - ] --- -2.21.0 - diff --git a/0001-hidpp20-fix-warnings.patch b/0001-hidpp20-fix-warnings.patch new file mode 100644 index 0000000..e792064 --- /dev/null +++ b/0001-hidpp20-fix-warnings.patch @@ -0,0 +1,64 @@ +From 7a14026f2dfb1b607d0d0353fcb4155bca6f511e Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Filipe=20La=C3=ADns?= +Date: Wed, 17 Jul 2019 15:13:51 +0100 +Subject: [PATCH libratbag] hidpp20: fix warnings +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Signed-off-by: Filipe LaĆ­ns +--- + src/hidpp20.c | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +diff --git a/src/hidpp20.c b/src/hidpp20.c +index 9bc6b927..4abf19e8 100644 +--- a/src/hidpp20.c ++++ b/src/hidpp20.c +@@ -1540,7 +1540,7 @@ hidpp20_onboard_profiles_read_sector(struct hidpp20_device *device, + .msg.address = CMD_ONBOARD_PROFILES_MEMORY_READ, + }; + +- hidpp_log_debug(device, "Reading sector 0x%04x\n", sector); ++ hidpp_log_debug(&device->base, "Reading sector 0x%04x\n", sector); + + feature_index = hidpp_root_get_feature_idx(device, + HIDPP_PAGE_ONBOARD_PROFILES); +@@ -1590,7 +1590,7 @@ hidpp20_onboard_profiles_is_sector_valid(struct hidpp20_device *device, + read_crc = hidpp_get_unaligned_be_u16(&data[sector_size - 2]); + + if (crc != read_crc) +- hidpp_log_debug(device, "Invalid CRC (%04x != %04x)\n", read_crc, crc); ++ hidpp_log_debug(&device->base, "Invalid CRC (%04x != %04x)\n", read_crc, crc); + + return crc == read_crc; + } +@@ -2447,14 +2447,14 @@ hidpp20_onboard_profiles_initialize(struct hidpp20_device *device, + profiles->profiles[i].enabled = !!d[HIDPP20_PROFILE_DIR_ENABLED]; + } + } else { +- hidpp_log_debug(device, "Profile directory has an invalid CRC... Reading ROM profiles.\n"); ++ hidpp_log_debug(&device->base, "Profile directory has an invalid CRC... Reading ROM profiles.\n"); + + read_userdata = false; + } + + for (i = 0; i < profiles->num_profiles; i++) { + if (read_userdata) { +- hidpp_log_debug(device, "Parsing profile %u\n", i); ++ hidpp_log_debug(&device->base, "Parsing profile %u\n", i); + rc = hidpp20_onboard_profiles_parse_profile(device, + profiles, + i, +@@ -2462,7 +2462,7 @@ hidpp20_onboard_profiles_initialize(struct hidpp20_device *device, + + /* on fail to read the user profile fallback to the default profile */ + if (rc) +- hidpp_log_debug("Profile %u is bad. Falling back to the ROM settings.\n", i); ++ hidpp_log_debug(&device->base, "Profile %u is bad. Falling back to the ROM settings.\n", i); + else + continue; + } +-- +2.21.0 + diff --git a/libratbag.spec b/libratbag.spec index d16ec6c..96e7433 100644 --- a/libratbag.spec +++ b/libratbag.spec @@ -1,14 +1,14 @@ %global udevdir %(pkg-config --variable=udevdir udev) Name: libratbag -Version: 0.9.905 -Release: 4%{?gitdate:.%{gitdate}git%{gitversion}}%{?dist} +Version: 0.9.906 +Release: 1%{?gitdate:.%{gitdate}git%{gitversion}}%{?dist} Summary: Programmable input device library License: MIT URL: https://github.com/libratbag/libratbag Source0: https://github.com/libratbag/%{name}/archive/v%{version}/%{name}-%{version}.tar.gz -Patch01: 0001-Use-python3-embed-as-dependency-on-Python-3.8.patch +Patch01: 0001-hidpp20-fix-warnings.patch BuildRequires: git gcc gcc-c++ BuildRequires: meson pkgconfig @@ -19,6 +19,7 @@ BuildRequires: check-devel valgrind BuildRequires: systemd BuildRequires: python3 python3-devel python3-gobject BuildRequires: python3-lxml python3-evdev swig +BuildRequires: libunistring-devel %description libratbag is a library that allows to configure programmable @@ -50,7 +51,7 @@ The liblur-devel package contains libraries and header files for developing applications that use liblur. %prep -%autosetup +%autosetup -S git # hack until rhbz#1409661 gets fixed %{!?__global_cxxflags: %define __global_cxxflags %{optflags}} @@ -79,7 +80,7 @@ developing applications that use liblur. %{_bindir}/ratbagd %dir %{_datadir}/libratbag %dir %{_datadir}/libratbag -%{_datadir}/libratbag/devices/*.device +%{_datadir}/libratbag/*.device %{_mandir}/man1/ratbagctl.1* %{_mandir}/man8/ratbagd.8* %{_datadir}/dbus-1/system.d/org.freedesktop.ratbag1.conf @@ -98,6 +99,9 @@ developing applications that use liblur. %{_libdir}/pkgconfig/liblur.pc %changelog +* Fri Jul 26 2019 Peter Hutterer 0.9.906-1 +- libratbag 0.9.906 + * Thu Jul 25 2019 Fedora Release Engineering - 0.9.905-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild diff --git a/sources b/sources index defc798..f8e9b99 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (libratbag-0.9.905.tar.gz) = 7b1486846ecfc1fc5988c5c99cbe8c79cd9c6d01714e63c896b97caa1d323bc9538ebe10c73a9d0d46df497d408ce5302d673f59814de2a744bfeee6fc72d4ac +SHA512 (libratbag-0.9.906.tar.gz) = f241c931a566b1b008c5cffee59f782ef448425e28c47186067e681e6af6ba0bd2f53d3cedac038628464fa72c6dade4d940750d903b69c081911d9d9ed5ee18