diff options
| author | 2011-09-14 02:26:51 +0200 | |
|---|---|---|
| committer | 2012-03-19 01:43:21 +0100 | |
| commit | 294cf69b256419e407b1eac04634752412ee7756 (patch) | |
| tree | aad873d07fca6e69547aa2609a645531fab44ddd /configure.ac | |
| parent | abf7eaa91e2ece0f461c71d3dcc0b2900c199209 (diff) | |
| download | libimobiledevice-294cf69b256419e407b1eac04634752412ee7756.tar.gz libimobiledevice-294cf69b256419e407b1eac04634752412ee7756.tar.bz2 | |
New file for be*/le* macros plus check for endian.h presence
Diffstat (limited to 'configure.ac')
| -rw-r--r-- | configure.ac | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/configure.ac b/configure.ac index 1bb33fa..feb5d11 100644 --- a/configure.ac +++ b/configure.ac | |||
| @@ -63,17 +63,19 @@ if test "x$have_vasprintf" = "xyes"; then | |||
| 63 | AC_DEFINE(HAVE_VASPRINTF,1,[define if vasprintf is available]) | 63 | AC_DEFINE(HAVE_VASPRINTF,1,[define if vasprintf is available]) |
| 64 | fi | 64 | fi |
| 65 | 65 | ||
| 66 | AC_DEFINE(LITTLE_ENDIAN,0,[little endian]) | 66 | AC_CHECK_HEADER(endian.h, [ac_cv_have_endian_h="yes"], [ac_cv_have_endian_h="no"]) |
| 67 | AC_DEFINE(BIG_ENDIAN,1,[big endian]) | 67 | if test "x$ac_cv_have_endian" = "xno"; then |
| 68 | AC_C_BIGENDIAN([ac_cv_c_bigendian="yes"], [ac_cv_c_bigendian="no"], [], []) | 68 | AC_DEFINE(__LITTLE_ENDIAN,1234,[little endian]) |
| 69 | if test "x$ac_cv_c_bigendian" = "xyes"; then | 69 | AC_DEFINE(__BIG_ENDIAN,4321,[big endian]) |
| 70 | AC_DEFINE(BYTE_ORDER,1,[big endian byte order]) | 70 | AC_C_BIGENDIAN([ac_cv_c_bigendian="yes"], [ac_cv_c_bigendian="no"], [], []) |
| 71 | else | 71 | if test "x$ac_cv_c_bigendian" = "xyes"; then |
| 72 | AC_DEFINE(BYTE_ORDER,0,[little endian byte order]) | 72 | AC_DEFINE(__BYTE_ORDER,4321,[big endian byte order]) |
| 73 | else | ||
| 74 | AC_DEFINE(__BYTE_ORDER,1234,[little endian byte order]) | ||
| 75 | fi | ||
| 73 | fi | 76 | fi |
| 74 | 77 | ||
| 75 | 78 | ||
| 76 | |||
| 77 | AC_ARG_WITH([swig], | 79 | AC_ARG_WITH([swig], |
| 78 | [AS_HELP_STRING([--without-swig], | 80 | [AS_HELP_STRING([--without-swig], |
| 79 | [build Python bindings using swig (default is yes)])], | 81 | [build Python bindings using swig (default is yes)])], |
