diff options
-rwxr-xr-x | CMakeLists.txt | 8 | ||||
-rw-r--r-- | meson.build | 1 | ||||
-rw-r--r-- | nix/patches/meson-build.patch | 3 | ||||
-rw-r--r-- | src/meson.build | 1 |
4 files changed, 11 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 1190876d..ef0ce88e 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -164,6 +164,12 @@ if(HAVE_LIBEXECINFO) target_link_libraries(Hyprland execinfo) endif() +check_include_file("sys/timerfd.h" HAS_TIMERFD) +pkg_check_modules(epoll IMPORTED_TARGET epoll-shim) +if(NOT HAS_TIMERFD AND epoll_FOUND) + target_link_libraries(Hyprland PkgConfig::epoll) +endif() + if(LEGACY_RENDERER) message(STATUS "Using the legacy GLES2 renderer!") add_compile_definitions(LEGACY_RENDERER) @@ -174,7 +180,7 @@ if(NO_XWAYLAND) add_compile_definitions(NO_XWAYLAND) else() message(STATUS "XWAYLAND Enabled (NO_XWAYLAND not defined) checking deps...") - pkg_check_modules(xdeps REQUIRED IMPORTED_TARGET xcb xwayland xcb-util xcb-render xcb-image xcb-xfixes xcb-icccm xcb-composite xcb-res xcb-ewmh) + pkg_check_modules(xdeps REQUIRED IMPORTED_TARGET xcb xwayland xcb-util xcb-render xcb-xfixes xcb-icccm xcb-composite xcb-res xcb-ewmh) pkg_check_modules(xcb_errors IMPORTED_TARGET xcb-errors) target_link_libraries(Hyprland PkgConfig::xdeps) if(xcb_errors_FOUND) diff --git a/meson.build b/meson.build index 28e652d7..dd73cb92 100644 --- a/meson.build +++ b/meson.build @@ -51,6 +51,7 @@ if not have_xwayland endif backtrace_dep = cpp_compiler.find_library('execinfo', required: false) +epoll_dep = dependency('epoll-shim', required: false) # timerfd on BSDs systemd_dep = dependency('libsystemd', required: get_option('systemd')) if get_option('systemd').enabled() diff --git a/nix/patches/meson-build.patch b/nix/patches/meson-build.patch index 21cec8ee..5827e5c3 100644 --- a/nix/patches/meson-build.patch +++ b/nix/patches/meson-build.patch @@ -46,13 +46,14 @@ index 45701f5f..3505cefe 100644 dependency('cairo'), dependency('hyprcursor'), dependency('hyprlang', version: '>= 0.3.2'), -@@ -16,12 +16,12 @@ executable('Hyprland', src, +@@ -17,11 +17,11 @@ executable('Hyprland', src, dependency('egl'), dependency('xkbcommon'), dependency('libinput'), - xcb_dep, + dependency('xcb', required: get_option('xwayland')), backtrace_dep, + epoll_dep, systemd_dep, - udis86, + dependency('udis86'), diff --git a/src/meson.build b/src/meson.build index 59771fcf..d490cddb 100644 --- a/src/meson.build +++ b/src/meson.build @@ -19,6 +19,7 @@ executable('Hyprland', src, dependency('libinput'), xcb_dep, backtrace_dep, + epoll_dep, systemd_dep, udis86, |