Charles Davis : msvcrt: Support 64-bit platforms that don' t have finitef or isnanf.
Alexandre Julliard
julliard at wine.codeweavers.com
Fri Jan 23 10:52:56 CST 2015
Module: wine
Branch: master
Commit: 7ef720f1840ea817d8a9bcc8da2843ec66a510fc
URL: http://source.winehq.org/git/wine.git/?a=commit;h=7ef720f1840ea817d8a9bcc8da2843ec66a510fc
Author: Charles Davis <cdavis5x at gmail.com>
Date: Thu Jan 22 23:30:57 2015 -0700
msvcrt: Support 64-bit platforms that don't have finitef or isnanf.
---
configure | 2 ++
configure.ac | 2 ++
dlls/msvcrt/math.c | 12 ++++++++++++
include/config.h.in | 6 ++++++
4 files changed, 22 insertions(+)
diff --git a/configure b/configure
index c0aa93e..b6660bd 100755
--- a/configure
+++ b/configure
@@ -14671,6 +14671,7 @@ for ac_func in \
dlopen \
epoll_create \
ffs \
+ finitef \
fnmatch \
fork \
fpclass \
@@ -14687,6 +14688,7 @@ for ac_func in \
gettimeofday \
getuid \
if_nameindex \
+ isnanf \
kqueue \
lstat \
memmove \
diff --git a/configure.ac b/configure.ac
index ab8945a..b40fde4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2045,6 +2045,7 @@ AC_CHECK_FUNCS(\
dlopen \
epoll_create \
ffs \
+ finitef \
fnmatch \
fork \
fpclass \
@@ -2061,6 +2062,7 @@ AC_CHECK_FUNCS(\
gettimeofday \
getuid \
if_nameindex \
+ isnanf \
kqueue \
lstat \
memmove \
diff --git a/dlls/msvcrt/math.c b/dlls/msvcrt/math.c
index 284924a..acac35d 100644
--- a/dlls/msvcrt/math.c
+++ b/dlls/msvcrt/math.c
@@ -34,6 +34,18 @@
WINE_DEFAULT_DEBUG_CHANNEL(msvcrt);
+#ifndef HAVE_FINITEF
+#define finitef(x) isfinite(x)
+#endif
+
+#ifndef HAVE_ISNANF
+#ifdef HAVE_ISNAN
+#define isnanf(x) isnan(x)
+#else
+#define isnanf(x) 0
+#endif
+#endif
+
#ifndef signbit
#define signbit(x) 0
#endif
diff --git a/include/config.h.in b/include/config.h.in
index a8ae6c5..4d7c7ac 100644
--- a/include/config.h.in
+++ b/include/config.h.in
@@ -123,6 +123,9 @@
/* Define to 1 if you have the `ffs' function. */
#undef HAVE_FFS
+/* Define to 1 if you have the `finitef' function. */
+#undef HAVE_FINITEF
+
/* Define to 1 if you have the <float.h> header file. */
#undef HAVE_FLOAT_H
@@ -279,6 +282,9 @@
/* Define to 1 if you have the `isnan' function. */
#undef HAVE_ISNAN
+/* Define to 1 if you have the `isnanf' function. */
+#undef HAVE_ISNANF
+
/* Define to 1 if you have the <jpeglib.h> header file. */
#undef HAVE_JPEGLIB_H
More information about the wine-cvs
mailing list