]> git.ipfire.org Git - thirdparty/zlib-ng.git/commitdiff
Fix building under MinGW64.
authorMika Lindqvist <postmaster@raasu.org>
Wed, 13 May 2015 17:36:09 +0000 (20:36 +0300)
committerMika Lindqvist <postmaster@raasu.org>
Wed, 13 May 2015 18:42:50 +0000 (21:42 +0300)
arch/x86/crc_folding.c
arch/x86/deflate_quick.c
configure

index f16cb82eaa6e7a17a46a696b2077365a1c82e42a..7b04890d0ee984dbd49e5ee2be5083a7850b6424 100644 (file)
@@ -285,7 +285,7 @@ ZLIB_INTERNAL void crc_fold_copy(deflate_state *const s,
         goto partial;
     }
 
-    algn_diff = (0 - (unsigned long)src) & 0xF;
+    algn_diff = (0 - (uintptr_t)src) & 0xF;
     if (algn_diff) {
         xmm_crc_part = _mm_loadu_si128((__m128i *)src);
         _mm_storeu_si128((__m128i *)dst, xmm_crc_part);
index 2f5d63ba30ec6add1174c3bacbe734d2a1f2317c..cf6da76dc634783fc2267651f1a17b80074a9286 100644 (file)
@@ -22,7 +22,7 @@ extern void flush_pending  (z_stream *strm);
 local inline long compare258(const unsigned char *const src0,
         const unsigned char *const src1)
 {
-    long ax, dx, cx;
+    uintptr_t ax, dx, cx;
     __m128i xmm_src0;
 
     ax = 16;
@@ -152,7 +152,7 @@ local inline Pos quick_insert_string(deflate_state *const s, const Pos str)
         "crc32l (%[window], %[str], 1), %0\n\t"
     : "+r" (h)
     : [window] "r" (s->window),
-      [str] "r" ((long)str)
+      [str] "r" ((uintptr_t)str)
     );
 
     ret = s->head[h & s->hash_mask];
index e641745383670df616ec58fcf46ce3b644128851..336f630b1d6e2f6e9f991adb742ecf34ff397707 100755 (executable)
--- a/configure
+++ b/configure
@@ -266,7 +266,7 @@ if test "$gcc" -eq 1 && ($cc -c $test.c) >> configure.log 2>&1; then
         SHAREDLIBV=''
         SHAREDTARGET=$SHAREDLIB
         IMPORTLIB='libz.dll.a'
-        LDSHARED=${LDSHARED-"$cc -shared -Wl,--out-implib,${IMPORTLIB},--version-script,${SRCDIR}/zlib.map"}
+        LDSHARED=${LDSHARED-"$cc -shared -Wl,--out-implib=${IMPORTLIB} -Wl,--version-script=${SRCDIR}/zlib.map"}
         LDSHAREDLIBC=""
         DEFFILE='win32/zlib.def'
         RC='windres'