build: a more robust zlib test
authorAndrew Bartlett <abartlet@samba.org>
Fri, 9 Sep 2011 02:08:54 +0000 (12:08 +1000)
committerAndrew Bartlett <abartlet@samba.org>
Fri, 9 Sep 2011 05:24:05 +0000 (15:24 +1000)
Just in-case, and done this way due to the #define maze that applies
to this function.  No actual host has been found that needs this yet.

Andrew Bartlett

lib/zlib/wscript

index a091de6b5f10ce8c499ef265aa6d1171d6516822..42d6f76f149e52244ae8ef9c1213f4467cb14081 100644 (file)
@@ -9,10 +9,13 @@ def configure(conf):
                     #else
                     #error "ZLIB_VERNUM < 0x1230"
                     #endif
+                    z_stream *z;
+                    inflateInit2(z, -15);
                     ''',
                     headers='zlib.h',
+                    lib='z',
                     local_include=False,
-                    msg='Checking for ZLIB_VERNUM >= 0x1230',
+                    msg='Checking for ZLIB_VERNUM >= 0x1230 and working link to zlib',
                     define='HAVE_ZLIB')
 
     # If we don't do this then we will receive an error that lib 'z'