diff options
author | Igor Pashev <igor.pashev@nexenta.com> | 2013-03-04 14:23:19 +0400 |
---|---|---|
committer | Igor Pashev <igor.pashev@nexenta.com> | 2013-03-04 14:23:19 +0400 |
commit | 59ad6e21eac75fcdd3aeb84b430e32a3366c2fec (patch) | |
tree | 4b042e46f76e90fc14ed63b6a2ad82c6804b540a | |
parent | ceaa1852eeab8151817dc3986136be98d586fa08 (diff) | |
download | cibs-pkgs-59ad6e21eac75fcdd3aeb84b430e32a3366c2fec.tar.gz |
zip 3.0 with Debian patches
-rw-r--r-- | zip/Makefile | 45 | ||||
-rw-r--r-- | zip/patches/01-typo-it-is-transferring-not-transfering | 27 | ||||
-rw-r--r-- | zip/patches/02-typo-it-is-privileges-not-priviliges | 27 | ||||
-rw-r--r-- | zip/patches/03-manpages-in-section-1-not-in-section-1l | 47 | ||||
-rw-r--r-- | zip/patches/04-do-not-set-unwanted-cflags | 15 | ||||
-rw-r--r-- | zip/patches/05-typo-it-is-preceding-not-preceeding | 26 | ||||
-rw-r--r-- | zip/patches/06-stack-markings-to-avoid-executable-stack | 21 | ||||
-rw-r--r-- | zip/patches/07-fclose-in-file-not-fclose-x | 16 | ||||
-rw-r--r-- | zip/patches/08-hardening-build-fix-1 | 25 | ||||
-rw-r--r-- | zip/patches/09-hardening-build-fix-2 | 16 | ||||
-rw-r--r-- | zip/patches/series | 9 | ||||
-rw-r--r-- | zip/zip.p5m | 15 |
12 files changed, 289 insertions, 0 deletions
diff --git a/zip/Makefile b/zip/Makefile new file mode 100644 index 0000000..cdd5fbe --- /dev/null +++ b/zip/Makefile @@ -0,0 +1,45 @@ +package ?= ips + +include /usr/share/cibs/rules/$(package).mk +include /usr/share/cibs/rules/archive.mk +include /usr/share/cibs/rules/64.mk +include /usr/share/cibs/rules/copy.mk +include /usr/share/cibs/rules/patch.mk + + +summary := a compression and file packaging/archive utility +license-file := LICENSE +license := Info-ZIP license + +home := http://www.info-zip.org/Zip.html +name := zip +version := 3.0 +archive := zip30.tar.gz +download := http://sourceforge.net/projects/infozip/files/Zip%203.x%20%28latest%29/$(version)/$(archive) + + +build-depends += \ + library/libbz2 + +CFLAGS += -Wall -I. -DUNIX + +configure-%-stamp: + cd $(builddir) && LDFLAGS="$(LDFLAGS)" sh unix/configure "$(CC)" "$(CFLAGS) $(CPPFLAGS)" + touch $@ + +build-%-stamp: + cd $(builddir) && $(MAKE) -f unix/Makefile generic + touch $@ + +install-%-stamp: + cd $(builddir) && $(MAKE) -f unix/Makefile install prefix=$(topdir)/$(protodir)/usr + cd $(protodir)/usr && mkdir share && mv man share/ + touch $@ + + +checksum-zip30.tar.gz := \ + md5:7b74551e63f8ee6aab6fbc86676c0d37 \ + sha1:c9f4099ecf2772b53c2dd4a8e508064ce015d182 \ + sha256:f0e8bb1f9b7eb0b01285495a2699df3a4b766784c1765a8f1aeedf63c0806369 \ + size:1118845 + diff --git a/zip/patches/01-typo-it-is-transferring-not-transfering b/zip/patches/01-typo-it-is-transferring-not-transfering new file mode 100644 index 0000000..3d1b9cb --- /dev/null +++ b/zip/patches/01-typo-it-is-transferring-not-transfering @@ -0,0 +1,27 @@ +From: A Costa <agcosta@gis.net> +Subject: manpage typo: transfering -> transferring +Bug-Debian: http://bugs.debian.org/301914 +X-Debian-version: 2.31-2 + +--- a/man/zip.1 ++++ b/man/zip.1 +@@ -2756,7 +2756,7 @@ + .I zip + handles some of the conversion internally. + When using Kermit to transfer zip files from VMS to MSDOS, type "set +-file type block" on VMS. When transfering from MSDOS to VMS, type ++file type block" on VMS. When transferring from MSDOS to VMS, type + "set file type fixed" on VMS. In both cases, type "set file type + binary" on MSDOS. + .LP +--- a/zip.txt ++++ b/zip.txt +@@ -1957,7 +1957,7 @@ + be converted using Rahul Dhesi's BILF program. This version of zip + handles some of the conversion internally. When using Kermit to trans- + fer zip files from VMS to MSDOS, type "set file type block" on VMS. +- When transfering from MSDOS to VMS, type "set file type fixed" on VMS. ++ When transferring from MSDOS to VMS, type "set file type fixed" on VMS. + In both cases, type "set file type binary" on MSDOS. + + Under some older VMS versions, zip may hang for file specifications diff --git a/zip/patches/02-typo-it-is-privileges-not-priviliges b/zip/patches/02-typo-it-is-privileges-not-priviliges new file mode 100644 index 0000000..70a3ffa --- /dev/null +++ b/zip/patches/02-typo-it-is-privileges-not-priviliges @@ -0,0 +1,27 @@ +From: A Costa <agcosta@gis.net> +Subject: manpage typo: priviliges -> privileges +Bug-Debian: http://bugs.debian.org/309877 +X-Debian-version: 2.31-3 + +--- a/man/zip.1 ++++ b/man/zip.1 +@@ -2403,7 +2403,7 @@ + .TP + .PD + .B \-\-use\-privileges +-[WIN32] Use priviliges (if granted) to obtain all aspects of WinNT security. ++[WIN32] Use privileges (if granted) to obtain all aspects of WinNT security. + .TP + .PD 0 + .B \-@ +--- a/zip.txt ++++ b/zip.txt +@@ -1696,7 +1696,7 @@ + + -! + --use-privileges +- [WIN32] Use priviliges (if granted) to obtain all aspects of ++ [WIN32] Use privileges (if granted) to obtain all aspects of + WinNT security. + + -@ diff --git a/zip/patches/03-manpages-in-section-1-not-in-section-1l b/zip/patches/03-manpages-in-section-1-not-in-section-1l new file mode 100644 index 0000000..23ea767 --- /dev/null +++ b/zip/patches/03-manpages-in-section-1-not-in-section-1l @@ -0,0 +1,47 @@ +From: Lior Kaplan <webmaster@guides.co.il> +Subject: put manpages in section 1, not in section 1L +Bug-Debian: http://bugs.debian.org/308045 +X-Debian-version: 2.31-3 + +--- a/man/zip.1 ++++ b/man/zip.1 +@@ -13,7 +13,7 @@ + .\" 30 August 2007, 27 April 2008, 25 May 2008, 27 May 2008 by EG, + .\" 7 June 2008 by SMS and EG; 12 June 2008 by EG) + .\" +-.TH ZIP 1L "16 June 2008 (v3.0)" Info-ZIP ++.TH ZIP 1 "16 June 2008 (v3.0)" Info-ZIP + .SH NAME + zip \- package and compress (archive) files + .SH SYNOPSIS +@@ -53,14 +53,14 @@ + and is compatible with PKZIP (Phil Katz's ZIP for MSDOS systems). + .LP + A companion program +-.RI ( unzip (1L)) ++.RI ( unzip (1)) + unpacks + .I zip + archives. + The + .I zip + and +-.IR unzip (1L) ++.IR unzip (1) + programs can work with archives produced by PKZIP (supporting + most PKZIP features up to PKZIP version 4.6), + and PKZIP and PKUNZIP can work with archives produced by +@@ -2661,10 +2661,10 @@ + [VMS] see ZIPOPT + .SH "SEE ALSO" + compress(1), +-shar(1L), ++shar(1), + tar(1), +-unzip(1L), +-gzip(1L) ++unzip(1), ++gzip(1) + .SH DIAGNOSTICS + The exit status (or error level) approximates the exit codes defined by PKWARE + and takes on the following values, except under VMS: diff --git a/zip/patches/04-do-not-set-unwanted-cflags b/zip/patches/04-do-not-set-unwanted-cflags new file mode 100644 index 0000000..35c4238 --- /dev/null +++ b/zip/patches/04-do-not-set-unwanted-cflags @@ -0,0 +1,15 @@ +From: Santiago Vila <sanvila@debian.org> +Subject: Do not set unwanted CFLAGS, as it breaks DEB_BUILD_OPTIONS +X-Debian-version: 2.32-1 + +--- a/unix/configure ++++ b/unix/configure +@@ -98,7 +98,7 @@ + _EOF_ + $CC $CFLAGS -c conftest.c > /dev/null 2>/dev/null + if test $? -eq 0; then +- CFLAGS_OPT='-O3' ++ # CFLAGS_OPT='-O3' + echo " GNU C ($CFLAGS_OPT)" + # Special Mac OS X shared library "ld" option? + if test ` uname -s 2> /dev/null ` = 'Darwin'; then diff --git a/zip/patches/05-typo-it-is-preceding-not-preceeding b/zip/patches/05-typo-it-is-preceding-not-preceeding new file mode 100644 index 0000000..5f54b12 --- /dev/null +++ b/zip/patches/05-typo-it-is-preceding-not-preceeding @@ -0,0 +1,26 @@ +From: Santiago Vila <sanvila@debian.org> +Subject: manpage typo: preceeding -> preceding +X-Debian-version: 3.0-2 + +--- a/man/zip.1 ++++ b/man/zip.1 +@@ -502,7 +502,7 @@ + where the option starts with --, has a multicharacter name, can + include a trailing dash to negate the option (if the option + supports it), and can have a value (option argument) specified by +-preceeding it with = (no spaces). Values can also follow the ++preceding it with = (no spaces). Values can also follow the + argument. So + .IP + \fC--before-date=mmddyyyy\fP +--- a/zip.txt ++++ b/zip.txt +@@ -376,7 +376,7 @@ + + where the option starts with --, has a multicharacter name, can include + a trailing dash to negate the option (if the option supports it), and +- can have a value (option argument) specified by preceeding it with = ++ can have a value (option argument) specified by preceding it with = + (no spaces). Values can also follow the argument. So + + --before-date=mmddyyyy diff --git a/zip/patches/06-stack-markings-to-avoid-executable-stack b/zip/patches/06-stack-markings-to-avoid-executable-stack new file mode 100644 index 0000000..9d8a8ff --- /dev/null +++ b/zip/patches/06-stack-markings-to-avoid-executable-stack @@ -0,0 +1,21 @@ +From: Kees Cook <kees@debian.org> +Subject: put stack markings in i386 assembly to avoid executable stack +Bug-Debian: http://bugs.debian.org/528280 +X-Debian-version: 3.0-2 + +--- a/crc_i386.S ++++ b/crc_i386.S +@@ -302,3 +302,5 @@ + #endif /* i386 || _i386 || _I386 || __i386 */ + + #endif /* !USE_ZLIB && !CRC_TABLE_ONLY */ ++.section .note.GNU-stack, "", @progbits ++.previous +--- a/match.S ++++ b/match.S +@@ -405,3 +405,5 @@ + #endif /* i386 || _I386 || _i386 || __i386 */ + + #endif /* !USE_ZLIB */ ++.section .note.GNU-stack, "", @progbits ++.previous diff --git a/zip/patches/07-fclose-in-file-not-fclose-x b/zip/patches/07-fclose-in-file-not-fclose-x new file mode 100644 index 0000000..7575279 --- /dev/null +++ b/zip/patches/07-fclose-in-file-not-fclose-x @@ -0,0 +1,16 @@ +From: Christian Spieler +Subject: zipnote.c: Close in_file instead of undefined file x +Bug-Debian: http://bugs.debian.org/628594 +X-Debian-version: 3.0-4 + +--- a/zipnote.c ++++ b/zipnote.c +@@ -661,7 +661,7 @@ + if ((r = zipcopy(z)) != ZE_OK) + ziperr(r, "was copying an entry"); + } +- fclose(x); ++ fclose(in_file); + + /* Write central directory and end of central directory with new comments */ + if ((c = zftello(y)) == (zoff_t)-1) /* get start of central */ diff --git a/zip/patches/08-hardening-build-fix-1 b/zip/patches/08-hardening-build-fix-1 new file mode 100644 index 0000000..94ddb71 --- /dev/null +++ b/zip/patches/08-hardening-build-fix-1 @@ -0,0 +1,25 @@ +From: Santiago Vila <sanvila@debian.org> +Subject: Use format specifier %s to print strings, not the string itself +Bug-Debian: http://bugs.debian.org/673476 +X-Debian-version: 3.0-5 + +--- a/zip.c ++++ b/zip.c +@@ -1028,7 +1028,7 @@ + + for (i = 0; i < sizeof(text)/sizeof(char *); i++) + { +- printf(text[i]); ++ printf("%s", text[i]); + putchar('\n'); + } + #ifdef DOS +@@ -1225,7 +1225,7 @@ + CR_MAJORVER, CR_MINORVER, CR_BETA_VER, CR_VERSION_DATE); + for (i = 0; i < sizeof(cryptnote)/sizeof(char *); i++) + { +- printf(cryptnote[i]); ++ printf("%s", cryptnote[i]); + putchar('\n'); + } + ++i; /* crypt support means there IS at least one compilation option */ diff --git a/zip/patches/09-hardening-build-fix-2 b/zip/patches/09-hardening-build-fix-2 new file mode 100644 index 0000000..52ecd91 --- /dev/null +++ b/zip/patches/09-hardening-build-fix-2 @@ -0,0 +1,16 @@ +From: Santiago Vila <sanvila@debian.org> +Subject: unix/configure: Take linking flags from the environment +Bug-Debian: http://bugs.debian.org/673476 +X-Debian-version: 3.0-5 + +--- a/unix/configure ++++ b/unix/configure +@@ -18,7 +18,7 @@ + + CC=${1-cc} + CFLAGS=${2-"-I. -DUNIX"} +-LFLAGS1='' ++LFLAGS1=${LDFLAGS} + LFLAGS2='' + LN="ln -s" + diff --git a/zip/patches/series b/zip/patches/series new file mode 100644 index 0000000..21f5988 --- /dev/null +++ b/zip/patches/series @@ -0,0 +1,9 @@ +01-typo-it-is-transferring-not-transfering +02-typo-it-is-privileges-not-priviliges +03-manpages-in-section-1-not-in-section-1l +04-do-not-set-unwanted-cflags +05-typo-it-is-preceding-not-preceeding +06-stack-markings-to-avoid-executable-stack +07-fclose-in-file-not-fclose-x +08-hardening-build-fix-1 +09-hardening-build-fix-2 diff --git a/zip/zip.p5m b/zip/zip.p5m new file mode 100644 index 0000000..21c8b4c --- /dev/null +++ b/zip/zip.p5m @@ -0,0 +1,15 @@ +set name=pkg.fmri value=pkg:/compress/zip@$(ips-version) +set name=pkg.summary value="$(summary)" +set name=info.upstream-url value="$(home)" +set name=info.source-url value="$(download)" + +license $(license-file) license="$(license)" + +file path=usr/bin/zipsplit +file path=usr/bin/zip +file path=usr/bin/zipnote +file path=usr/bin/zipcloak +file path=usr/share/man/man1/zipsplit.1 +file path=usr/share/man/man1/zip.1 +file path=usr/share/man/man1/zipnote.1 +file path=usr/share/man/man1/zipcloak.1 |