From 86e6915d49202ca544b75f9872e9d289a55bf95c Mon Sep 17 00:00:00 2001 From: Jan Beich Date: Mon, 12 Aug 2019 17:09:29 +0000 Subject: [PATCH] Unbreak on FreeBSD ../clients/window.c:42:10: fatal error: 'sys/epoll.h' file not found #include ^~~~~~~~~~~~~ ../shared/xalloc.c:39:28: error: use of undeclared identifier 'program_invocation_short_name' fprintf(stderr, "[%s] ", program_invocation_short_name); ^ --- meson.build | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build index 92e98377..376f6abb 100644 --- a/meson.build +++ b/meson.build @@ -62,6 +62,7 @@ pixman = dependency('pixman-1') png = dependency('libpng') gio = dependency('gio-2.0') gio_unix = dependency('gio-unix-2.0') +epoll = dependency('epoll-shim', required: ['freebsd'].contains(host_machine.system())) wl_protocol_dir = wayland_protos.get_pkgconfig_variable('pkgdatadir') @@ -134,9 +135,13 @@ sources += dbus_src add_global_arguments('-DLIBEXECDIR=""', language : 'c') add_global_arguments('-DDATADIR=""', language : 'c') +if cc.has_function('getprogname', prefix: '#include ') + add_global_arguments('-Dprogram_invocation_short_name=getprogname()', language: 'c') +endif + executable( 'virtboard', sources, - dependencies: [png, math, pixman, wayland_cursor, wayland_client, wayland_protos, xkbcommon, cairo, gio, gio_unix], + dependencies: [png, math, pixman, wayland_cursor, wayland_client, wayland_protos, xkbcommon, cairo, gio, gio_unix, epoll], install: true, ) -- GitLab