[Python-checkins] r60277 - in python/trunk: Modules/mathmodule.c Objects/floatobject.c
neal.norwitz
python-checkins at python.org
Fri Jan 25 09:04:16 CET 2008
Author: neal.norwitz
Date: Fri Jan 25 09:04:16 2008
New Revision: 60277
Modified:
python/trunk/Modules/mathmodule.c
python/trunk/Objects/floatobject.c
Log:
Add prototypes to get the mathmodule.c to compile on OSF1 5.1 (Tru64)
and eliminate a compiler warning in floatobject.c. There might be
a better way to go about this, but it should be good enough for now.
Modified: python/trunk/Modules/mathmodule.c
==============================================================================
--- python/trunk/Modules/mathmodule.c (original)
+++ python/trunk/Modules/mathmodule.c Fri Jan 25 09:04:16 2008
@@ -12,6 +12,11 @@
#endif /* __STDC__ */
#endif /* _MSC_VER */
+#ifdef _OSF_SOURCE
+/* OSF1 5.1 doesn't make this available with XOPEN_SOURCE_EXTENDED defined */
+extern double copysign(double, double);
+#endif
+
/* Call is_error when errno != 0, and where x is the result libm
* returned. is_error will usually set up an exception and return
* true (1), but may return false (0) without setting up an exception.
Modified: python/trunk/Objects/floatobject.c
==============================================================================
--- python/trunk/Objects/floatobject.c (original)
+++ python/trunk/Objects/floatobject.c Fri Jan 25 09:04:16 2008
@@ -16,6 +16,11 @@
extern double pow(double, double);
#endif
+#ifdef _OSF_SOURCE
+/* OSF1 5.1 doesn't make this available with XOPEN_SOURCE_EXTENDED defined */
+extern int finite(double);
+#endif
+
/* Special free list -- see comments for same code in intobject.c. */
#define BLOCK_SIZE 1000 /* 1K less typical malloc overhead */
#define BHEAD_SIZE 8 /* Enough for a 64-bit pointer */
More information about the Python-checkins
mailing list