summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--configure.ac1
-rw-r--r--include/c.h4
2 files changed, 5 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 8922d1f68..5b491f8ef 100644
--- a/configure.ac
+++ b/configure.ac
@@ -566,6 +566,7 @@ printf(__progname);
AC_CHECK_TYPES([union semun], [], [], [[
#include <sys/sem.h>
]])
+AC_CHECK_TYPES(loff_t)
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
diff --git a/include/c.h b/include/c.h
index cfee616fb..83be3565c 100644
--- a/include/c.h
+++ b/include/c.h
@@ -69,5 +69,9 @@ static inline __attribute__((const)) int is_power_of_2(unsigned long num)
return (num != 0 && ((num & (num - 1)) == 0));
}
+#ifndef HAVE_LOFF_T
+typedef int64_t loff_t;
+#endif
+
#endif /* UTIL_LINUX_C_H */