diff options
author | peter <peter@FreeBSD.org> | 2013-06-18 16:05:33 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 2013-06-18 16:05:33 +0000 |
commit | 88439828ccdcbcde66625a1eabbcf885c48b71b5 (patch) | |
tree | 2fe6b7e734fd61fc6cc0cdfdf4a77f93674cda42 | |
parent | 9ac60dd2842975c1c8715febf9ab8bb217d1692f (diff) | |
download | FreeBSD-src-88439828ccdcbcde66625a1eabbcf885c48b71b5.zip FreeBSD-src-88439828ccdcbcde66625a1eabbcf885c48b71b5.tar.gz |
Tweak generated config to make it more likely to work on 32 bit systems.
Pointed out by: Trond.Endrestol@fagskolen.gjovik.no
-rw-r--r-- | usr.bin/svn/lib/libapr/apr.h | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/usr.bin/svn/lib/libapr/apr.h b/usr.bin/svn/lib/libapr/apr.h index 77ee40d..0ce5d85 100644 --- a/usr.bin/svn/lib/libapr/apr.h +++ b/usr.bin/svn/lib/libapr/apr.h @@ -316,7 +316,12 @@ typedef unsigned short apr_uint16_t; typedef int apr_int32_t; typedef unsigned int apr_uint32_t; +#include <sys/_types.h> +#ifdef __LP64__ #define APR_SIZEOF_VOIDP 8 +#else +#define APR_SIZEOF_VOIDP 4 +#endif /* * Darwin 10's default compiler (gcc42) builds for both 64 and @@ -351,8 +356,8 @@ typedef unsigned int apr_uint32_t; #define UINT64_C(v) (v ## ULL) #endif #else - typedef long apr_int64_t; - typedef unsigned long apr_uint64_t; + typedef __int64_t apr_int64_t; + typedef __uint64_t apr_uint64_t; #endif typedef size_t apr_size_t; @@ -516,6 +521,7 @@ typedef apr_uint32_t apr_uintptr_t; * configure.in. */ +#ifdef __LP64__ #define APR_SSIZE_T_FMT "ld" /* And APR_SIZE_T_FMT */ @@ -535,6 +541,15 @@ typedef apr_uint32_t apr_uintptr_t; /* And APR_UINT64_T_HEX_FMT */ #define APR_UINT64_T_HEX_FMT "lx" +#else +#define APR_SSIZE_T_FMT "d" +#define APR_SIZE_T_FMT "u" +#define APR_OFF_T_FMT APR_INT64_T_FMT +#define APR_PID_T_FMT "d" +#define APR_INT64_T_FMT "lld" +#define APR_UINT64_T_FMT "llu" +#define APR_UINT64_T_HEX_FMT "llx" +#endif /* * Ensure we work with universal binaries on Darwin |