fenv-exceptions-state: Fix test failure on Haiku/i386 and Haiku/x86_64.
authorBruno Haible <bruno@clisp.org>
Sun, 5 Nov 2023 21:16:38 +0000 (22:16 +0100)
committerBruno Haible <bruno@clisp.org>
Sun, 5 Nov 2023 21:16:38 +0000 (22:16 +0100)
* m4/fenv-exceptions-state.m4 (gl_FENV_EXCEPTIONS_STATE): Arrange to
override fesetexceptflag() on Haiku.
* doc/posix-functions/fesetexceptflag.texi: Mention the Haiku bug.

ChangeLog
doc/posix-functions/fesetexceptflag.texi
m4/fenv-exceptions-state.m4

index dd3661fffd9031adc67a8b6cbd0f1d125ce9528f..0f5821ac4d1bb5847364efccf0c92f4f07ee26ef 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2023-11-05  Bruno Haible  <bruno@clisp.org>
+
+       fenv-exceptions-state: Fix test failure on Haiku/i386 and Haiku/x86_64.
+       * m4/fenv-exceptions-state.m4 (gl_FENV_EXCEPTIONS_STATE): Arrange to
+       override fesetexceptflag() on Haiku.
+       * doc/posix-functions/fesetexceptflag.texi: Mention the Haiku bug.
+
 2023-11-05  Bruno Haible  <bruno@clisp.org>
 
        fenv: Add C++ tests.
index 66075be67538d4cbb4bafcfa6eac0acdfa66dcf2..3523dbb8f8874df0ea4791e2d6a2b75483646eca 100644 (file)
@@ -17,7 +17,7 @@ This function triggers floating-point exception traps although it shouldn't, on
 glibc 2.37/i386, glibc 2.37/x86_64,
 @c https://sourceware.org/bugzilla/show_bug.cgi?id=30988
 glibc 2.37/powerpc,
-musl libc, Mac OS X 10.5, mingw.
+musl libc, Mac OS X 10.5, mingw, Haiku.
 @item
 This function clears too many floating-point exception flags on
 @c https://sourceware.org/bugzilla/show_bug.cgi?id=30998
index bd443be721d5d242aa2a758aa5709e96ff16a691..3cd09edd11bf8482bc156cc8d51916677bcaa5e5 100644 (file)
@@ -58,7 +58,8 @@ AC_DEFUN([gl_FENV_EXCEPTIONS_STATE],
       AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
       gl_MATHFUNC([feenableexcept], [int], [(int)], [#include <fenv.h>])
       dnl On glibc 2.37 for PowerPC, i386, x86_64, fesetexceptflag may raise
-      dnl traps. Likewise on Mac OS X 10.5.8 on i386, x86_64 and on mingw.
+      dnl traps. Likewise on Mac OS X 10.5.8 on i386, x86_64, on mingw, and
+      dnl on Haiku on i386, x86_64.
       AC_CACHE_CHECK([whether fesetexceptflag is guaranteed non-trapping],
         [gl_cv_func_fesetexceptflag_works1],
         [if test $gl_cv_func_feenableexcept_no_libm = yes \
@@ -129,6 +130,10 @@ changequote([,])dnl
                  [gl_cv_func_fesetexceptflag_works1="guessing no"],
                  [gl_cv_func_fesetexceptflag_works1="guessing yes"])
                ;;
+             # Guess no on Haiku.
+             haiku*)
+               gl_cv_func_fesetexceptflag_works1="guessing no"
+               ;;
              *) gl_cv_func_fesetexceptflag_works1="guessing yes" ;;
            esac
          fi