libarchive-static 1.0.5 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (296) hide show
  1. checksums.yaml +5 -5
  2. data/ext/extconf.rb +2 -9
  3. data/ext/libarchive-0.1.1/ext/archive_read_support_compression.c +6 -6
  4. data/ext/libarchive-0.1.1/ext/archive_read_support_compression.o +0 -0
  5. data/ext/libarchive-0.1.1/ext/archive_read_support_format.o +0 -0
  6. data/ext/libarchive-0.1.1/ext/archive_write_open_rb_str.c +1 -1
  7. data/ext/libarchive-0.1.1/ext/archive_write_open_rb_str.o +0 -0
  8. data/ext/libarchive-0.1.1/ext/archive_write_set_compression.c +5 -5
  9. data/ext/libarchive-0.1.1/ext/archive_write_set_compression.o +0 -0
  10. data/ext/libarchive-0.1.1/ext/config.h +23 -0
  11. data/ext/libarchive-0.1.1/ext/config.log +230 -0
  12. data/ext/libarchive-0.1.1/ext/config.status +671 -0
  13. data/ext/libarchive-0.1.1/ext/libarchive.c +1 -1
  14. data/ext/libarchive-0.1.1/ext/libarchive.o +0 -0
  15. data/ext/libarchive-0.1.1/ext/libarchive_archive.c +7 -7
  16. data/ext/libarchive-0.1.1/ext/libarchive_archive.o +0 -0
  17. data/ext/libarchive-0.1.1/ext/libarchive_entry.c +6 -0
  18. data/ext/libarchive-0.1.1/ext/libarchive_entry.o +0 -0
  19. data/ext/libarchive-0.1.1/ext/libarchive_internal.h +0 -1
  20. data/ext/libarchive-0.1.1/ext/libarchive_reader.c +6 -4
  21. data/ext/libarchive-0.1.1/ext/libarchive_reader.o +0 -0
  22. data/ext/libarchive-0.1.1/ext/libarchive_ruby.so +0 -0
  23. data/ext/libarchive-0.1.1/ext/libarchive_win32.h +1 -1
  24. data/ext/libarchive-0.1.1/ext/libarchive_writer.c +2 -2
  25. data/ext/libarchive-0.1.1/ext/libarchive_writer.o +0 -0
  26. data/ext/libarchive-3.6.2/Makefile.in +16892 -0
  27. data/ext/libarchive-3.6.2/build/autoconf/ax_append_compile_flags.m4 +67 -0
  28. data/ext/libarchive-3.6.2/build/autoconf/ax_append_flag.m4 +71 -0
  29. data/ext/libarchive-3.6.2/build/autoconf/ax_check_compile_flag.m4 +74 -0
  30. data/ext/libarchive-3.6.2/build/autoconf/ax_require_defined.m4 +37 -0
  31. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/build/autoconf/check_stdcall_func.m4 +0 -0
  32. data/ext/libarchive-3.6.2/build/autoconf/compile +348 -0
  33. data/ext/libarchive-3.6.2/build/autoconf/config.guess +1754 -0
  34. data/ext/libarchive-3.6.2/build/autoconf/config.rpath +696 -0
  35. data/ext/libarchive-3.6.2/build/autoconf/config.sub +1890 -0
  36. data/ext/libarchive-3.6.2/build/autoconf/depcomp +791 -0
  37. data/ext/libarchive-3.6.2/build/autoconf/iconv.m4 +271 -0
  38. data/ext/libarchive-3.6.2/build/autoconf/install-sh +541 -0
  39. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/build/autoconf/la_uid_t.m4 +0 -0
  40. data/ext/libarchive-3.6.2/build/autoconf/lib-ld.m4 +109 -0
  41. data/ext/libarchive-3.6.2/build/autoconf/lib-link.m4 +777 -0
  42. data/ext/libarchive-3.6.2/build/autoconf/lib-prefix.m4 +224 -0
  43. data/ext/libarchive-3.6.2/build/autoconf/ltmain.sh +11251 -0
  44. data/ext/libarchive-3.6.2/build/autoconf/m4_ax_compile_check_sizeof.m4 +115 -0
  45. data/ext/libarchive-3.6.2/build/autoconf/missing +215 -0
  46. data/ext/libarchive-3.6.2/build/autoconf/test-driver +153 -0
  47. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/build/pkgconfig/libarchive.pc.in +4 -1
  48. data/ext/libarchive-3.6.2/config.h.in +1504 -0
  49. data/ext/libarchive-3.6.2/configure +25558 -0
  50. data/ext/libarchive-3.6.2/libarchive/archive.h +1212 -0
  51. data/ext/libarchive-3.6.2/libarchive/archive_acl.c +2097 -0
  52. data/ext/libarchive-3.6.2/libarchive/archive_acl_private.h +83 -0
  53. data/ext/libarchive-3.6.2/libarchive/archive_blake2.h +197 -0
  54. data/ext/libarchive-3.6.2/libarchive/archive_blake2_impl.h +161 -0
  55. data/ext/libarchive-3.6.2/libarchive/archive_blake2s_ref.c +369 -0
  56. data/ext/libarchive-3.6.2/libarchive/archive_blake2sp_ref.c +361 -0
  57. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_check_magic.c +63 -22
  58. data/ext/libarchive-3.6.2/libarchive/archive_cmdline.c +227 -0
  59. data/ext/libarchive-3.6.2/libarchive/archive_cmdline_private.h +47 -0
  60. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_crc32.h +17 -0
  61. data/ext/libarchive-3.6.2/libarchive/archive_cryptor.c +534 -0
  62. data/ext/libarchive-3.6.2/libarchive/archive_cryptor_private.h +188 -0
  63. data/ext/libarchive-3.6.2/libarchive/archive_digest.c +1505 -0
  64. data/ext/libarchive-3.6.2/libarchive/archive_digest_private.h +416 -0
  65. data/ext/libarchive-3.6.2/libarchive/archive_disk_acl_darwin.c +559 -0
  66. data/ext/libarchive-3.6.2/libarchive/archive_disk_acl_freebsd.c +712 -0
  67. data/ext/libarchive-3.6.2/libarchive/archive_disk_acl_linux.c +760 -0
  68. data/ext/libarchive-3.6.2/libarchive/archive_disk_acl_sunos.c +824 -0
  69. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_endian.h +48 -15
  70. data/ext/libarchive-3.6.2/libarchive/archive_entry.c +2149 -0
  71. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_entry.h +305 -106
  72. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_entry_copy_bhfi.c +5 -4
  73. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_entry_copy_stat.c +9 -3
  74. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_entry_link_resolver.c +104 -62
  75. data/ext/libarchive-3.6.2/libarchive/archive_entry_locale.h +92 -0
  76. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_entry_private.h +65 -49
  77. data/ext/libarchive-3.6.2/libarchive/archive_entry_sparse.c +156 -0
  78. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_entry_stat.c +6 -6
  79. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_entry_strmode.c +1 -1
  80. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_entry_xattr.c +4 -6
  81. data/ext/libarchive-3.6.2/libarchive/archive_getdate.c +1165 -0
  82. data/ext/libarchive-3.6.2/libarchive/archive_getdate.h +39 -0
  83. data/ext/libarchive-3.6.2/libarchive/archive_hmac.c +334 -0
  84. data/ext/libarchive-3.6.2/libarchive/archive_hmac_private.h +117 -0
  85. data/ext/libarchive-3.6.2/libarchive/archive_match.c +1875 -0
  86. data/ext/libarchive-3.6.2/libarchive/archive_openssl_evp_private.h +53 -0
  87. data/ext/libarchive-3.6.2/libarchive/archive_openssl_hmac_private.h +54 -0
  88. data/ext/libarchive-3.6.2/libarchive/archive_options.c +218 -0
  89. data/ext/libarchive-3.6.2/libarchive/archive_options_private.h +51 -0
  90. data/ext/libarchive-3.6.2/libarchive/archive_pack_dev.c +337 -0
  91. data/ext/libarchive-3.6.2/libarchive/archive_pack_dev.h +49 -0
  92. data/ext/libarchive-3.6.2/libarchive/archive_pathmatch.c +463 -0
  93. data/ext/libarchive-3.6.2/libarchive/archive_pathmatch.h +52 -0
  94. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_platform.h +77 -9
  95. data/ext/libarchive-3.6.2/libarchive/archive_platform_acl.h +55 -0
  96. data/ext/libarchive-3.6.2/libarchive/archive_platform_xattr.h +47 -0
  97. data/ext/libarchive-3.6.2/libarchive/archive_ppmd7.c +1168 -0
  98. data/ext/libarchive-3.6.2/libarchive/archive_ppmd7_private.h +119 -0
  99. data/ext/libarchive-3.6.2/libarchive/archive_ppmd8.c +1287 -0
  100. data/ext/libarchive-3.6.2/libarchive/archive_ppmd8_private.h +148 -0
  101. data/ext/libarchive-3.6.2/libarchive/archive_ppmd_private.h +151 -0
  102. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_private.h +74 -18
  103. data/ext/libarchive-3.6.2/libarchive/archive_random.c +272 -0
  104. data/ext/libarchive-3.6.2/libarchive/archive_random_private.h +36 -0
  105. data/ext/libarchive-3.6.2/libarchive/archive_rb.c +709 -0
  106. data/ext/libarchive-3.6.2/libarchive/archive_rb.h +113 -0
  107. data/ext/libarchive-3.6.2/libarchive/archive_read.c +1756 -0
  108. data/ext/libarchive-3.6.2/libarchive/archive_read_add_passphrase.c +190 -0
  109. data/ext/libarchive-3.6.2/libarchive/archive_read_append_filter.c +204 -0
  110. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_data_into_fd.c +64 -18
  111. data/ext/libarchive-3.6.2/libarchive/archive_read_disk_entry_from_file.c +1086 -0
  112. data/ext/libarchive-3.6.2/libarchive/archive_read_disk_posix.c +2732 -0
  113. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_disk_private.h +40 -4
  114. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_disk_set_standard_lookup.c +21 -11
  115. data/ext/libarchive-3.6.2/libarchive/archive_read_disk_windows.c +2479 -0
  116. data/ext/libarchive-3.6.2/libarchive/archive_read_extract.c +60 -0
  117. data/ext/{libarchive-2.8.4/libarchive/archive_read_extract.c → libarchive-3.6.2/libarchive/archive_read_extract2.c} +34 -61
  118. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_open_fd.c +70 -49
  119. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_open_file.c +38 -23
  120. data/ext/libarchive-3.6.2/libarchive/archive_read_open_filename.c +586 -0
  121. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_open_memory.c +58 -28
  122. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_private.h +127 -59
  123. data/ext/libarchive-3.6.2/libarchive/archive_read_set_format.c +117 -0
  124. data/ext/libarchive-3.6.2/libarchive/archive_read_set_options.c +133 -0
  125. data/ext/{libarchive-2.8.4/libarchive/archive_read_support_compression_all.c → libarchive-3.6.2/libarchive/archive_read_support_filter_all.c} +35 -10
  126. data/ext/libarchive-3.6.2/libarchive/archive_read_support_filter_by_code.c +83 -0
  127. data/ext/{libarchive-2.8.4/libarchive/archive_read_support_compression_bzip2.c → libarchive-3.6.2/libarchive/archive_read_support_filter_bzip2.c} +38 -26
  128. data/ext/{libarchive-2.8.4/libarchive/archive_read_support_compression_compress.c → libarchive-3.6.2/libarchive/archive_read_support_filter_compress.c} +52 -44
  129. data/ext/libarchive-3.6.2/libarchive/archive_read_support_filter_grzip.c +112 -0
  130. data/ext/{libarchive-2.8.4/libarchive/archive_read_support_compression_gzip.c → libarchive-3.6.2/libarchive/archive_read_support_filter_gzip.c} +108 -37
  131. data/ext/libarchive-3.6.2/libarchive/archive_read_support_filter_lrzip.c +122 -0
  132. data/ext/libarchive-3.6.2/libarchive/archive_read_support_filter_lz4.c +742 -0
  133. data/ext/libarchive-3.6.2/libarchive/archive_read_support_filter_lzop.c +499 -0
  134. data/ext/{libarchive-2.8.4/libarchive/archive_read_support_compression_none.c → libarchive-3.6.2/libarchive/archive_read_support_filter_none.c} +15 -3
  135. data/ext/{libarchive-2.8.4/libarchive/archive_read_support_compression_program.c → libarchive-3.6.2/libarchive/archive_read_support_filter_program.c} +114 -77
  136. data/ext/{libarchive-2.8.4/libarchive/archive_read_support_compression_rpm.c → libarchive-3.6.2/libarchive/archive_read_support_filter_rpm.c} +31 -31
  137. data/ext/{libarchive-2.8.4/libarchive/archive_read_support_compression_uu.c → libarchive-3.6.2/libarchive/archive_read_support_filter_uu.c} +141 -85
  138. data/ext/{libarchive-2.8.4/libarchive/archive_read_support_compression_xz.c → libarchive-3.6.2/libarchive/archive_read_support_filter_xz.c} +369 -284
  139. data/ext/libarchive-3.6.2/libarchive/archive_read_support_filter_zstd.c +297 -0
  140. data/ext/libarchive-3.6.2/libarchive/archive_read_support_format_7zip.c +3900 -0
  141. data/ext/libarchive-3.6.2/libarchive/archive_read_support_format_all.c +89 -0
  142. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_support_format_ar.c +126 -72
  143. data/ext/libarchive-3.6.2/libarchive/archive_read_support_format_by_code.c +92 -0
  144. data/ext/libarchive-3.6.2/libarchive/archive_read_support_format_cab.c +3228 -0
  145. data/ext/libarchive-3.6.2/libarchive/archive_read_support_format_cpio.c +1104 -0
  146. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_support_format_empty.c +14 -11
  147. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_support_format_iso9660.c +990 -541
  148. data/ext/libarchive-3.6.2/libarchive/archive_read_support_format_lha.c +2916 -0
  149. data/ext/libarchive-3.6.2/libarchive/archive_read_support_format_mtree.c +2150 -0
  150. data/ext/libarchive-3.6.2/libarchive/archive_read_support_format_rar.c +3797 -0
  151. data/ext/libarchive-3.6.2/libarchive/archive_read_support_format_rar5.c +4251 -0
  152. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_support_format_raw.c +38 -31
  153. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_support_format_tar.c +1157 -629
  154. data/ext/libarchive-3.6.2/libarchive/archive_read_support_format_warc.c +848 -0
  155. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_read_support_format_xar.c +439 -258
  156. data/ext/libarchive-3.6.2/libarchive/archive_read_support_format_zip.c +4270 -0
  157. data/ext/libarchive-3.6.2/libarchive/archive_string.c +4240 -0
  158. data/ext/libarchive-3.6.2/libarchive/archive_string.h +243 -0
  159. data/ext/libarchive-3.6.2/libarchive/archive_string_composition.h +2292 -0
  160. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_string_sprintf.c +44 -16
  161. data/ext/libarchive-3.6.2/libarchive/archive_util.c +655 -0
  162. data/ext/libarchive-3.6.2/libarchive/archive_version_details.c +151 -0
  163. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_virtual.c +85 -16
  164. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_windows.c +214 -541
  165. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_windows.h +74 -106
  166. data/ext/libarchive-3.6.2/libarchive/archive_write.c +828 -0
  167. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter.c +72 -0
  168. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_b64encode.c +304 -0
  169. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_by_name.c +77 -0
  170. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_bzip2.c +401 -0
  171. data/ext/{libarchive-2.8.4/libarchive/archive_write_set_compression_compress.c → libarchive-3.6.2/libarchive/archive_write_add_filter_compress.c} +86 -131
  172. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_grzip.c +135 -0
  173. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_gzip.c +442 -0
  174. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_lrzip.c +197 -0
  175. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_lz4.c +700 -0
  176. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_lzop.c +478 -0
  177. data/ext/{libarchive-2.8.4/libarchive/archive_read_support_format_all.c → libarchive-3.6.2/libarchive/archive_write_add_filter_none.c} +11 -11
  178. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_program.c +391 -0
  179. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_uuencode.c +295 -0
  180. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_xz.c +545 -0
  181. data/ext/libarchive-3.6.2/libarchive/archive_write_add_filter_zstd.c +418 -0
  182. data/ext/libarchive-3.6.2/libarchive/archive_write_disk_posix.c +4711 -0
  183. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_disk_private.h +9 -2
  184. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_disk_set_standard_lookup.c +30 -29
  185. data/ext/libarchive-3.6.2/libarchive/archive_write_disk_windows.c +2842 -0
  186. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_open_fd.c +15 -10
  187. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_open_file.c +15 -9
  188. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_open_filename.c +128 -20
  189. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_open_memory.c +7 -18
  190. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_private.h +72 -29
  191. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_set_format.c +56 -3
  192. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_7zip.c +2322 -0
  193. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_set_format_ar.c +54 -34
  194. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_set_format_by_name.c +20 -2
  195. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_cpio.c +11 -0
  196. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_cpio_binary.c +610 -0
  197. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_cpio_newc.c +457 -0
  198. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_cpio_odc.c +500 -0
  199. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_filter_by_ext.c +142 -0
  200. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_gnutar.c +755 -0
  201. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_iso9660.c +8165 -0
  202. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_mtree.c +2217 -0
  203. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_set_format_pax.c +1049 -387
  204. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_private.h +42 -0
  205. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_raw.c +125 -0
  206. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_set_format_shar.c +62 -47
  207. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/archive_write_set_format_ustar.c +279 -108
  208. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_v7tar.c +638 -0
  209. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_warc.c +453 -0
  210. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_xar.c +3259 -0
  211. data/ext/libarchive-3.6.2/libarchive/archive_write_set_format_zip.c +1704 -0
  212. data/ext/libarchive-3.6.2/libarchive/archive_write_set_options.c +130 -0
  213. data/ext/libarchive-3.6.2/libarchive/archive_write_set_passphrase.c +95 -0
  214. data/ext/libarchive-3.6.2/libarchive/archive_xxhash.h +48 -0
  215. data/ext/libarchive-3.6.2/libarchive/config_freebsd.h +271 -0
  216. data/ext/{libarchive-2.8.4 → libarchive-3.6.2}/libarchive/filter_fork.h +10 -5
  217. data/ext/{libarchive-2.8.4/libarchive/filter_fork.c → libarchive-3.6.2/libarchive/filter_fork_posix.c} +98 -19
  218. data/ext/libarchive-3.6.2/libarchive/filter_fork_windows.c +236 -0
  219. data/ext/libarchive-3.6.2/libarchive/xxhash.c +525 -0
  220. data/ext/libarchive-static-makefile +144 -80
  221. data/ext/libarchive-static-wrapper-makefile +1 -1
  222. data/ext/zlib-1.2.13/Makefile.in +404 -0
  223. data/ext/{zlib-1.2.5 → zlib-1.2.13}/adler32.c +51 -34
  224. data/ext/{zlib-1.2.5 → zlib-1.2.13}/compress.c +27 -21
  225. data/ext/zlib-1.2.13/configure +922 -0
  226. data/ext/zlib-1.2.13/crc32.c +1125 -0
  227. data/ext/zlib-1.2.13/crc32.h +9446 -0
  228. data/ext/{zlib-1.2.5 → zlib-1.2.13}/deflate.c +842 -459
  229. data/ext/{zlib-1.2.5 → zlib-1.2.13}/deflate.h +37 -33
  230. data/ext/{zlib-1.2.5 → zlib-1.2.13}/gzclose.c +0 -0
  231. data/ext/{zlib-1.2.5 → zlib-1.2.13}/gzguts.h +103 -16
  232. data/ext/{zlib-1.2.5 → zlib-1.2.13}/gzlib.c +155 -53
  233. data/ext/zlib-1.2.13/gzread.c +650 -0
  234. data/ext/zlib-1.2.13/gzwrite.c +677 -0
  235. data/ext/{zlib-1.2.5 → zlib-1.2.13}/infback.c +24 -12
  236. data/ext/{zlib-1.2.5 → zlib-1.2.13}/inffast.c +49 -66
  237. data/ext/{zlib-1.2.5 → zlib-1.2.13}/inffast.h +0 -0
  238. data/ext/{zlib-1.2.5 → zlib-1.2.13}/inffixed.h +3 -3
  239. data/ext/{zlib-1.2.5 → zlib-1.2.13}/inflate.c +209 -94
  240. data/ext/{zlib-1.2.5 → zlib-1.2.13}/inflate.h +9 -5
  241. data/ext/{zlib-1.2.5 → zlib-1.2.13}/inftrees.c +24 -50
  242. data/ext/{zlib-1.2.5 → zlib-1.2.13}/inftrees.h +1 -1
  243. data/ext/{zlib-1.2.5 → zlib-1.2.13}/trees.c +135 -198
  244. data/ext/{zlib-1.2.5 → zlib-1.2.13}/trees.h +0 -0
  245. data/ext/zlib-1.2.13/uncompr.c +93 -0
  246. data/ext/{zlib-1.2.5 → zlib-1.2.13}/zconf.h +182 -63
  247. data/ext/{zlib-1.2.5 → zlib-1.2.13}/zlib.h +617 -295
  248. data/ext/{zlib-1.2.5 → zlib-1.2.13}/zutil.c +50 -41
  249. data/ext/{zlib-1.2.5 → zlib-1.2.13}/zutil.h +83 -82
  250. metadata +244 -137
  251. data/ext/libarchive-0.1.1/libarchive.c +0 -1762
  252. data/ext/libarchive-2.8.4/Makefile.in +0 -7076
  253. data/ext/libarchive-2.8.4/build/autoconf/compile +0 -143
  254. data/ext/libarchive-2.8.4/build/autoconf/config.guess +0 -1502
  255. data/ext/libarchive-2.8.4/build/autoconf/config.sub +0 -1708
  256. data/ext/libarchive-2.8.4/build/autoconf/depcomp +0 -630
  257. data/ext/libarchive-2.8.4/build/autoconf/install-sh +0 -291
  258. data/ext/libarchive-2.8.4/build/autoconf/ltmain.sh +0 -8406
  259. data/ext/libarchive-2.8.4/build/autoconf/missing +0 -376
  260. data/ext/libarchive-2.8.4/config.h.in +0 -772
  261. data/ext/libarchive-2.8.4/configure +0 -17916
  262. data/ext/libarchive-2.8.4/libarchive/archive.h +0 -741
  263. data/ext/libarchive-2.8.4/libarchive/archive_entry.c +0 -2202
  264. data/ext/libarchive-2.8.4/libarchive/archive_hash.h +0 -281
  265. data/ext/libarchive-2.8.4/libarchive/archive_read.c +0 -1249
  266. data/ext/libarchive-2.8.4/libarchive/archive_read_disk.c +0 -198
  267. data/ext/libarchive-2.8.4/libarchive/archive_read_disk_entry_from_file.c +0 -570
  268. data/ext/libarchive-2.8.4/libarchive/archive_read_open_filename.c +0 -272
  269. data/ext/libarchive-2.8.4/libarchive/archive_read_support_format_cpio.c +0 -777
  270. data/ext/libarchive-2.8.4/libarchive/archive_read_support_format_mtree.c +0 -1304
  271. data/ext/libarchive-2.8.4/libarchive/archive_read_support_format_zip.c +0 -903
  272. data/ext/libarchive-2.8.4/libarchive/archive_string.c +0 -453
  273. data/ext/libarchive-2.8.4/libarchive/archive_string.h +0 -148
  274. data/ext/libarchive-2.8.4/libarchive/archive_util.c +0 -391
  275. data/ext/libarchive-2.8.4/libarchive/archive_write.c +0 -466
  276. data/ext/libarchive-2.8.4/libarchive/archive_write_disk.c +0 -2628
  277. data/ext/libarchive-2.8.4/libarchive/archive_write_set_compression_bzip2.c +0 -408
  278. data/ext/libarchive-2.8.4/libarchive/archive_write_set_compression_gzip.c +0 -477
  279. data/ext/libarchive-2.8.4/libarchive/archive_write_set_compression_none.c +0 -257
  280. data/ext/libarchive-2.8.4/libarchive/archive_write_set_compression_program.c +0 -347
  281. data/ext/libarchive-2.8.4/libarchive/archive_write_set_compression_xz.c +0 -438
  282. data/ext/libarchive-2.8.4/libarchive/archive_write_set_format_cpio.c +0 -344
  283. data/ext/libarchive-2.8.4/libarchive/archive_write_set_format_cpio_newc.c +0 -295
  284. data/ext/libarchive-2.8.4/libarchive/archive_write_set_format_mtree.c +0 -1050
  285. data/ext/libarchive-2.8.4/libarchive/archive_write_set_format_zip.c +0 -667
  286. data/ext/libarchive-2.8.4/libarchive/config_freebsd.h +0 -154
  287. data/ext/libarchive-2.8.4/libarchive/filter_fork_windows.c +0 -113
  288. data/ext/zlib-1.2.5/Makefile.in +0 -257
  289. data/ext/zlib-1.2.5/configure +0 -596
  290. data/ext/zlib-1.2.5/crc32.c +0 -442
  291. data/ext/zlib-1.2.5/crc32.h +0 -441
  292. data/ext/zlib-1.2.5/example.c +0 -565
  293. data/ext/zlib-1.2.5/gzread.c +0 -653
  294. data/ext/zlib-1.2.5/gzwrite.c +0 -531
  295. data/ext/zlib-1.2.5/minigzip.c +0 -440
  296. data/ext/zlib-1.2.5/uncompr.c +0 -59
@@ -1,596 +0,0 @@
1
- #!/bin/sh
2
- # configure script for zlib.
3
- #
4
- # Normally configure builds both a static and a shared library.
5
- # If you want to build just a static library, use: ./configure --static
6
- #
7
- # To impose specific compiler or flags or install directory, use for example:
8
- # prefix=$HOME CC=cc CFLAGS="-O4" ./configure
9
- # or for csh/tcsh users:
10
- # (setenv prefix $HOME; setenv CC cc; setenv CFLAGS "-O4"; ./configure)
11
-
12
- # Incorrect settings of CC or CFLAGS may prevent creating a shared library.
13
- # If you have problems, try without defining CC and CFLAGS before reporting
14
- # an error.
15
-
16
- if [ -n "${CHOST}" ]; then
17
- uname="$(echo "${CHOST}" | sed -e 's/^[^-]*-\([^-]*\)$/\1/' -e 's/^[^-]*-[^-]*-\([^-]*\)$/\1/' -e 's/^[^-]*-[^-]*-\([^-]*\)-.*$/\1/')"
18
- CROSS_PREFIX="${CHOST}-"
19
- fi
20
-
21
- STATICLIB=libz.a
22
- LDFLAGS="${LDFLAGS} -L. ${STATICLIB}"
23
- VER=`sed -n -e '/VERSION "/s/.*"\(.*\)".*/\1/p' < zlib.h`
24
- VER3=`sed -n -e '/VERSION "/s/.*"\([0-9]*\\.[0-9]*\\.[0-9]*\).*/\1/p' < zlib.h`
25
- VER2=`sed -n -e '/VERSION "/s/.*"\([0-9]*\\.[0-9]*\)\\..*/\1/p' < zlib.h`
26
- VER1=`sed -n -e '/VERSION "/s/.*"\([0-9]*\)\\..*/\1/p' < zlib.h`
27
- if "${CROSS_PREFIX}ar" --version >/dev/null 2>/dev/null || test $? -lt 126; then
28
- AR=${AR-"${CROSS_PREFIX}ar"}
29
- test -n "${CROSS_PREFIX}" && echo Using ${AR}
30
- else
31
- AR=${AR-"ar"}
32
- test -n "${CROSS_PREFIX}" && echo Using ${AR}
33
- fi
34
- AR_RC="${AR} rc"
35
- if "${CROSS_PREFIX}ranlib" --version >/dev/null 2>/dev/null || test $? -lt 126; then
36
- RANLIB=${RANLIB-"${CROSS_PREFIX}ranlib"}
37
- test -n "${CROSS_PREFIX}" && echo Using ${RANLIB}
38
- else
39
- RANLIB=${RANLIB-"ranlib"}
40
- fi
41
- if "${CROSS_PREFIX}nm" --version >/dev/null 2>/dev/null || test $? -lt 126; then
42
- NM=${NM-"${CROSS_PREFIX}nm"}
43
- test -n "${CROSS_PREFIX}" && echo Using ${NM}
44
- else
45
- NM=${NM-"nm"}
46
- fi
47
- LDCONFIG=${LDCONFIG-"ldconfig"}
48
- LDSHAREDLIBC="${LDSHAREDLIBC--lc}"
49
- prefix=${prefix-/usr/local}
50
- exec_prefix=${exec_prefix-'${prefix}'}
51
- libdir=${libdir-'${exec_prefix}/lib'}
52
- sharedlibdir=${sharedlibdir-'${libdir}'}
53
- includedir=${includedir-'${prefix}/include'}
54
- mandir=${mandir-'${prefix}/share/man'}
55
- shared_ext='.so'
56
- shared=1
57
- zprefix=0
58
- build64=0
59
- gcc=0
60
- old_cc="$CC"
61
- old_cflags="$CFLAGS"
62
-
63
- while test $# -ge 1
64
- do
65
- case "$1" in
66
- -h* | --help)
67
- echo 'usage:'
68
- echo ' configure [--zprefix] [--prefix=PREFIX] [--eprefix=EXPREFIX]'
69
- echo ' [--static] [--64] [--libdir=LIBDIR] [--sharedlibdir=LIBDIR]'
70
- echo ' [--includedir=INCLUDEDIR]'
71
- exit 0 ;;
72
- -p*=* | --prefix=*) prefix=`echo $1 | sed 's/.*=//'`; shift ;;
73
- -e*=* | --eprefix=*) exec_prefix=`echo $1 | sed 's/.*=//'`; shift ;;
74
- -l*=* | --libdir=*) libdir=`echo $1 | sed 's/.*=//'`; shift ;;
75
- --sharedlibdir=*) sharedlibdir=`echo $1 | sed 's/.*=//'`; shift ;;
76
- -i*=* | --includedir=*) includedir=`echo $1 | sed 's/.*=//'`;shift ;;
77
- -u*=* | --uname=*) uname=`echo $1 | sed 's/.*=//'`;shift ;;
78
- -p* | --prefix) prefix="$2"; shift; shift ;;
79
- -e* | --eprefix) exec_prefix="$2"; shift; shift ;;
80
- -l* | --libdir) libdir="$2"; shift; shift ;;
81
- -i* | --includedir) includedir="$2"; shift; shift ;;
82
- -s* | --shared | --enable-shared) shared=1; shift ;;
83
- -t | --static) shared=0; shift ;;
84
- -z* | --zprefix) zprefix=1; shift ;;
85
- -6* | --64) build64=1; shift ;;
86
- --sysconfdir=*) echo "ignored option: --sysconfdir"; shift ;;
87
- --localstatedir=*) echo "ignored option: --localstatedir"; shift ;;
88
- *) echo "unknown option: $1"; echo "$0 --help for help"; exit 1 ;;
89
- esac
90
- done
91
-
92
- test=ztest$$
93
- cat > $test.c <<EOF
94
- extern int getchar();
95
- int hello() {return getchar();}
96
- EOF
97
-
98
- test -z "$CC" && echo Checking for ${CROSS_PREFIX}gcc...
99
- cc=${CC-${CROSS_PREFIX}gcc}
100
- cflags=${CFLAGS-"-O3"}
101
- # to force the asm version use: CFLAGS="-O3 -DASMV" ./configure
102
- case "$cc" in
103
- *gcc*) gcc=1 ;;
104
- esac
105
-
106
- if test "$gcc" -eq 1 && ($cc -c $cflags $test.c) 2>/dev/null; then
107
- CC="$cc"
108
- SFLAGS="${CFLAGS--O3} -fPIC"
109
- CFLAGS="${CFLAGS--O3}"
110
- if test $build64 -eq 1; then
111
- CFLAGS="${CFLAGS} -m64"
112
- SFLAGS="${SFLAGS} -m64"
113
- fi
114
- if test "${ZLIBGCCWARN}" = "YES"; then
115
- CFLAGS="${CFLAGS} -Wall -Wextra -pedantic"
116
- fi
117
- if test -z "$uname"; then
118
- uname=`(uname -s || echo unknown) 2>/dev/null`
119
- fi
120
- case "$uname" in
121
- Linux* | linux* | GNU | GNU/* | *BSD | DragonFly) LDSHARED=${LDSHARED-"$cc -shared -Wl,-soname,libz.so.1,--version-script,zlib.map"} ;;
122
- CYGWIN* | Cygwin* | cygwin* | OS/2*)
123
- EXE='.exe' ;;
124
- MINGW*|mingw*)
125
- # temporary bypass
126
- rm -f $test.[co] $test $test$shared_ext
127
- echo "Please use win32/Makefile.gcc instead."
128
- exit 1
129
- LDSHARED=${LDSHARED-"$cc -shared"}
130
- LDSHAREDLIBC=""
131
- EXE='.exe' ;;
132
- QNX*) # This is for QNX6. I suppose that the QNX rule below is for QNX2,QNX4
133
- # (alain.bonnefoy@icbt.com)
134
- LDSHARED=${LDSHARED-"$cc -shared -Wl,-hlibz.so.1"} ;;
135
- HP-UX*)
136
- LDSHARED=${LDSHARED-"$cc -shared $SFLAGS"}
137
- case `(uname -m || echo unknown) 2>/dev/null` in
138
- ia64)
139
- shared_ext='.so'
140
- SHAREDLIB='libz.so' ;;
141
- *)
142
- shared_ext='.sl'
143
- SHAREDLIB='libz.sl' ;;
144
- esac ;;
145
- Darwin*) shared_ext='.dylib'
146
- SHAREDLIB=libz$shared_ext
147
- SHAREDLIBV=libz.$VER$shared_ext
148
- SHAREDLIBM=libz.$VER1$shared_ext
149
- LDSHARED=${LDSHARED-"$cc -dynamiclib -install_name $libdir/$SHAREDLIBM -compatibility_version $VER1 -current_version $VER3"} ;;
150
- *) LDSHARED=${LDSHARED-"$cc -shared"} ;;
151
- esac
152
- else
153
- # find system name and corresponding cc options
154
- CC=${CC-cc}
155
- gcc=0
156
- if test -z "$uname"; then
157
- uname=`(uname -sr || echo unknown) 2>/dev/null`
158
- fi
159
- case "$uname" in
160
- HP-UX*) SFLAGS=${CFLAGS-"-O +z"}
161
- CFLAGS=${CFLAGS-"-O"}
162
- # LDSHARED=${LDSHARED-"ld -b +vnocompatwarnings"}
163
- LDSHARED=${LDSHARED-"ld -b"}
164
- case `(uname -m || echo unknown) 2>/dev/null` in
165
- ia64)
166
- shared_ext='.so'
167
- SHAREDLIB='libz.so' ;;
168
- *)
169
- shared_ext='.sl'
170
- SHAREDLIB='libz.sl' ;;
171
- esac ;;
172
- IRIX*) SFLAGS=${CFLAGS-"-ansi -O2 -rpath ."}
173
- CFLAGS=${CFLAGS-"-ansi -O2"}
174
- LDSHARED=${LDSHARED-"cc -shared -Wl,-soname,libz.so.1"} ;;
175
- OSF1\ V4*) SFLAGS=${CFLAGS-"-O -std1"}
176
- CFLAGS=${CFLAGS-"-O -std1"}
177
- LDFLAGS="${LDFLAGS} -Wl,-rpath,."
178
- LDSHARED=${LDSHARED-"cc -shared -Wl,-soname,libz.so -Wl,-msym -Wl,-rpath,$(libdir) -Wl,-set_version,${VER}:1.0"} ;;
179
- OSF1*) SFLAGS=${CFLAGS-"-O -std1"}
180
- CFLAGS=${CFLAGS-"-O -std1"}
181
- LDSHARED=${LDSHARED-"cc -shared -Wl,-soname,libz.so.1"} ;;
182
- QNX*) SFLAGS=${CFLAGS-"-4 -O"}
183
- CFLAGS=${CFLAGS-"-4 -O"}
184
- LDSHARED=${LDSHARED-"cc"}
185
- RANLIB=${RANLIB-"true"}
186
- AR_RC="cc -A" ;;
187
- SCO_SV\ 3.2*) SFLAGS=${CFLAGS-"-O3 -dy -KPIC "}
188
- CFLAGS=${CFLAGS-"-O3"}
189
- LDSHARED=${LDSHARED-"cc -dy -KPIC -G"} ;;
190
- SunOS\ 5*) LDSHARED=${LDSHARED-"cc -G"}
191
- case `(uname -m || echo unknown) 2>/dev/null` in
192
- i86*)
193
- SFLAGS=${CFLAGS-"-xpentium -fast -KPIC -R."}
194
- CFLAGS=${CFLAGS-"-xpentium -fast"} ;;
195
- *)
196
- SFLAGS=${CFLAGS-"-fast -xcg92 -KPIC -R."}
197
- CFLAGS=${CFLAGS-"-fast -xcg92"} ;;
198
- esac ;;
199
- SunOS\ 4*) SFLAGS=${CFLAGS-"-O2 -PIC"}
200
- CFLAGS=${CFLAGS-"-O2"}
201
- LDSHARED=${LDSHARED-"ld"} ;;
202
- SunStudio\ 9*) SFLAGS=${CFLAGS-"-fast -xcode=pic32 -xtarget=ultra3 -xarch=v9b"}
203
- CFLAGS=${CFLAGS-"-fast -xtarget=ultra3 -xarch=v9b"}
204
- LDSHARED=${LDSHARED-"cc -xarch=v9b"} ;;
205
- UNIX_System_V\ 4.2.0)
206
- SFLAGS=${CFLAGS-"-KPIC -O"}
207
- CFLAGS=${CFLAGS-"-O"}
208
- LDSHARED=${LDSHARED-"cc -G"} ;;
209
- UNIX_SV\ 4.2MP)
210
- SFLAGS=${CFLAGS-"-Kconform_pic -O"}
211
- CFLAGS=${CFLAGS-"-O"}
212
- LDSHARED=${LDSHARED-"cc -G"} ;;
213
- OpenUNIX\ 5)
214
- SFLAGS=${CFLAGS-"-KPIC -O"}
215
- CFLAGS=${CFLAGS-"-O"}
216
- LDSHARED=${LDSHARED-"cc -G"} ;;
217
- AIX*) # Courtesy of dbakker@arrayasolutions.com
218
- SFLAGS=${CFLAGS-"-O -qmaxmem=8192"}
219
- CFLAGS=${CFLAGS-"-O -qmaxmem=8192"}
220
- LDSHARED=${LDSHARED-"xlc -G"} ;;
221
- # send working options for other systems to zlib@gzip.org
222
- *) SFLAGS=${CFLAGS-"-O"}
223
- CFLAGS=${CFLAGS-"-O"}
224
- LDSHARED=${LDSHARED-"cc -shared"} ;;
225
- esac
226
- fi
227
-
228
- SHAREDLIB=${SHAREDLIB-"libz$shared_ext"}
229
- SHAREDLIBV=${SHAREDLIBV-"libz$shared_ext.$VER"}
230
- SHAREDLIBM=${SHAREDLIBM-"libz$shared_ext.$VER1"}
231
-
232
- if test $shared -eq 1; then
233
- echo Checking for shared library support...
234
- # we must test in two steps (cc then ld), required at least on SunOS 4.x
235
- if test "`($CC -w -c $SFLAGS $test.c) 2>&1`" = "" &&
236
- test "`($LDSHARED $SFLAGS -o $test$shared_ext $test.o) 2>&1`" = ""; then
237
- echo Building shared library $SHAREDLIBV with $CC.
238
- elif test -z "$old_cc" -a -z "$old_cflags"; then
239
- echo No shared library support.
240
- shared=0;
241
- else
242
- echo Tested $CC -w -c $SFLAGS $test.c
243
- $CC -w -c $SFLAGS $test.c
244
- echo Tested $LDSHARED $SFLAGS -o $test$shared_ext $test.o
245
- $LDSHARED $SFLAGS -o $test$shared_ext $test.o
246
- echo 'No shared library support; try without defining CC and CFLAGS'
247
- shared=0;
248
- fi
249
- fi
250
- if test $shared -eq 0; then
251
- LDSHARED="$CC"
252
- ALL="static"
253
- TEST="all teststatic"
254
- SHAREDLIB=""
255
- SHAREDLIBV=""
256
- SHAREDLIBM=""
257
- echo Building static library $STATICLIB version $VER with $CC.
258
- else
259
- ALL="static shared"
260
- TEST="all teststatic testshared"
261
- fi
262
-
263
- cat > $test.c <<EOF
264
- #include <sys/types.h>
265
- off64_t dummy = 0;
266
- EOF
267
- if test "`($CC -c $CFLAGS -D_LARGEFILE64_SOURCE=1 $test.c) 2>&1`" = ""; then
268
- CFLAGS="${CFLAGS} -D_LARGEFILE64_SOURCE=1"
269
- SFLAGS="${SFLAGS} -D_LARGEFILE64_SOURCE=1"
270
- ALL="${ALL} all64"
271
- TEST="${TEST} test64"
272
- echo "Checking for off64_t... Yes."
273
- echo "Checking for fseeko... Yes."
274
- else
275
- echo "Checking for off64_t... No."
276
- cat > $test.c <<EOF
277
- #include <stdio.h>
278
- int main(void) {
279
- fseeko(NULL, 0, 0);
280
- return 0;
281
- }
282
- EOF
283
- if test "`($CC $CFLAGS -o $test $test.c) 2>&1`" = ""; then
284
- echo "Checking for fseeko... Yes."
285
- else
286
- CFLAGS="${CFLAGS} -DNO_FSEEKO"
287
- SFLAGS="${SFLAGS} -DNO_FSEEKO"
288
- echo "Checking for fseeko... No."
289
- fi
290
- fi
291
-
292
- cp -p zconf.h.in zconf.h
293
-
294
- cat > $test.c <<EOF
295
- #include <unistd.h>
296
- int main() { return 0; }
297
- EOF
298
- if test "`($CC -c $CFLAGS $test.c) 2>&1`" = ""; then
299
- sed < zconf.h "/^#ifdef HAVE_UNISTD_H.* may be/s/def HAVE_UNISTD_H\(.*\) may be/ 1\1 was/" > zconf.temp.h
300
- mv zconf.temp.h zconf.h
301
- echo "Checking for unistd.h... Yes."
302
- else
303
- echo "Checking for unistd.h... No."
304
- fi
305
-
306
- if test $zprefix -eq 1; then
307
- sed < zconf.h "/#ifdef Z_PREFIX.* may be/s/def Z_PREFIX\(.*\) may be/ 1\1 was/" > zconf.temp.h
308
- mv zconf.temp.h zconf.h
309
- echo "Using z_ prefix on all symbols."
310
- fi
311
-
312
- cat > $test.c <<EOF
313
- #include <stdio.h>
314
- #include <stdarg.h>
315
- #include "zconf.h"
316
-
317
- int main()
318
- {
319
- #ifndef STDC
320
- choke me
321
- #endif
322
-
323
- return 0;
324
- }
325
- EOF
326
-
327
- if test "`($CC -c $CFLAGS $test.c) 2>&1`" = ""; then
328
- echo "Checking whether to use vs[n]printf() or s[n]printf()... using vs[n]printf()."
329
-
330
- cat > $test.c <<EOF
331
- #include <stdio.h>
332
- #include <stdarg.h>
333
-
334
- int mytest(const char *fmt, ...)
335
- {
336
- char buf[20];
337
- va_list ap;
338
-
339
- va_start(ap, fmt);
340
- vsnprintf(buf, sizeof(buf), fmt, ap);
341
- va_end(ap);
342
- return 0;
343
- }
344
-
345
- int main()
346
- {
347
- return (mytest("Hello%d\n", 1));
348
- }
349
- EOF
350
-
351
- if test "`($CC $CFLAGS -o $test $test.c) 2>&1`" = ""; then
352
- echo "Checking for vsnprintf() in stdio.h... Yes."
353
-
354
- cat >$test.c <<EOF
355
- #include <stdio.h>
356
- #include <stdarg.h>
357
-
358
- int mytest(const char *fmt, ...)
359
- {
360
- int n;
361
- char buf[20];
362
- va_list ap;
363
-
364
- va_start(ap, fmt);
365
- n = vsnprintf(buf, sizeof(buf), fmt, ap);
366
- va_end(ap);
367
- return n;
368
- }
369
-
370
- int main()
371
- {
372
- return (mytest("Hello%d\n", 1));
373
- }
374
- EOF
375
-
376
- if test "`($CC -c $CFLAGS $test.c) 2>&1`" = ""; then
377
- echo "Checking for return value of vsnprintf()... Yes."
378
- else
379
- CFLAGS="$CFLAGS -DHAS_vsnprintf_void"
380
- SFLAGS="$SFLAGS -DHAS_vsnprintf_void"
381
- echo "Checking for return value of vsnprintf()... No."
382
- echo " WARNING: apparently vsnprintf() does not return a value. zlib"
383
- echo " can build but will be open to possible string-format security"
384
- echo " vulnerabilities."
385
- fi
386
- else
387
- CFLAGS="$CFLAGS -DNO_vsnprintf"
388
- SFLAGS="$SFLAGS -DNO_vsnprintf"
389
- echo "Checking for vsnprintf() in stdio.h... No."
390
- echo " WARNING: vsnprintf() not found, falling back to vsprintf(). zlib"
391
- echo " can build but will be open to possible buffer-overflow security"
392
- echo " vulnerabilities."
393
-
394
- cat >$test.c <<EOF
395
- #include <stdio.h>
396
- #include <stdarg.h>
397
-
398
- int mytest(const char *fmt, ...)
399
- {
400
- int n;
401
- char buf[20];
402
- va_list ap;
403
-
404
- va_start(ap, fmt);
405
- n = vsprintf(buf, fmt, ap);
406
- va_end(ap);
407
- return n;
408
- }
409
-
410
- int main()
411
- {
412
- return (mytest("Hello%d\n", 1));
413
- }
414
- EOF
415
-
416
- if test "`($CC -c $CFLAGS $test.c) 2>&1`" = ""; then
417
- echo "Checking for return value of vsprintf()... Yes."
418
- else
419
- CFLAGS="$CFLAGS -DHAS_vsprintf_void"
420
- SFLAGS="$SFLAGS -DHAS_vsprintf_void"
421
- echo "Checking for return value of vsprintf()... No."
422
- echo " WARNING: apparently vsprintf() does not return a value. zlib"
423
- echo " can build but will be open to possible string-format security"
424
- echo " vulnerabilities."
425
- fi
426
- fi
427
- else
428
- echo "Checking whether to use vs[n]printf() or s[n]printf()... using s[n]printf()."
429
-
430
- cat >$test.c <<EOF
431
- #include <stdio.h>
432
-
433
- int mytest()
434
- {
435
- char buf[20];
436
-
437
- snprintf(buf, sizeof(buf), "%s", "foo");
438
- return 0;
439
- }
440
-
441
- int main()
442
- {
443
- return (mytest());
444
- }
445
- EOF
446
-
447
- if test "`($CC $CFLAGS -o $test $test.c) 2>&1`" = ""; then
448
- echo "Checking for snprintf() in stdio.h... Yes."
449
-
450
- cat >$test.c <<EOF
451
- #include <stdio.h>
452
-
453
- int mytest()
454
- {
455
- char buf[20];
456
-
457
- return snprintf(buf, sizeof(buf), "%s", "foo");
458
- }
459
-
460
- int main()
461
- {
462
- return (mytest());
463
- }
464
- EOF
465
-
466
- if test "`($CC -c $CFLAGS $test.c) 2>&1`" = ""; then
467
- echo "Checking for return value of snprintf()... Yes."
468
- else
469
- CFLAGS="$CFLAGS -DHAS_snprintf_void"
470
- SFLAGS="$SFLAGS -DHAS_snprintf_void"
471
- echo "Checking for return value of snprintf()... No."
472
- echo " WARNING: apparently snprintf() does not return a value. zlib"
473
- echo " can build but will be open to possible string-format security"
474
- echo " vulnerabilities."
475
- fi
476
- else
477
- CFLAGS="$CFLAGS -DNO_snprintf"
478
- SFLAGS="$SFLAGS -DNO_snprintf"
479
- echo "Checking for snprintf() in stdio.h... No."
480
- echo " WARNING: snprintf() not found, falling back to sprintf(). zlib"
481
- echo " can build but will be open to possible buffer-overflow security"
482
- echo " vulnerabilities."
483
-
484
- cat >$test.c <<EOF
485
- #include <stdio.h>
486
-
487
- int mytest()
488
- {
489
- char buf[20];
490
-
491
- return sprintf(buf, "%s", "foo");
492
- }
493
-
494
- int main()
495
- {
496
- return (mytest());
497
- }
498
- EOF
499
-
500
- if test "`($CC -c $CFLAGS $test.c) 2>&1`" = ""; then
501
- echo "Checking for return value of sprintf()... Yes."
502
- else
503
- CFLAGS="$CFLAGS -DHAS_sprintf_void"
504
- SFLAGS="$SFLAGS -DHAS_sprintf_void"
505
- echo "Checking for return value of sprintf()... No."
506
- echo " WARNING: apparently sprintf() does not return a value. zlib"
507
- echo " can build but will be open to possible string-format security"
508
- echo " vulnerabilities."
509
- fi
510
- fi
511
- fi
512
-
513
- if test "$gcc" -eq 1; then
514
- cat > $test.c <<EOF
515
- #if ((__GNUC__-0) * 10 + __GNUC_MINOR__-0 >= 33)
516
- # define ZLIB_INTERNAL __attribute__((visibility ("hidden")))
517
- #else
518
- # define ZLIB_INTERNAL
519
- #endif
520
- int ZLIB_INTERNAL foo;
521
- int main()
522
- {
523
- return 0;
524
- }
525
- EOF
526
- if test "`($CC -c $CFLAGS $test.c) 2>&1`" = ""; then
527
- echo "Checking for attribute(visibility) support... Yes."
528
- else
529
- CFLAGS="$CFLAGS -DNO_VIZ"
530
- SFLAGS="$SFLAGS -DNO_VIZ"
531
- echo "Checking for attribute(visibility) support... No."
532
- fi
533
- fi
534
-
535
- CPP=${CPP-"$CC -E"}
536
- case $CFLAGS in
537
- *ASMV*)
538
- if test "`$NM $test.o | grep _hello`" = ""; then
539
- CPP="$CPP -DNO_UNDERLINE"
540
- echo Checking for underline in external names... No.
541
- else
542
- echo Checking for underline in external names... Yes.
543
- fi ;;
544
- esac
545
-
546
- rm -f $test.[co] $test $test$shared_ext
547
-
548
- # udpate Makefile
549
- sed < Makefile.in "
550
- /^CC *=/s#=.*#=$CC#
551
- /^CFLAGS *=/s#=.*#=$CFLAGS#
552
- /^SFLAGS *=/s#=.*#=$SFLAGS#
553
- /^LDFLAGS *=/s#=.*#=$LDFLAGS#
554
- /^LDSHARED *=/s#=.*#=$LDSHARED#
555
- /^CPP *=/s#=.*#=$CPP#
556
- /^STATICLIB *=/s#=.*#=$STATICLIB#
557
- /^SHAREDLIB *=/s#=.*#=$SHAREDLIB#
558
- /^SHAREDLIBV *=/s#=.*#=$SHAREDLIBV#
559
- /^SHAREDLIBM *=/s#=.*#=$SHAREDLIBM#
560
- /^AR *=/s#=.*#=$AR_RC#
561
- /^RANLIB *=/s#=.*#=$RANLIB#
562
- /^LDCONFIG *=/s#=.*#=$LDCONFIG#
563
- /^LDSHAREDLIBC *=/s#=.*#=$LDSHAREDLIBC#
564
- /^EXE *=/s#=.*#=$EXE#
565
- /^prefix *=/s#=.*#=$prefix#
566
- /^exec_prefix *=/s#=.*#=$exec_prefix#
567
- /^libdir *=/s#=.*#=$libdir#
568
- /^sharedlibdir *=/s#=.*#=$sharedlibdir#
569
- /^includedir *=/s#=.*#=$includedir#
570
- /^mandir *=/s#=.*#=$mandir#
571
- /^all: */s#:.*#: $ALL#
572
- /^test: */s#:.*#: $TEST#
573
- " > Makefile
574
-
575
- sed < zlib.pc.in "
576
- /^CC *=/s#=.*#=$CC#
577
- /^CFLAGS *=/s#=.*#=$CFLAGS#
578
- /^CPP *=/s#=.*#=$CPP#
579
- /^LDSHARED *=/s#=.*#=$LDSHARED#
580
- /^STATICLIB *=/s#=.*#=$STATICLIB#
581
- /^SHAREDLIB *=/s#=.*#=$SHAREDLIB#
582
- /^SHAREDLIBV *=/s#=.*#=$SHAREDLIBV#
583
- /^SHAREDLIBM *=/s#=.*#=$SHAREDLIBM#
584
- /^AR *=/s#=.*#=$AR_RC#
585
- /^RANLIB *=/s#=.*#=$RANLIB#
586
- /^EXE *=/s#=.*#=$EXE#
587
- /^prefix *=/s#=.*#=$prefix#
588
- /^exec_prefix *=/s#=.*#=$exec_prefix#
589
- /^libdir *=/s#=.*#=$libdir#
590
- /^sharedlibdir *=/s#=.*#=$sharedlibdir#
591
- /^includedir *=/s#=.*#=$includedir#
592
- /^mandir *=/s#=.*#=$mandir#
593
- /^LDFLAGS *=/s#=.*#=$LDFLAGS#
594
- " | sed -e "
595
- s/\@VERSION\@/$VER/g;
596
- " > zlib.pc