From 3834a79741178632f9b5f45256c300c3b0a4271a Mon Sep 17 00:00:00 2001 From: Luca Bacci Date: Mon, 30 Jun 2025 17:13:52 +0200 Subject: [PATCH] Do not check for feclearexcept Unlike feenableexcept and fedisableexcept, which are GNU extensions, feclearexcept is part of C99. https://en.cppreference.com/w/c/header/fenv.html --- meson.build | 2 +- test/invalid-matrix.c | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/meson.build b/meson.build index 6dafaad6e..0921c6480 100644 --- a/meson.build +++ b/meson.build @@ -137,7 +137,7 @@ check_headers = [ ['sys/wait.h'], ['sys/stat.h'], ['io.h'], - ['fenv.h', {'check-funcs': ['feenableexcept', 'fedisableexcept', 'feclearexcept']}], + ['fenv.h', {'check-funcs': ['feenableexcept', 'fedisableexcept']}], ['xlocale.h'], ['sys/ioctl.h'], ['intsafe.h'], diff --git a/test/invalid-matrix.c b/test/invalid-matrix.c index 81cce5edc..44dd6bfd6 100644 --- a/test/invalid-matrix.c +++ b/test/invalid-matrix.c @@ -29,6 +29,8 @@ #include "config.h" #include "cairo-test.h" +#include + #if !defined(INFINITY) #define INFINITY HUGE_VAL #endif @@ -361,7 +363,7 @@ if ((status) == CAIRO_STATUS_SUCCESS) { \ CHECK_STATUS (status, "cairo_rotate(∞)"); cairo_destroy (cr2); -#if HAVE_FECLEAREXCEPT +#if FE_ALL_EXCEPT feclearexcept (FE_INVALID); #endif