diff options
| -rw-r--r-- | configure.in | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/configure.in b/configure.in index 71388a34d..c7c45fc2c 100644 --- a/configure.in +++ b/configure.in @@ -317,20 +317,20 @@ AC_C_BIGENDIAN AC_CHECK_SIZEOF(short, 2) AC_CHECK_SIZEOF(int, 4) AC_CHECK_SIZEOF(long, 4) -if test ${ac_cv_sizeof_short:0:1} -eq 2; then +if test $ac_cv_sizeof_short -eq 2; then AC_DEFINE(U16,unsigned short) fi -if test ${ac_cv_sizeof_int:0:1} -eq 4; then +if test $ac_cv_sizeof_int -eq 4; then AC_DEFINE(U32,unsigned) else - if test ${ac_cv_sizeof_long:0:1} -eq 4; then + if test $ac_cv_sizeof_long -eq 4; then AC_DEFINE(U32,unsigned long) fi fi -if test ${ac_cv_sizeof_int:0:1} -eq 8; then +if test $ac_cv_sizeof_int -eq 8; then AC_DEFINE(U64,unsigned) else - if test ${ac_cv_sizeof_long:0:1} -eq 8; then + if test $ac_cv_sizeof_long -eq 8; then AC_DEFINE(U64,unsigned long) fi fi @@ -610,6 +610,10 @@ UNINSTALL_DESKTOP="" case $uname in CYGWIN* | MINGW*) dnl Cygwin environment... + # Recent versions of Cygwin are seriously broken and the size + # checks don't work because the shell puts out \r\n instead of + # \n. Here we just force U32 to be defined to "unsigned"... + AC_DEFINE(U32,unsigned) CFLAGS="-mwindows -DWIN32 $CFLAGS" CXXFLAGS="-mwindows -DWIN32 $CXXFLAGS" LDFLAGS="-mwindows $LDFLAGS" |
