Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build fail #5

Open
IOU4 opened this issue Feb 11, 2022 · 1 comment
Open

build fail #5

IOU4 opened this issue Feb 11, 2022 · 1 comment

Comments

@IOU4
Copy link

IOU4 commented Feb 11, 2022

here is the output of ninja -C build :

FAILED: wdomirror.p/main.c.o
cc -Iwdomirror.p -I. -I.. -Iprotocol -I../protocol -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Werror -std=c11 -g -Wno-missing-braces -Wno-unused-parameter -MD -MQ wdomirror.p/main.c.o -MF wdomirror.p/main.c.o.d -o wdomirror.p/main.c.o -c ../main.c
../main.c:415:1: error: missing initializer for field ‘configure_bounds’ of ‘const struct xdg_toplevel_listener’ [-Werror=missing-field-initializers]
  415 | };
      | ^
In file included from ../main.c:16:
wdomirror.p/xdg-shell-client-protocol.h:1388:16: note: ‘configure_bounds’ declared here
 1388 |         void (*configure_bounds)(void *data,
      |                ^~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
ninja: build stopped: subcommand failed.

meson : 0.61.1
ninja : 1.10.2
sway: 1.7
5.16.8-arch1-1

@AlexBMJ
Copy link

AlexBMJ commented Apr 19, 2022

It looks like configure_bounds has been added to xdg-shell-client-protocol.h, so it needs to be implemented in main.c as well. Here is a quick patch to fix the build error.

echo "
--- a/main.c
+++ b/main.c
@@ -409,9 +409,12 @@ xdg_toplevel_handle_close(void *data, struct xdg_toplevel *xdg_toplevel)
   ctx->quit = true;
 }

+static void xdg_toplevel_handle_configure_bounds(void *data, struct xdg_toplevel *toplevel, int32_t width, int32_t height) {}
+
 static const struct xdg_toplevel_listener xdg_toplevel_listener = {
   xdg_toplevel_handle_configure,
   xdg_toplevel_handle_close,
+  xdg_toplevel_handle_configure_bounds,
 };


" | git apply

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants