diff --git a/configure b/configure index bb5b1b8a271ca465f0b242a794cf51afe4229807..b77a8a8cf95f75e9adc79b62a8b95d201dca21de 100755 --- a/configure +++ b/configure @@ -740,32 +740,6 @@ EOF fi fi -echo >> configure.log - -# find a four-byte unsiged integer type for crc calculations -cat > $test.c < -#define is32(n,t) for(n=1,k=0;n;n<<=1,k++);if(k==32){puts(t);return 0;} -int main() { - int k; - unsigned i; - unsigned long l; - unsigned short s; - is32(i, "unsigned") - is32(l, "unsigned long") - is32(s, "unsigned short") - return 1; -} -EOF -Z_U4="" -if try $CC $CFLAGS $test.c -o $test && Z_U4=`./$test` && test -n "$Z_U4"; then - sed < zconf.h "/#define Z_U4/s/\/\* \.\/configure may/#define Z_U4 $Z_U4 \/* .\/configure put the/" > zconf.temp.h - mv zconf.temp.h zconf.h - echo "Looking for a four-byte integer type... Found." | tee -a configure.log -else - echo "Looking for a four-byte integer type... Not found." | tee -a configure.log -fi - # show the results in the log echo >> configure.log echo ALL = $ALL >> configure.log diff --git a/zconf.h b/zconf.h index 95c9ef648bad76605759d39759978915f308b9af..c6ec884d10c226f923ab1830d5acd69bcf7d5997 100644 --- a/zconf.h +++ b/zconf.h @@ -390,20 +390,14 @@ typedef uLong FAR uLongf; typedef Byte *voidp; #endif -/* ./configure may #define Z_U4 here */ - #if !defined(Z_U4) && !defined(Z_SOLO) && defined(STDC) # include -# if (UINT_MAX == 0xffffffffUL) +# if (UINT_MAX == 4294967295) # define Z_U4 unsigned -# else -# if (ULONG_MAX == 0xffffffffUL) -# define Z_U4 unsigned long -# else -# if (USHRT_MAX == 0xffffffffUL) -# define Z_U4 unsigned short -# endif -# endif +# elif (ULONG_MAX == 4294967295) +# define Z_U4 unsigned long +# elif (USHRT_MAX == 4294967295) +# define Z_U4 unsigned short # endif #endif diff --git a/zconf.h.cmakein b/zconf.h.cmakein index 028be15f98fa11d05e0a47159aa928cefaea6728..9254e9a25351fcdff96a57d06887ee778e370c7f 100644 --- a/zconf.h.cmakein +++ b/zconf.h.cmakein @@ -392,20 +392,14 @@ typedef uLong FAR uLongf; typedef Byte *voidp; #endif -/* ./configure may #define Z_U4 here */ - #if !defined(Z_U4) && !defined(Z_SOLO) && defined(STDC) # include -# if (UINT_MAX == 0xffffffffUL) +# if (UINT_MAX == 4294967295) # define Z_U4 unsigned -# else -# if (ULONG_MAX == 0xffffffffUL) -# define Z_U4 unsigned long -# else -# if (USHRT_MAX == 0xffffffffUL) -# define Z_U4 unsigned short -# endif -# endif +# elif (ULONG_MAX == 4294967295) +# define Z_U4 unsigned long +# elif (USHRT_MAX == 4294967295) +# define Z_U4 unsigned short # endif #endif diff --git a/zconf.h.in b/zconf.h.in index 95c9ef648bad76605759d39759978915f308b9af..c6ec884d10c226f923ab1830d5acd69bcf7d5997 100644 --- a/zconf.h.in +++ b/zconf.h.in @@ -390,20 +390,14 @@ typedef uLong FAR uLongf; typedef Byte *voidp; #endif -/* ./configure may #define Z_U4 here */ - #if !defined(Z_U4) && !defined(Z_SOLO) && defined(STDC) # include -# if (UINT_MAX == 0xffffffffUL) +# if (UINT_MAX == 4294967295) # define Z_U4 unsigned -# else -# if (ULONG_MAX == 0xffffffffUL) -# define Z_U4 unsigned long -# else -# if (USHRT_MAX == 0xffffffffUL) -# define Z_U4 unsigned short -# endif -# endif +# elif (ULONG_MAX == 4294967295) +# define Z_U4 unsigned long +# elif (USHRT_MAX == 4294967295) +# define Z_U4 unsigned short # endif #endif