unzip-vl.spec 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345
  1. %define src_file unzip60
  2. Summary: A utility for unpacking zip files.
  3. Summary(ja): zip ファイルを展開するユーティリティ
  4. Name: unzip
  5. Version: 6.0
  6. Release: 8%{?_dist_release}
  7. Group: accessories
  8. Vendor: Project Vine
  9. Distribution: Vine Linux
  10. Packager: daisuke
  11. License: BSD
  12. URL: http://www.info-zip.org/UnZip.html
  13. Source: http://downloads.sourceforge.net/infozip/%{src_file}.tar.gz
  14. # Not sent to upstream.
  15. Patch1: unzip-6.0-bzip2-configure.patch
  16. # Upstream plans to do this in zip (hopefully also in unzip).
  17. Patch2: unzip-6.0-exec-shield.patch
  18. # Upstream plans to do similar thing.
  19. Patch3: unzip-6.0-close.patch
  20. # Details in rhbz#532380.
  21. # Reported to upstream: http://www.info-zip.org/board/board.pl?m-1259575993/
  22. Patch4: unzip-6.0-attribs-overflow.patch
  23. # Not sent to upstream, as it's Fedora/RHEL specific.
  24. # Modify the configure script to accept var LFLAGS2 so linking can be configurable
  25. # from the spec file. In addition '-s' is still removed as before
  26. Patch5: unzip-6.0-configure.patch
  27. Patch6: unzip-6.0-manpage-fix.patch
  28. # Update match.c with recmatch() from zip 3.0's util.c
  29. # This also resolves the license issue in that old function.
  30. # Original came from here: https://projects.parabolagnulinux.org/abslibre.git/plain/libre/unzip-libre/match.patch
  31. Patch7: unzip-6.0-fix-recmatch.patch
  32. # Update process.c
  33. Patch8: unzip-6.0-symlink.patch
  34. # change using of macro "case_map" by "to_up"
  35. Patch9: unzip-6.0-caseinsensitive.patch
  36. # downstream fix for "-Werror=format-security"
  37. # upstream doesn't want hear about this option again
  38. Patch10: unzip-6.0-format-secure.patch
  39. Patch11: unzip-6.0-valgrind.patch
  40. Patch12: unzip-6.0-x-option.patch
  41. Patch13: unzip-6.0-overflow.patch
  42. Patch14: unzip-6.0-cve-2014-8139.patch
  43. Patch15: unzip-6.0-cve-2014-8140.patch
  44. Patch16: unzip-6.0-cve-2014-8141.patch
  45. Patch17: unzip-6.0-overflow-long-fsize.patch
  46. # Fix heap overflow and infinite loop when invalid input is given (#1260947)
  47. Patch18: unzip-6.0-heap-overflow-infloop.patch
  48. # support non-{latin,unicode} encoding
  49. Patch19: unzip-6.0-alt-iconv-utf8.patch
  50. Patch20: unzip-6.0-alt-iconv-utf8-print.patch
  51. Patch21: 0001-Fix-CVE-2016-9844-rhbz-1404283.patch
  52. # restore unix timestamp accurately
  53. Patch22: unzip-6.0-timestamp.patch
  54. # fix possible heap based stack overflow in passwd protected files
  55. Patch23: unzip-6.0-cve-2018-1000035-heap-based-overflow.patch
  56. Patch24: unzip-6.0-cve-2018-18384.patch
  57. # covscan issues
  58. Patch25: unzip-6.0-COVSCAN-fix-unterminated-string.patch
  59. Patch26: unzip-zipbomb-part1.patch
  60. Patch27: unzip-zipbomb-part2.patch
  61. Patch28: unzip-zipbomb-part3.patch
  62. Patch29: unzip-zipbomb-manpage.patch
  63. # https://github.com/madler/unzip/commit/13f0260beae851f7d5dd96e9ef757d8d6d7daac1
  64. Patch30: unzip-6.0-fix-false-overlap-detection-on-32bit-systems.patch
  65. # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=963996
  66. Patch31: unzip-fix-buffer-length.patch
  67. # japanese charset support
  68. # https://gist.github.com/hamano/573753
  69. Patch200: unzip-6.0-japanese_charset.patch
  70. # just ignore -E option, older nls patch use this.
  71. Patch201: unzip-6.0-ignore-E-option.patch
  72. # support ja_JP.utf8 locale
  73. Patch202: unzip-6.0-japanese_charset-utf8.patch
  74. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  75. BuildRequires: bzip2-devel, gcc
  76. %description
  77. The unzip utility is used to list, test, or extract files from a zip
  78. archive. Zip archives are commonly found on MS-DOS systems. The zip
  79. utility, included in the zip package, creates zip archives. Zip and
  80. unzip are both compatible with archives created by PKWARE(R)'s PKZIP
  81. for MS-DOS, but the programs' options and default behaviors do differ
  82. in some respects.
  83. Install the unzip package if you need to list, test or extract files from
  84. a zip archive.
  85. %description -l ja
  86. unzip ユーティリティは,zip アーカイブ内のファイルを一覧表示したり,
  87. テスト/展開する為に使うユーティリティです.zip アーカイブは MS-DOS
  88. システムで一般的に使われます.
  89. zip パッケージに含まれる zip プログラムは zip アーカイブを
  90. 作成するのに使います.
  91. zip と unzip は PKWARE(R) の MS-DOS 用 PKZIP で作成された zip アーカイブに
  92. 対応していますが,デフォルトの動作やプログラムオプション等一部が
  93. 異なります.
  94. %debug_package
  95. %prep
  96. %setup -q -n %{src_file}
  97. %patch1 -p1
  98. %patch2 -p1
  99. %patch3 -p1
  100. %patch4 -p1
  101. %patch5 -p1
  102. %patch6 -p1
  103. %patch7 -p1
  104. %patch8 -p1
  105. %patch9 -p1
  106. %patch10 -p1
  107. %patch11 -p1
  108. %patch12 -p1
  109. %patch13 -p1
  110. %patch14 -p1
  111. %patch15 -p1
  112. %patch16 -p1
  113. %patch17 -p1
  114. %patch18 -p1
  115. %patch19 -p1
  116. %patch20 -p1
  117. %patch21 -p1
  118. %patch22 -p1
  119. %patch23 -p1
  120. %patch24 -p1
  121. %patch25 -p1
  122. %patch26 -p1
  123. %patch27 -p1
  124. %patch28 -p1
  125. %patch29 -p1
  126. %patch30 -p1
  127. %patch31 -p1
  128. %patch200 -p1 -b .jp
  129. %patch201 -p1 -b .ignore-E
  130. %patch202 -p1 -b .utf8
  131. %build
  132. make -f unix/Makefile \
  133. CF_NOOPT="-I. -DUNIX $RPM_OPT_FLAGS -DNOMEMCPY -DIZ_HAVE_UXUIDGID -DNO_LCHMOD -D_MBCS" \
  134. LFLAGS2="%{?__global_ldflags}" \
  135. generic_gcc
  136. %install
  137. [ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf $RPM_BUILD_ROOT
  138. make -f unix/Makefile prefix=$RPM_BUILD_ROOT%{_prefix} MANDIR=$RPM_BUILD_ROOT/%{_mandir}/man1 INSTALL="cp -p" install
  139. %clean
  140. [ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf $RPM_BUILD_ROOT
  141. %files
  142. %defattr(-,root,root)
  143. %license LICENSE
  144. %doc README BUGS INSTALL
  145. %{_bindir}/*
  146. %{_mandir}/*/*
  147. %changelog
  148. * Wed Sep 23 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 6.0-8
  149. - added Patch31.
  150. - changed options for make.
  151. * Wed Sep 23 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 6.0-7
  152. - imported Patch30 from gentoo.
  153. * Sun Sep 13 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 6.0-6
  154. - re-imported Patch1-29 from rawhide.
  155. * Sun May 19 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 6.0-5
  156. - imported Patch17-18, 21-24 from rawhide.
  157. - replaced Patch100-120 to rawhide's one.
  158. * Sun Feb 8 2015 IWAI, Masaharu <iwaim.sub@gmail.com> 6.0-4
  159. - add Patch130 for CVE-2014-9636 (heap overflow)
  160. * Sun Jan 18 2015 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 6.0-3
  161. - add Patch100 for fix CVE-2014-8139 (crc-overflow)
  162. - add Patch110 for fix CVE-2014-8140 (test-compr-eb)
  163. - add Patch120 for fix CVE-2014-8141 (getzip64data)
  164. - add Patch9-12 from fc22
  165. * Thu Jul 03 2014 Daisuke SUZUKI <daisuke@vinelinux.org> 6.0-2
  166. - add patch202 to support ja_JP.utf8
  167. * Thu May 22 2014 Daisuke SUZUKI <daisuke@vinelinux.org> 6.0-1
  168. - update to 6.0
  169. - replace nls patch.
  170. * Tue Apr 5 2011 IWAI, Masaharu <iwai@alib.jp> 5.52-3vl6
  171. - build on current VineSeed
  172. * Wed Apr 15 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 5.52-2
  173. - spec in utf-8
  174. - add NLS patch
  175. * Wed Apr 09 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 5.52-1
  176. - new upstream release
  177. - add patch13 from fc8
  178. - update patches to fit new release & drop old patches
  179. - with new versioning polity
  180. * Wed Apr 09 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 5.51-11vl4
  181. - fix changelog typo
  182. * Wed Apr 09 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 5.51-10vl4
  183. - update patch100 to fix ppc issue (it was patch5, from rhel4)
  184. - renumber patchs
  185. - add patch 2,3 to support big archive (from rhel4)
  186. - with new versioning polity
  187. * Fri Mar 21 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 5.51-9vl1.1
  188. - add patch5 for fix CVE-2005-4667
  189. - add patch6 for fix CVE-2008-0888
  190. - add Vendor/Distribution tag
  191. * Tue May 10 2005 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 5.51-9vl1
  192. - new upstream release
  193. - based on 5.51-9 Fedora development
  194. * Thu Feb 10 2005 Ivana Varekova <varekova@redhat.com> 5.51-9
  195. - fix the other problem with unpacking zipfiles containing symlinks
  196. (bug #134073)
  197. * Thu Feb 03 2005 Ivana Varekova <varekova@redhat.com> 5.51-8
  198. - fix segfault with unpacking of zipfiles containing dangling symlinks
  199. (bug #134073)
  200. * Thu Dec 02 2004 Lon Hohberger <lhh@redhat.com> 5.51-5
  201. - Fix segfault on extraction of symlinks
  202. * Mon Jun 21 2004 Lon Hohberger <lhh@redhat.com> 5.51-4
  203. - Extend max file/archive size to 2^32-8193 (4294959103) bytes
  204. * Tue Jun 08 2004 Lon Hohberger <lhh@redhat.com> 5.51-1.1
  205. - Update to 5.51; remove dotdot patch.
  206. * Tue Sep 23 2003 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 5.50-5vl2
  207. - merged patch1 from Vine Linux 2.6 updates
  208. - Thu Aug 28 2003 Tomohiro 'Tomo-p' KATO <tomop@teamgedoh.net> 5.50-4vl3
  209. - replace patch1 from RedHat (RHSA-2003:199-02).
  210. - Fri Jul 18 2003 Kunio Murasawa <murasawa@fa2.so-net.ne.jp> 5.50-4vl2
  211. - added patch1 from Redhat (RHSA-2003:199-01)
  212. * Sun Dec 1 2002 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 5.50-5vl1
  213. - modified changelog section :-P (merge rawhidee changelogs)
  214. - Sun Dec 1 2002 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 5.50-4vl2
  215. - rebuild with new toolchains
  216. - Sun May 26 2002 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 5.50-4vl1
  217. - based on 5.50-4 from Rawhide
  218. - previous Vine version was 5.41-3vl1:
  219. - Tue Dec 26 2000 MATSUBAYASHI 'Shaolin' Kohji <shaolin@rhythmaning.org>
  220. - 5.41-3vl1
  221. - based on 5.41-3 from Rawhide
  222. - added Japanese summary and description
  223. - use better macros
  224. * Fri Jun 21 2002 Tim Powers <timp@redhat.com>
  225. - automated rebuild
  226. * Thu May 23 2002 Tim Powers <timp@redhat.com>
  227. - automated rebuild
  228. * Thu Apr 25 2002 Trond Eivind Glomsr︰ <teg@redhat.com> 5.50-3
  229. - Rebuild
  230. * Tue Apr 2 2002 Trond Eivind Glomsr︰ <teg@redhat.com> 5.50-2
  231. - Make it not strip
  232. * Wed Mar 13 2002 Trond Eivind Glomsr︰ <teg@redhat.com> 5.50-1
  233. - 5.50
  234. * Thu Feb 21 2002 Trond Eivind Glomsr︰ <teg@redhat.com> 5.42-3
  235. - Rebuild
  236. * Wed Jan 09 2002 Tim Powers <timp@redhat.com>
  237. - automated rebuild
  238. * Mon May 21 2001 Trond Eivind Glomsr︰ <teg@redhat.com>
  239. - 5.42
  240. - Don't strip binaries explicitly
  241. - build without assembly, it doesn't seem to increase performance
  242. - make it respect RPM_OPT_FLAGS, define _GNU_SOURCE
  243. - use %%{_tmppath}
  244. - "License:" replaces "Copyright:"
  245. - Update URL
  246. - include zipgrep
  247. - COPYING doesn't exist anymore, include LICENSE instead
  248. * Thu Jul 13 2000 Prospector <bugzilla@redhat.com>
  249. - automatic rebuild
  250. * Sun Jun 11 2000 BIll Nottingham <notting@redhat.com>
  251. - rebuild in new env.; FHS fixes.
  252. * Tue Apr 18 2000 Bernhard Rosenkraenzer <bero@redhat.com>
  253. - 4.51 (an acceptable license at last...)
  254. * Thu Feb 3 2000 Bill Nottingham <notting@redhat.com>
  255. - handle compressed man pages
  256. * Fri Jul 30 1999 Bill Nottingham <notting@redhat.com>
  257. - update to 5.40
  258. * Sun Mar 21 1999 Cristian Gafton <gafton@redhat.com>
  259. - auto rebuild in the new build environment (release 5)
  260. * Thu Dec 17 1998 Michael Maher <mike@redhat.com>
  261. - built for 6.0
  262. * Tue Aug 11 1998 Jeff Johnson <jbj@redhat.com>
  263. - build root
  264. * Mon Apr 27 1998 Prospector System <bugs@redhat.com>
  265. - translations modified for de, fr, tr
  266. * Tue Oct 21 1997 Erik Troan <ewt@redhat.com>
  267. - builds on non i386 platforms
  268. * Mon Oct 20 1997 Otto Hammersmith <otto@redhat.com>
  269. - updated the version
  270. * Thu Jul 10 1997 Erik Troan <ewt@redhat.com>
  271. - built against glibc