[librep] OpenBSD fixups
- From: Christopher Bratusek <chrisb src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [librep] OpenBSD fixups
- Date: Fri, 13 Nov 2009 05:51:24 +0000 (UTC)
commit c542e6028acd010b83e18e81b995146ae63965e2
Author: Christopher Roy Bratusek <chris nanolx org>
Date: Fri Nov 13 06:50:44 2009 +0100
OpenBSD fixups
ChangeLog | 6 ++++++
man/news.texi | 7 +++++++
src/numbers.c | 2 +-
src/repint.h | 12 ++++++++++--
4 files changed, 24 insertions(+), 3 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 17ac67c..3432852 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2009-11-13 Christopher Bratusek <zanghar freenet de>
+ * configure.in: post-release version-bump to 0.90.4
+
+ * src/numbers.c
+ * src/repint.h: fixups for OpenBSD [Jasper Lievisse Adriaanse]
+
2009-10-24 Christopher Bratusek <zanghar freenet de>
* librep.spec.in
* man/Makefile.in
diff --git a/man/news.texi b/man/news.texi
index 3681e3d..3b1af40 100644
--- a/man/news.texi
+++ b/man/news.texi
@@ -3,6 +3,13 @@
@appendix News
@cindex News
+ heading 0.90.4
+
+ itemize @bullet
+
+ item Fixups for OpenBSD [Jasper Lievisse Adriaanse]
+ end itemize
+
@heading 0.90.3
@itemize @bullet
diff --git a/src/numbers.c b/src/numbers.c
index 5826a02..29dd100 100644
--- a/src/numbers.c
+++ b/src/numbers.c
@@ -70,7 +70,7 @@ DEFSTRING(domain_error, "Domain error");
# define LONG_LONG_MIN LONGLONG_MIN
# define LONG_LONG_MAX LONGLONG_MAX
# elif defined (LLONG_MIN)
- /* Solaris uses LLONG_ */
+ /* Solaris and OpenBSD uses LLONG_ */
# define LONG_LONG_MIN LLONG_MIN
# define LONG_LONG_MAX LLONG_MAX
# endif
diff --git a/src/repint.h b/src/repint.h
index 59435af..b6f031b 100644
--- a/src/repint.h
+++ b/src/repint.h
@@ -26,8 +26,16 @@
#endif
/* Maximum/minimum macros. Don't use when X or Y have side-effects! */
-#define MAX(x,y) (((x) > (y)) ? (x) : (y))
-#define MIN(x,y) (((x) < (y)) ? (x) : (y))
+#ifdef __OpenBSD__
+ /* MAX and MIN these are defined in <sys/param.h> on OpenBSD
+ * We include that here as sometimes it's included in other
+ * places and sometimes not - this ensures we don't redefine
+ * these two macros */
+# include <sys/param.h>
+#else
+# define MAX(x,y) (((x) > (y)) ? (x) : (y))
+# define MIN(x,y) (((x) < (y)) ? (x) : (y))
+#endif
#define POS(x) MAX(x, 0)
#define ABS(x) MAX(x, -(x))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]