aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/dba.c
diff options
context:
space:
mode:
Diffstat (limited to 'dba.c')
-rw-r--r--dba.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/dba.c b/dba.c
index 426d40b3..0a1b656d 100644
--- a/dba.c
+++ b/dba.c
@@ -1,4 +1,4 @@
-/* $Id: dba.c,v 1.4 2016/08/05 21:38:11 schwarze Exp $ */
+/* $Id: dba.c,v 1.5 2016/08/05 23:15:08 schwarze Exp $ */
/*
* Copyright (c) 2016 Ingo Schwarze <schwarze@openbsd.org>
*
@@ -17,8 +17,16 @@
* Allocation-based version of the mandoc database, for read-write access.
* The interface is defined in "dba.h".
*/
+#include "config.h"
+
#include <sys/types.h>
+#if HAVE_ENDIAN
#include <endian.h>
+#elif HAVE_SYS_ENDIAN
+#include <sys/endian.h>
+#elif HAVE_NTOHL
+#include <arpa/inet.h>
+#endif
#include <errno.h>
#include <stdint.h>
#include <stdlib.h>