file_watch: only use inotify on linux
Fixes build on *BSD platforms. Fixes #262, Closes #261 Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
@@ -78,6 +78,14 @@ if get_option('unittest')
|
||||
cflags += ['-DUNIT_TEST']
|
||||
endif
|
||||
|
||||
host_system = host_machine.system()
|
||||
if host_system == 'linux'
|
||||
cflags += ['-DHAS_INOTIFY']
|
||||
elif host_system == 'freebsd' or host_system == 'netbsd' or
|
||||
host_system == 'dragonfly' or host_system == 'openbsd'
|
||||
cflags += ['-DHAS_KQUEUE']
|
||||
endif
|
||||
|
||||
subdir('backend')
|
||||
|
||||
picom = executable('picom', srcs, c_args: cflags,
|
||||
|
||||
Reference in New Issue
Block a user