67e138c0ba
if the system lacks one (trick borrowed from multimedia/smpeg). Fixes build on Darwin.
34 lines
952 B
Text
34 lines
952 B
Text
$NetBSD: patch-ao,v 1.3 2007/06/30 14:19:52 schmonz Exp $
|
|
|
|
--- port.h.orig 1999-09-06 11:38:10.000000000 -0400
|
|
+++ port.h
|
|
@@ -42,8 +42,10 @@
|
|
/* If endian.h is not present, it can be handled in the code below, */
|
|
/* but if you have this file, it can make it more fool proof. */
|
|
#if (defined(XFRACT) && !defined(__sun))
|
|
-#if defined(sgi)
|
|
+#if defined(sgi) || defined(__NetBSD__) || defined(__DragonFly__)
|
|
#include <sys/endian.h>
|
|
+#elif defined (__APPLE__)
|
|
+#include <machine/endian.h>
|
|
#else
|
|
#include <endian.h>
|
|
#endif
|
|
@@ -290,6 +292,9 @@ typedef int sigfunc(int);
|
|
#ifdef sun
|
|
#define DO_NOT_USE_LONG_DOUBLE
|
|
#endif
|
|
+#if defined(__NetBSD__) || defined(__DragonFly__)
|
|
+#define DO_NOT_USE_LONG_DOUBLE
|
|
+#endif
|
|
|
|
#ifndef DO_NOT_USE_LONG_DOUBLE
|
|
#ifdef LDBL_DIG
|
|
@@ -353,6 +358,7 @@ typedef int sigfunc(int);
|
|
#define fabsl fabs
|
|
#define sinl sin
|
|
#define cosl cos
|
|
+#define frexpl frexp
|
|
#endif
|
|
|
|
#endif /* PORT_H */
|