Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit7badb1e

Browse files
committed
Fix configure problem.
1 parentb721c9e commit7badb1e

File tree

3 files changed

+43
-9
lines changed

3 files changed

+43
-9
lines changed

‎src/backend/port/isinf.c

Lines changed: 24 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,12 @@
1-
/* $Id: isinf.c,v 1.10 1999/07/1817:38:23 momjian Exp $ */
1+
/* $Id: isinf.c,v 1.11 1999/07/1820:43:12 momjian Exp $ */
22

33
#include<math.h>
4-
54
#include"config.h"
65

7-
#ifdefNOT_USED
8-
6+
#ifHAVE_FPCLASS
97
#ifHAVE_IEEEFP_H
108
#include<ieeefp.h>
119
#endif
12-
#ifHAVE_FP_CLASS_H
13-
#include<fp_class.h>
14-
#endif
15-
1610
int
1711
isinf(doubled)
1812
{
@@ -29,6 +23,12 @@ isinf(double d)
2923
return0;
3024
}
3125

26+
#else
27+
28+
#if defined(HAVE_FP_CLASS)|| defined(HAVE_FP_CLASS_D)
29+
#ifHAVE_FP_CLASS_H
30+
#include<fp_class.h>
31+
#endif
3232
int
3333
isinf(x)
3434
doublex;
@@ -49,3 +49,19 @@ doublex;
4949
}
5050

5151
#endif
52+
#endif
53+
54+
#if defined(HAVE_CLASS)
55+
int
56+
isinf(doublex)
57+
{
58+
intfpclass=class(x);
59+
60+
if (fpclass==FP_PLUS_INF)
61+
return1;
62+
if (fpclass==FP_MINUS_INF)
63+
return-1;
64+
return0;
65+
}
66+
67+
#endif

‎src/configure.in

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -581,6 +581,7 @@ AC_CHECK_HEADERS(crypt.h)
581581
AC_CHECK_HEADERS(dld.h)
582582
AC_CHECK_HEADERS(endian.h)
583583
AC_CHECK_HEADERS(float.h)
584+
AC_CHECK_HEADERS(fp_class.h)
584585
AC_CHECK_HEADERS(history.h)
585586
AC_CHECK_HEADERS(ieeefp.h)
586587
AC_CHECK_HEADERS(limits.h)
@@ -665,6 +666,7 @@ AC_TYPE_SIGNAL
665666
AC_FUNC_VPRINTF
666667
AC_CHECK_FUNCS(memmove sigsetjmp sysconf)
667668
AC_CHECK_FUNCS(sigprocmask waitpid setsid fcvt)
669+
AC_CHECK_FUNCS(fpclass fp_class fp_class_d class)
668670
dnl We use our snprintf.c emulation if either snprintf() or vsnprintf()
669671
dnl is missing. Yes, there are machines that have only one.
670672
dnl We may also decide to use snprintf.c if snprintf() is present but does
@@ -714,6 +716,11 @@ AC_CHECK_FUNC(inet_aton,
714716
AC_DEFINE(HAVE_INET_ATON),
715717
INET_ATON='inet_aton.o')
716718
AC_SUBST(INET_ATON)
719+
AC_CHECK_FUNC(strerror,
720+
AC_DEFINE(HAVE_STRERROR),
721+
[STRERROR='strerror.o' STRERROR2='../../backend/port/strerror.o'])
722+
AC_SUBST(STRERROR)
723+
AC_SUBST(STRERROR2)
717724
AC_CHECK_FUNC(strdup,
718725
AC_DEFINE(HAVE_STRDUP),
719726
STRDUP='../../utils/strdup.o')

‎src/include/config.h.in

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -303,10 +303,21 @@
303303
/* Set to 1 if you have snprintf() */
304304
#undef HAVE_SNPRINTF
305305

306+
/* Set to 1 if you have strerror() */
307+
#undef HAVE_STRERROR
308+
306309
/* Set to 1 if you have vsnprintf() */
307310
#undef HAVE_VSNPRINTF
308311

309-
/* Set to 1 if you have isinf() */
312+
/*
313+
*Set to 1 if you have isinf().
314+
*These are all realated to port/isinf.c
315+
*/
316+
#undef HAVE_FPCLASS
317+
#undef HAVE_FP_CLASS
318+
#undef HAVE_FP_CLASS_H
319+
#undef HAVE_FP_CLASS_D
320+
#undef HAVE_CLASS
310321
#undef HAVE_ISINF
311322
#ifndefHAVE_ISINF
312323
intisinf(doublex);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp