summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/zlib/extconf.rb12
1 files changed, 9 insertions, 3 deletions
diff --git a/ext/zlib/extconf.rb b/ext/zlib/extconf.rb
index c3035e37b5d..47a15b1b20a 100644
--- a/ext/zlib/extconf.rb
+++ b/ext/zlib/extconf.rb
@@ -70,9 +70,15 @@ if have_zlib
$defs.concat(defines.collect{|d|' -D'+d})
- have_func('crc32_combine', 'zlib.h')
- have_func('adler32_combine', 'zlib.h')
- have_type('z_crc_t', 'zlib.h')
+ if zsrc
+ $defs << "-DHAVE_CRC32_COMBINE"
+ $defs << "-DHAVE_ADLER32_COMBINE"
+ $defs << "-DHAVE_TYPE_Z_CRC_T"
+ else
+ have_func('crc32_combine', 'zlib.h')
+ have_func('adler32_combine', 'zlib.h')
+ have_type('z_crc_t', 'zlib.h')
+ end
create_makefile('zlib') {|conf|
if zsrc