Gentoo Archives: gentoo-commits

From: Sam James <sam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-auth/fprintd/files/, sys-auth/fprintd/
Date: Fri, 21 Jan 2022 17:11:56
Message-Id: 1642785095.a7920d91042220f86a5673fa5aab3028024d8f01.sam@gentoo
1 commit: a7920d91042220f86a5673fa5aab3028024d8f01
2 Author: Sam James <sam <AT> gentoo <DOT> org>
3 AuthorDate: Fri Jan 21 17:11:35 2022 +0000
4 Commit: Sam James <sam <AT> gentoo <DOT> org>
5 CommitDate: Fri Jan 21 17:11:35 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a7920d91
7
8 sys-auth/fprintd: fix build with meson 0.61
9
10 Closes: https://bugs.gentoo.org/831753
11 Signed-off-by: Sam James <sam <AT> gentoo.org>
12
13 .../fprintd-1.94.1-fix-meson-0.61-build.patch | 121 +++++++++++++++++++++
14 sys-auth/fprintd/fprintd-1.94.1.ebuild | 1 +
15 2 files changed, 122 insertions(+)
16
17 diff --git a/sys-auth/fprintd/files/fprintd-1.94.1-fix-meson-0.61-build.patch b/sys-auth/fprintd/files/fprintd-1.94.1-fix-meson-0.61-build.patch
18 new file mode 100644
19 index 000000000000..e7f78320d1b9
20 --- /dev/null
21 +++ b/sys-auth/fprintd/files/fprintd-1.94.1-fix-meson-0.61-build.patch
22 @@ -0,0 +1,121 @@
23 +https://gitlab.freedesktop.org/libfprint/fprintd/-/commit/f4256533d1ffdc203c3f8c6ee42e8dcde470a93f.patch
24 +https://gitlab.freedesktop.org/libfprint/fprintd/-/commit/2c34cef5ef2004d8479475db5523c572eb409a6b.patch
25 +https://bugs.gentoo.org/831753
26 +
27 +From f4256533d1ffdc203c3f8c6ee42e8dcde470a93f Mon Sep 17 00:00:00 2001
28 +From: Eli Schwartz <eschwartz@×××××××××.org>
29 +Date: Tue, 11 Jan 2022 21:06:35 -0500
30 +Subject: [PATCH] use more idiomatic/correct embedded shell scripting
31 +
32 +Formatting arguments into code is fragile, and meson natively knows how
33 +to pass files as arguments via argv. So pass them as arguments to the
34 +shell.
35 +---
36 + doc/dbus/meson.build | 9 ++++-----
37 + 1 file changed, 4 insertions(+), 5 deletions(-)
38 +
39 +diff --git a/doc/dbus/meson.build b/doc/dbus/meson.build
40 +index 802938e..861da64 100644
41 +--- a/doc/dbus/meson.build
42 ++++ b/doc/dbus/meson.build
43 +@@ -19,11 +19,10 @@ foreach interface_file: dbus_interfaces_files
44 + capture: true,
45 + command: [
46 + bash, '-c',
47 +- 'cat @INPUT@;' +
48 +- xsltproc.path() + ' @0@/@1@ '.format(
49 +- meson.source_root(),
50 +- files('spec-to-docbook.xsl')[0]) +
51 +- interface_file.full_path() + '| tail -n +2;',
52 ++ 'cat "$1"; "$2" "$3" "$4" | tail -n +2',
53 ++ '_', # argv0 ignored
54 ++ '@INPUT@',
55 ++ xsltproc, files('spec-to-docbook.xsl')[0], interface_file
56 + ],
57 + )
58 + endforeach
59 +--
60 +GitLab
61 +
62 +From 2c34cef5ef2004d8479475db5523c572eb409a6b Mon Sep 17 00:00:00 2001
63 +From: Eli Schwartz <eschwartz@×××××××××.org>
64 +Date: Tue, 11 Jan 2022 20:46:29 -0500
65 +Subject: [PATCH] remove pointless copying of files into build directory
66 +
67 +I'm not entirely sure what this did, but it seems to be obsoleted by
68 +commit 93bad825406d13ed5eb2cf27541dc58194bef8f3.
69 +---
70 + doc/dbus/meson.build | 6 +++---
71 + src/meson.build | 20 ++++++-------------
72 + ....xml => net.reactivated.Fprint.Device.xml} | 0
73 + ...xml => net.reactivated.Fprint.Manager.xml} | 0
74 + 4 files changed, 9 insertions(+), 17 deletions(-)
75 + rename src/{device.xml => net.reactivated.Fprint.Device.xml} (100%)
76 + rename src/{manager.xml => net.reactivated.Fprint.Manager.xml} (100%)
77 +
78 +diff --git a/doc/dbus/meson.build b/doc/dbus/meson.build
79 +index 861da64..431127d 100644
80 +--- a/doc/dbus/meson.build
81 ++++ b/doc/dbus/meson.build
82 +@@ -9,13 +9,13 @@ docbook_xml_header = custom_target('docbook_xml_header',
83 + )
84 +
85 + dbus_interfaces_refs = []
86 +-foreach interface_file: dbus_interfaces_files
87 +- basename = run_command('basename', interface_file.full_path(), '.xml').stdout().strip()
88 ++foreach interface_file: dbus_interfaces
89 ++ basename = run_command('basename', interface_file, '.xml').stdout().strip()
90 + dbus_interfaces_refs += custom_target(basename + '_ref',
91 + input: docbook_xml_header,
92 + output: basename + '.ref.xml',
93 + build_by_default: true,
94 +- depends: interface_file,
95 ++ depend_files: interface_file,
96 + capture: true,
97 + command: [
98 + bash, '-c',
99 +diff --git a/src/meson.build b/src/meson.build
100 +index 1df6216..a7ce3fe 100644
101 +--- a/src/meson.build
102 ++++ b/src/meson.build
103 +@@ -1,22 +1,14 @@
104 + bash = find_program('bash')
105 +-dbus_interfaces = ['Manager', 'Device']
106 +-dbus_interfaces_files = []
107 ++dbus_interfaces = files(
108 ++ 'net.reactivated.Fprint.Manager.xml',
109 ++ 'net.reactivated.Fprint.Device.xml',
110 ++)
111 +
112 +-foreach interface_name: dbus_interfaces
113 +- interface = interface_name.to_lower()
114 +- interface_file = interface + '.xml'
115 +- dbus_interfaces_files += custom_target('dbus_interface_' + interface,
116 +- input: interface_file,
117 +- output: 'net.reactivated.Fprint.@0@.xml'.format(interface_name),
118 +- command: ['cp', '@INPUT@', '@OUTPUT@'],
119 +- install: true,
120 +- install_dir: dbus_interfaces_dir,
121 +- )
122 +-endforeach
123 ++install_data(dbus_interfaces, install_dir: dbus_interfaces_dir)
124 +
125 + # NOTE: We should pass "--glib-min-required 2.64" but cannot
126 + fprintd_dbus_sources_base = gnome.gdbus_codegen('fprintd-dbus',
127 +- sources: dbus_interfaces_files,
128 ++ sources: dbus_interfaces,
129 + autocleanup: 'all',
130 + interface_prefix: 'net.reactivated.Fprint.',
131 + namespace: 'FprintDBus',
132 +diff --git a/src/device.xml b/src/net.reactivated.Fprint.Device.xml
133 +similarity index 100%
134 +rename from src/device.xml
135 +rename to src/net.reactivated.Fprint.Device.xml
136 +diff --git a/src/manager.xml b/src/net.reactivated.Fprint.Manager.xml
137 +similarity index 100%
138 +rename from src/manager.xml
139 +rename to src/net.reactivated.Fprint.Manager.xml
140 +--
141 +GitLab
142 +
143 +
144
145 diff --git a/sys-auth/fprintd/fprintd-1.94.1.ebuild b/sys-auth/fprintd/fprintd-1.94.1.ebuild
146 index 8a0c86a78391..1cf6326d13f2 100644
147 --- a/sys-auth/fprintd/fprintd-1.94.1.ebuild
148 +++ b/sys-auth/fprintd/fprintd-1.94.1.ebuild
149 @@ -53,6 +53,7 @@ BDEPEND="
150 PATCHES=(
151 "${FILESDIR}/${PN}-1.90.7_0001-add-test-feature-and-make-tests-optional.patch"
152 "${FILESDIR}/${PN}-1.90.8_0002-add-configure-option-for-libsystemd-provider.patch"
153 + "${FILESDIR}/${P}-fix-meson-0.61-build.patch"
154 )
155
156 S="${WORKDIR}/${MY_P}"