Browse Source

Use autoconf to check for endian.h.

master
Reece H. Dunn 8 years ago
parent
commit
58c655abae
2 changed files with 2 additions and 1 deletions
  1. 1
    0
      configure.ac
  2. 1
    1
      src/include/compat/endian.h

+ 1
- 0
configure.ac View File

@@ -85,6 +85,7 @@ dnl ================================================================
dnl library checks.
dnl ================================================================

AC_CHECK_HEADERS([endian.h]) dnl Linux
AC_CHECK_HEADERS([fcntl.h]) dnl POSIX
AC_CHECK_HEADERS([getopt.h]) dnl POSIX
AC_CHECK_HEADERS([locale.h]) dnl C89

+ 1
- 1
src/include/compat/endian.h View File

@@ -19,7 +19,7 @@
#ifndef ENDIAN_H_COMPAT_SHIM
#define ENDIAN_H_COMPAT_SHIM

#if defined(__linux__) || defined(__CYGWIN__) || defined(__EMSCRIPTEN__)
#if defined(HAVE_ENDIAN_H)
# pragma GCC system_header // Silence "warning: #include_next is a GCC extension"
# include_next <endian.h>
#elif defined(__APPLE__)

Loading…
Cancel
Save