[PATCH xserver] xwayland: Silence a build warning if we can
Emil Velikov
emil.l.velikov at gmail.com
Fri Apr 6 09:39:53 UTC 2018
On 6 April 2018 at 08:07, Pekka Paalanen <ppaalanen at gmail.com> wrote:
> On Thu, 5 Apr 2018 13:35:11 -0400
> Adam Jackson <ajax at redhat.com> wrote:
>
>> [735/786] Generating 'hw/xwayland/Xwayland at exe/relative-pointer-unstable-v1-protocol.c'.
>> Using "code" is deprecated - use private-code or public-code.
>> See the help page for details.
>>
>> Use private-code if wayland-scanner is new enough.
>>
>> Signed-off-by: Adam Jackson <ajax at redhat.com>
>> ---
>> configure.ac | 4 ++++
>> hw/xwayland/Makefile.am | 14 +++++++-------
>> hw/xwayland/meson.build | 9 ++++++++-
>> 3 files changed, 19 insertions(+), 8 deletions(-)
>>
>
> Hi,
>
> I only read through the patch, and it looks quite ok to me, so:
> Reviewed-by: Pekka Paalanen <pekka.paalanen at collabora.co.uk>
>
And another one from me
Reviewed-by: Emil Velikov <emil.velikov at collabora.com>
> But I still have a couple of questions below.
>
>> diff --git a/configure.ac b/configure.ac
>> index 290721891d..d8d88e2b15 100644
>> --- a/configure.ac
>> +++ b/configure.ac
>> @@ -2391,6 +2391,10 @@ if test "x$XWAYLAND" = xyes; then
>> AC_PATH_PROG([WAYLAND_SCANNER], [wayland-scanner],,
>> [${WAYLAND_PREFIX}/bin$PATH_SEPARATOR$PATH])
>>
>> + PKG_CHECK_MODULES(WAYLAND_SCANNER, [wayland-scanner >= 1.14.91],
>> + AC_SUBST(SCANNER_ARG, 'private-code'),
>> + AC_SUBST(SCANNER_ARG, 'code'))
>
> Are you happy with the whitespace (tabs vs. spaces) here?
>
IIRC there's no hard rule.
> Thinking of cross-compiling, is this ok or should it be more paranoid
> about mismatching 'wayland-scanner' and 'wayland-scanner.pc'?
>
> Personally I would claim that version mismatch there would be user
> error, so this should be fine.
>
Since the Xserver detection does something very unusual* to begin
with, I wouldn't worry about it.
-Emil
The unusual bit:
- fetches the wayland-client prefix
- uses ^^ to search for wayland-scanner (via AC_PATH_PROG)
Instead one should really:
- do plain wayland-scanner + AC_PATH_PROG
- (as a fallback?) wayland-scanner + PKG_CHECK_MODULES +
--variable=wayland_scanner
More information about the xorg-devel
mailing list