From 25eb324719f5927dda1c6aa9644ed362f1cc4c3f Mon Sep 17 00:00:00 2001 From: Carter Li Date: Sun, 12 Jan 2025 11:53:35 +0800 Subject: [PATCH] CI: fix build --- CMakeLists.txt | 1 - src/detection/cpu/cpu_bsd.c | 7 +++++-- .../wayland/kde-output-device-v2-client-protocol.h | 14 +++++++------- 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 3159adc66..52bc16e80 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -496,7 +496,6 @@ if(LINUX) src/detection/displayserver/linux/wayland/kde-output-device-v2-protocol.c src/detection/displayserver/linux/wayland/kde-output-order-v1-protocol.c src/detection/displayserver/linux/wayland/xdg-output-unstable-v1-protocol.c - src/detection/displayserver/linux/wayland/xx-color-management-v4-protocol.c src/detection/displayserver/linux/wmde.c src/detection/displayserver/linux/xcb.c src/detection/displayserver/linux/xlib.c diff --git a/src/detection/cpu/cpu_bsd.c b/src/detection/cpu/cpu_bsd.c index 0ba110d0d..a2ce3e5a8 100644 --- a/src/detection/cpu/cpu_bsd.c +++ b/src/detection/cpu/cpu_bsd.c @@ -2,7 +2,10 @@ #include "common/sysctl.h" #include -#include +#if __has_include() + #include + #define FF_HAVE_CPUSET 1 +#endif static const char* detectCpuTemp(double* current) { @@ -63,7 +66,7 @@ const char* ffDetectCPUImpl(const FFCPUOptions* options, FFCPUResult* cpu) } } -#if __x86_64__ || __i386__ +#if FF_HAVE_CPUSET && (__x86_64__ || __i386__) // Bind current process to the first two cores, which is *usually* a performance core cpuset_t currentCPU; CPU_ZERO(¤tCPU); diff --git a/src/detection/displayserver/linux/wayland/kde-output-device-v2-client-protocol.h b/src/detection/displayserver/linux/wayland/kde-output-device-v2-client-protocol.h index 34f5c66ac..b220a2e98 100644 --- a/src/detection/displayserver/linux/wayland/kde-output-device-v2-client-protocol.h +++ b/src/detection/displayserver/linux/wayland/kde-output-device-v2-client-protocol.h @@ -5,7 +5,7 @@ #include #include -#include "wayland-client.h" +#include #ifdef __cplusplus extern "C" { @@ -556,7 +556,7 @@ struct kde_output_device_v2_listener { /** * describes when auto rotate is used * - * + * * @since 4 */ void (*auto_rotate_policy)(void *data, @@ -565,7 +565,7 @@ struct kde_output_device_v2_listener { /** * describes when auto rotate is used * - * + * * @since 5 */ void (*icc_profile_path)(void *data, @@ -574,7 +574,7 @@ struct kde_output_device_v2_listener { /** * metadata about the screen's brightness limits * - * + * * @param max_peak_brightness in nits * @param max_frame_average_brightness in nits * @param min_brightness in 0.0001 nits @@ -588,7 +588,7 @@ struct kde_output_device_v2_listener { /** * overrides for the screen's brightness limits * - * + * * @param max_peak_brightness -1 for no override, positive values are the brightness in nits * @param max_average_brightness -1 for no override, positive values are the brightness in nits * @param min_brightness -1 for no override, positive values are the brightness in 0.0001 nits @@ -614,7 +614,7 @@ struct kde_output_device_v2_listener { /** * describes which source the compositor uses for the color profile on an output * - * + * * @since 7 */ void (*color_profile_source)(void *data, @@ -638,7 +638,7 @@ struct kde_output_device_v2_listener { /** * the preferred color/power tradeoff * - * + * * @since 10 */ void (*color_power_tradeoff)(void *data,