From f354ff8939d91a160a1b13050e5b20fa8b2c1482 Mon Sep 17 00:00:00 2001 From: Erik Faye-Lund Date: Thu, 29 Sep 2011 22:15:31 +0200 Subject: [PATCH] gzip: build native tools from source Recent git versions have started to call up gzip for git-archive. However, our gzip is an MSYS program, which ends up messing up line-endings in the binary stream between git and gzip. Building a native gzip makes this problem go away. Signed-off-by: Erik Faye-Lund --- src/gzip/patches/0001-use-windows-exe-prefix.patch | 25 ++++++++++++++ src/gzip/release.sh | 38 ++++++++++++++++++++++ 2 files changed, 63 insertions(+) create mode 100644 src/gzip/patches/0001-use-windows-exe-prefix.patch create mode 100644 src/gzip/release.sh diff --git a/src/gzip/patches/0001-use-windows-exe-prefix.patch b/src/gzip/patches/0001-use-windows-exe-prefix.patch new file mode 100644 index 00000000..8848d57e --- /dev/null +++ b/src/gzip/patches/0001-use-windows-exe-prefix.patch @@ -0,0 +1,25 @@ +From aaa5e6e398e1e4dc527df0e95c5c07e32118cb79 Mon Sep 17 00:00:00 2001 +From: Erik Faye-Lund +Date: Thu, 29 Sep 2011 21:55:40 +0200 +Subject: [PATCH] use windows exe-suffix + +--- + Makefile.in | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/Makefile.in b/Makefile.in +index 40906a2..590bf8f 100644 +--- a/Makefile.in ++++ b/Makefile.in +@@ -81,7 +81,7 @@ G=@G@ + ZCAT=@ZCAT@ + # To install zcat executable and man page as gzcat, use: ZCAT=gzcat + +-X= ++X=.exe + # For OS/2 or MSDOS, use: X=.exe + + O=.o +-- +1.7.6.355.g842ba.dirty + diff --git a/src/gzip/release.sh b/src/gzip/release.sh new file mode 100644 index 00000000..9c79cb40 --- /dev/null +++ b/src/gzip/release.sh @@ -0,0 +1,38 @@ +#!/bin/sh + +cd "$(dirname "$0")" + +VERSION=1.2.4 +DIR=gzip-$VERSION +URL=ftp://ftp.cs.tu-berlin.de/pub/gnu/gzip/$DIR.tar.gz +FILE=${URL##*/} + +die () { + echo "$*" >&2 + exit 1 +} + +test -d $DIR || { + test -f $FILE || + curl -O $URL || + die "Could not download $FILE" + + tar xzvf $FILE && ( + cd $DIR && + git init && + git add . && + git commit -m "Import of $FILE" + ) +} || die "Could not check out $FILE" + +test $(cd $DIR && git rev-list HEAD | wc -l) -gt 1 || +(cd $DIR && git am ../patches/*) || +die "Could not apply patches" + +(cd $DIR && +INSTALL=/bin/install ./configure --prefix=/mingw && +make && +index=$(/share/msysGit/pre-install.sh) && +make install && +/share/msysGit/post-install.sh $index "Install $FILE" +) || die "Could not install $FILE" -- 2.11.4.GIT