summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorxantares2015-06-08 22:35:17 +0200
committerxantares2015-06-08 22:35:17 +0200
commitaf4d36a44cc5f8dd0a33b3e359118b8345304a6d (patch)
tree1a8f6030cf47d712b2671ea386738fc9e4218cd7
downloadaur-af4d36a44cc5f8dd0a33b3e359118b8345304a6d.tar.gz
Initial import
-rw-r--r--.SRCINFO23
-rw-r--r--PKGBUILD51
-rw-r--r--bzip2-1.0.5-autoconfiscated.patch286
-rw-r--r--bzip2-use-cdecl-calling-convention.patch64
-rw-r--r--mingw32-bzip2-1.0.5-slash.patch11
5 files changed, 435 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..60353f2a270
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,23 @@
+pkgbase = mingw-w64-bzip2
+ pkgdesc = A high-quality data compression program (mingw-w64)
+ pkgver = 1.0.6
+ pkgrel = 8
+ url = http://sources.redhat.com/bzip2
+ arch = any
+ license = custom
+ makedepends = mingw-w64-configure
+ depends = mingw-w64-crt
+ options = !strip
+ options = !buildflags
+ options = staticlibs
+ source = http://www.bzip.org/1.0.6/bzip2-1.0.6.tar.gz
+ source = bzip2-1.0.5-autoconfiscated.patch
+ source = bzip2-use-cdecl-calling-convention.patch
+ source = mingw32-bzip2-1.0.5-slash.patch
+ sha1sums = 3f89f861209ce81a6bab1fd1998c0ef311712002
+ sha1sums = 4d512b19b802d328037bf957c18866471c092e84
+ sha1sums = f73d45bb02741cf0cfa995ac46547b34aedf5343
+ sha1sums = 809c3a95f6f6c26463d804b345d62eed8420c6a6
+
+pkgname = mingw-w64-bzip2
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..6152dbd8ac4
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,51 @@
+pkgname=mingw-w64-bzip2
+pkgver=1.0.6
+pkgrel=8
+pkgdesc="A high-quality data compression program (mingw-w64)"
+arch=(any)
+url="http://sources.redhat.com/bzip2"
+license=("custom")
+makedepends=(mingw-w64-configure)
+depends=(mingw-w64-crt)
+options=(!strip !buildflags staticlibs)
+source=("http://www.bzip.org/${pkgver}/bzip2-${pkgver}.tar.gz"
+ "bzip2-1.0.5-autoconfiscated.patch"
+ "bzip2-use-cdecl-calling-convention.patch"
+ "mingw32-bzip2-1.0.5-slash.patch")
+sha1sums=('3f89f861209ce81a6bab1fd1998c0ef311712002'
+ '4d512b19b802d328037bf957c18866471c092e84'
+ 'f73d45bb02741cf0cfa995ac46547b34aedf5343'
+ '809c3a95f6f6c26463d804b345d62eed8420c6a6')
+
+_architectures="i686-w64-mingw32 x86_64-w64-mingw32"
+
+prepare() {
+ cd "$srcdir/bzip2-$pkgver"
+ rm -f autogen.sh README.autotools configure.ac Makefile.am bzip2.pc.in
+ patch -p1 -i "$srcdir/"bzip2-1.0.5-autoconfiscated.patch
+ patch bzlib.h < "$srcdir/"bzip2-use-cdecl-calling-convention.patch
+ patch bzip2.c < "$srcdir/"mingw32-bzip2-1.0.5-slash.patch
+ sh autogen.sh
+}
+
+build() {
+ cd "$srcdir/bzip2-$pkgver"
+ for _arch in ${_architectures}; do
+ mkdir -p build-${_arch} && pushd build-${_arch}
+ ${_arch}-configure
+ make
+ popd
+ done
+}
+
+package() {
+ for _arch in ${_architectures}; do
+ cd "${srcdir}/bzip2-${pkgver}/build-${_arch}"
+ make DESTDIR="$pkgdir" install
+ rm -r "$pkgdir/usr/${_arch}/share"
+ rm "$pkgdir/usr/${_arch}/bin/bz"{diff,grep,more}
+ rm "$pkgdir"/usr/${_arch}/bin/*.exe
+ ${_arch}-strip --strip-unneeded "$pkgdir"/usr/${_arch}/bin/*.dll
+ ${_arch}-strip -g "$pkgdir"/usr/${_arch}/lib/*.a
+ done
+}
diff --git a/bzip2-1.0.5-autoconfiscated.patch b/bzip2-1.0.5-autoconfiscated.patch
new file mode 100644
index 00000000000..9d52ed05a7f
--- /dev/null
+++ b/bzip2-1.0.5-autoconfiscated.patch
@@ -0,0 +1,286 @@
+diff -urN files/autogen.sh ./autogen.sh
+--- bzip2-1.0.5.orig/autogen.sh 1970-01-01 01:00:00.000000000 +0100
++++ bzip2-1.0.5.autoconfiscated/autogen.sh 2009-11-06 12:10:43.574602171 +0100
+@@ -0,0 +1,8 @@
++mv LICENSE COPYING
++mv CHANGES NEWS
++touch AUTHORS
++touch ChangeLog
++libtoolize --force
++aclocal
++automake --add-missing --gnu
++autoconf
+diff -urN bzip2-1.0.5.orig/README.autotools bzip2-1.0.5.autoconfiscated/README.autotools
+--- bzip2-1.0.5.orig/README.autotools 1970-01-01 01:00:00.000000000 +0100
++++ bzip2-1.0.5.autoconfiscated/README.autotools 2010-11-02 17:04:06.000000000 +0100
+@@ -0,0 +1,39 @@
++bzip2 autoconfiscated
++=====================
++
++Temporarily at http://ftp.suse.com/pub/people/sbrabec/bzip2/ expecting
++that it will become a new upstream version to prevent per-distribution
++shared library patching done by nearly each Linux vendor separately.
++
++Autoconfiscation brings standard ./configure ; make ; make install
++installation, seamless support of DESTDIR, automatic check for supported
++CFLAGS, standard shared library support, automatic large files CFLAGS
++check and all things that are supported by automake.
++
++It makes obsolete Makefile-libbz2_so and README.COMPILATION.PROBLEMS.
++Now configure should automatically detect correct build flags.
++
++In case of any problem or question with autotools support feel free to
++contact me: Stanislav Brabec <sbrabec@suse.cz>
++
++Autoconfiscated version binaries are exactly equal to
++bzip2-1.0.5.tar.gz. There are only few changes. See below.
++
++
++New features:
++
++Trivial link man pages for bzcat and bunzip2 added.
++
++bzip2.pc file for pkg-config. Packages can use it for checks.
++
++
++Incompatible changes:
++
++soname change. Libtool has no support for two parts name suffix (e. g.
++libbz2.so.1.0). It must be a single number (e. g. libbz2.so.1). That is
++why soname must change. But I see not a big problem with it. Several
++distributions already use the new number instead of the non-standard
++number from Makefile-libbz2_so.
++
++To be super-safe, I incremented minor number of the library file, so
++both instances of the shared library can live together.
+diff -urN bzip2-1.0.5.orig/configure.ac bzip2-1.0.5.autoconfiscated/configure.ac
+--- bzip2-1.0.5.orig/configure.ac 1970-01-01 01:00:00.000000000 +0100
++++ bzip2-1.0.5.autoconfiscated/configure.ac 2009-11-06 17:04:04.000000000 +0100
+@@ -0,0 +1,70 @@
++# -*- Autoconf -*-
++# Process this file with autoconf to produce a configure script.
++
++AC_PREREQ([2.57])
++AC_INIT([bzip2], [1.0.6], [Julian Seward <jseward@bzip.org>])
++BZIP2_LT_CURRENT=1
++BZIP2_LT_REVISION=5
++BZIP2_LT_AGE=0
++AC_CONFIG_SRCDIR([bzlib.h])
++AC_CONFIG_MACRO_DIR([m4])
++
++AM_INIT_AUTOMAKE
++AM_MAINTAINER_MODE
++
++# Checks for programs.
++AC_PROG_AWK
++AC_PROG_CC
++AC_PROG_INSTALL
++AC_PROG_LN_S
++AC_PROG_MAKE_SET
++AC_PROG_LIBTOOL
++PKG_PROG_PKG_CONFIG
++
++# Checks for libraries.
++
++# Checks for header files.
++
++# Checks for typedefs, structures, and compiler characteristics.
++
++# Check for system features.
++AC_SYS_LARGEFILE
++
++AC_MSG_CHECKING([whether compiler understands -Wall])
++save_CFLAGS="$CFLAGS"
++CFLAGS="$CFLAGS -Wall"
++AC_TRY_COMPILE([], [], [
++ AC_MSG_RESULT([yes])
++], [
++ AC_MSG_RESULT([no])
++ CFLAGS="$save_CFLAGS"
++])
++
++AC_MSG_CHECKING([whether compiler understands -Winline])
++save_CFLAGS="$CFLAGS"
++CFLAGS="$CFLAGS -Winline"
++AC_TRY_COMPILE([], [], [
++ AC_MSG_RESULT([yes])
++], [
++ AC_MSG_RESULT([no])
++ CFLAGS="$save_CFLAGS"
++])
++
++AC_MSG_CHECKING([whether compiler understands -fno-strength-reduce])
++save_CFLAGS="$CFLAGS"
++CFLAGS="$CFLAGS -fno-strength-reduce"
++AC_TRY_COMPILE([], [], [
++ AC_MSG_RESULT([yes])
++], [
++ AC_MSG_RESULT([no])
++ CFLAGS="$save_CFLAGS"
++])
++
++# Checks for library functions.
++
++# Write the output.
++AC_SUBST([BZIP2_LT_CURRENT])
++AC_SUBST([BZIP2_LT_REVISION])
++AC_SUBST([BZIP2_LT_AGE])
++AC_CONFIG_FILES([Makefile bzip2.pc])
++AC_OUTPUT
+diff -urN bzip2-1.0.5.orig/Makefile.am bzip2-1.0.5.autoconfiscated/Makefile.am
+--- bzip2-1.0.5.orig/Makefile.am 1970-01-01 01:00:00.000000000 +0100
++++ bzip2-1.0.5.autoconfiscated/Makefile.am 2009-11-05 16:45:11.000000000 +0100
+@@ -0,0 +1,138 @@
++lib_LTLIBRARIES = libbz2.la
++
++libbz2_la_SOURCES = \
++ blocksort.c \
++ huffman.c \
++ crctable.c \
++ randtable.c \
++ compress.c \
++ decompress.c \
++ bzlib.c
++
++libbz2_la_LDFLAGS = \
++ -version-info $(BZIP2_LT_CURRENT):$(BZIP2_LT_REVISION):$(BZIP2_LT_AGE) \
++ -no-undefined
++
++include_HEADERS = bzlib.h
++
++noinst_HEADERS = bzlib_private.h
++
++bin_PROGRAMS = bzip2 bzip2recover
++
++bzip2_SOURCES = bzip2.c
++bzip2_LDADD = libbz2.la
++
++bzip2recover_SOURCES = bzip2recover.c
++bzip2recover_LDADD = libbz2.la
++
++bin_SCRIPTS = bzgrep bzmore bzdiff
++
++man_MANS = bzip2.1 bzgrep.1 bzmore.1 bzdiff.1
++
++pkgconfigdir = $(libdir)/pkgconfig
++pkgconfig_DATA = bzip2.pc
++
++$(pkgconfig_DATA): $(srcdir)/bzip2.pc.in config.status
++
++install-exec-hook:
++ rm -f $(DESTDIR)$(bindir)/`echo "bunzip2" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ rm -f $(DESTDIR)$(bindir)/`echo "bzcat" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ rm -f $(DESTDIR)$(bindir)/`echo "bzegrep" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ rm -f $(DESTDIR)$(bindir)/`echo "bzfgrep" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ rm -f $(DESTDIR)$(bindir)/`echo "bzless" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ rm -f $(DESTDIR)$(bindir)/`echo "bzcmp" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ $(LN_S) `echo "bzip2" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'` $(DESTDIR)$(bindir)/`echo "bunzip2" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ $(LN_S) `echo "bzip2" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'` $(DESTDIR)$(bindir)/`echo "bzcat" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ $(LN_S) `echo "bzgrep" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'` $(DESTDIR)$(bindir)/`echo "bzegrep" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ $(LN_S) `echo "bzgrep" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'` $(DESTDIR)$(bindir)/`echo "bzfgrep" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ $(LN_S) `echo "bzmore" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'` $(DESTDIR)$(bindir)/`echo "bzless" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ $(LN_S) `echo "bzdiff" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'` $(DESTDIR)$(bindir)/`echo "bzcmp" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++
++install-data-hook:
++ echo ".so man1/`echo "bzip2" | sed 's,^.*/,,;$(transform)'`.1" >$(DESTDIR)$(mandir)/man1/`echo "bunzip2" | sed 's,^.*/,,;$(transform)'`.1
++ echo ".so man1/`echo "bzip2" | sed 's,^.*/,,;$(transform)'`.1" >$(DESTDIR)$(mandir)/man1/`echo "bzcat" | sed 's,^.*/,,;$(transform)'`.1
++ echo ".so man1/`echo "bzgrep" | sed 's,^.*/,,;$(transform)'`.1" >$(DESTDIR)$(mandir)/man1/`echo "bzegrep" | sed 's,^.*/,,;$(transform)'`.1
++ echo ".so man1/`echo "bzgrep" | sed 's,^.*/,,;$(transform)'`.1" >$(DESTDIR)$(mandir)/man1/`echo "bzfgrep" | sed 's,^.*/,,;$(transform)'`.1
++ echo ".so man1/`echo "bzmore" | sed 's,^.*/,,;$(transform)'`.1" >$(DESTDIR)$(mandir)/man1/`echo "bzless" | sed 's,^.*/,,;$(transform)'`.1
++ echo ".so man1/`echo "bzdiff" | sed 's,^.*/,,;$(transform)'`.1" >$(DESTDIR)$(mandir)/man1/`echo "bzcmp" | sed 's,^.*/,,;$(transform)'`.1
++
++uninstall-hook:
++ rm -f $(DESTDIR)$(bindir)/`echo "bunzip2" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ rm -f $(DESTDIR)$(bindir)/`echo "bzcat" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ rm -f $(DESTDIR)$(bindir)/`echo "bzegrep" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ rm -f $(DESTDIR)$(bindir)/`echo "bzfgrep" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ rm -f $(DESTDIR)$(bindir)/`echo "bzless" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ rm -f $(DESTDIR)$(bindir)/`echo "bzcmp" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`
++ rm -f $(DESTDIR)$(mandir)/man1/`echo "bunzip2" | sed 's,^.*/,,;$(transform)'`.1
++ rm -f $(DESTDIR)$(mandir)/man1/`echo "bzcat" | sed 's,^.*/,,;$(transform)'`.1
++ rm -f $(DESTDIR)$(mandir)/man1/`echo "bzegrep" | sed 's,^.*/,,;$(transform)'`.1
++ rm -f $(DESTDIR)$(mandir)/man1/`echo "bzfgrep" | sed 's,^.*/,,;$(transform)'`.1
++ rm -f $(DESTDIR)$(mandir)/man1/`echo "bzless" | sed 's,^.*/,,;$(transform)'`.1
++ rm -f $(DESTDIR)$(mandir)/man1/`echo "bzcmp" | sed 's,^.*/,,;$(transform)'`.1
++
++test: bzip2
++ @cat $(srcdir)/words1
++ ./bzip2 -1 <$(srcdir)/sample1.ref >sample1.rb2
++ ./bzip2 -2 <$(srcdir)/sample2.ref >sample2.rb2
++ ./bzip2 -3 <$(srcdir)/sample3.ref >sample3.rb2
++ ./bzip2 -d <$(srcdir)/sample1.bz2 >sample1.tst
++ ./bzip2 -d <$(srcdir)/sample2.bz2 >sample2.tst
++ ./bzip2 -ds <$(srcdir)/sample3.bz2 >sample3.tst
++ cmp $(srcdir)/sample1.bz2 sample1.rb2
++ cmp $(srcdir)/sample2.bz2 sample2.rb2
++ cmp $(srcdir)/sample3.bz2 sample3.rb2
++ cmp sample1.tst $(srcdir)/sample1.ref
++ cmp sample2.tst $(srcdir)/sample2.ref
++ cmp sample3.tst $(srcdir)/sample3.ref
++ @cat $(srcdir)/words3
++
++manual: $(srcdir)/manual.html $(srcdir)/manual.ps $(srcdir)/manual.pdf
++
++manual.ps: $(MANUAL_SRCS)
++ cd $(srcdir); ./xmlproc.sh -ps manual.xml
++
++manual.pdf: $(MANUAL_SRCS)
++ cd $(srcdir); ./xmlproc.sh -pdf manual.xml
++
++manual.html: $(MANUAL_SRCS)
++ cd $(srcdir); ./xmlproc.sh -html manual.xml
++
++EXTRA_DIST = \
++ $(bin_SCRIPTS) \
++ $(man_MANS) \
++ README.autotools \
++ README.XML.STUFF \
++ bz-common.xsl \
++ bz-fo.xsl \
++ bz-html.xsl \
++ bzip.css \
++ bzip2.1.preformatted \
++ bzip2.pc.in \
++ bzip2.txt \
++ dlltest.c \
++ dlltest.dsp \
++ entities.xml \
++ format.pl \
++ libbz2.def \
++ libbz2.dsp \
++ makefile.msc \
++ manual.html \
++ manual.pdf \
++ manual.ps \
++ manual.xml \
++ mk251.c \
++ sample1.bz2 \
++ sample1.ref \
++ sample2.bz2 \
++ sample2.ref \
++ sample3.bz2 \
++ sample3.ref \
++ spewG.c \
++ unzcrash.c \
++ words0 \
++ words1 \
++ words2 \
++ words3 \
++ xmlproc.sh
++
++ACLOCAL_AMFLAGS = -I m4
+diff -urN bzip2-1.0.5.orig/bzip2.pc.in bzip2-1.0.5.autoconfiscated/bzip2.pc.in
+--- bzip2-1.0.5.orig/bzip2.pc.in 1970-01-01 01:00:00.000000000 +0100
++++ bzip2-1.0.5.autoconfiscated/bzip2.pc.in 2009-11-03 18:48:28.000000000 +0100
+@@ -0,0 +1,11 @@
++prefix=@prefix@
++exec_prefix=@exec_prefix@
++bindir=@bindir@
++libdir=@libdir@
++includedir=@includedir@
++
++Name: bzip2
++Description: Lossless, block-sorting data compression
++Version: @VERSION@
++Libs: -L${libdir} -lbz2
++Cflags: -I${includedir}
diff --git a/bzip2-use-cdecl-calling-convention.patch b/bzip2-use-cdecl-calling-convention.patch
new file mode 100644
index 00000000000..c9b7f283881
--- /dev/null
+++ b/bzip2-use-cdecl-calling-convention.patch
@@ -0,0 +1,64 @@
+--- bzip2-1.0.5/bzlib.h 2007-12-09 13:34:39.000000000 +0100
++++ src/bzip2/1.0.5/bzip2-1.0.5/bzlib.h 2008-03-20 20:05:47.000000000 +0100
+@@ -81,18 +81,52 @@
+ /* windows.h define small to char */
+ # undef small
+ # endif
+-# ifdef BZ_EXPORT
+-# define BZ_API(func) WINAPI func
+-# define BZ_EXTERN extern
++//# ifdef BZ_EXPORT
++//# define BZ_API(func) WINAPI func
++//# define BZ_EXTERN extern
++//# else
++// /* import windows dll dynamically */
++//# define BZ_API(func) (WINAPI * func)
++//# define BZ_EXTERN
++//# endif
++//#else
++//# define BZ_API(func) func
++//# define BZ_EXTERN extern
++# include <stdio.h>
++# include <io.h>
++# include <sys/utime.h>
++# define fdopen _fdopen
++# define isatty _isatty
++# define setmode _setmode
++# define utime _utime
++# endif
++
++#ifndef __GNUC__
++# define __DLL_IMPORT__ __declspec(dllimport)
++# define __DLL_EXPORT__ __declspec(dllexport)
+ # else
+- /* import windows dll dynamically */
+-# define BZ_API(func) (WINAPI * func)
+-# define BZ_EXTERN
++# define __DLL_IMPORT__ __attribute__((dllimport)) extern
++# define __DLL_EXPORT__ __attribute__((dllexport)) extern
+ # endif
+-#else
+-# define BZ_API(func) func
+-# define BZ_EXTERN extern
++
++#if (defined __WIN32__) || (defined _WIN32)
++# if defined BUILD_BZIP2_DLL || defined BZ_EXPORT
++# define BZIP2_DLL_IMPEXP __DLL_EXPORT__
++# elif defined(BZIP2_STATIC)
++# define BZIP2_DLL_IMPEXP
++# elif defined (USE_BZIP2_DLL) || defined BZ_IMPORT
++# define BZIP2_DLL_IMPEXP __DLL_IMPORT__
++# elif defined (USE_BZIP2_STATIC)
++# define BZIP2_DLL_IMPEXP
++# else /* assume USE_BZIP2_DLL */
++# define BZIP2_DLL_IMPEXP __DLL_IMPORT__
+ #endif
++#else /* __WIN32__ */
++# define BZIP2_DLL_IMPEXP
++#endif
++
++#define BZ_API(func) func
++#define BZ_EXTERN BZIP2_DLL_IMPEXP
+
+
+ /*-- Core (low-level) library functions --*/
diff --git a/mingw32-bzip2-1.0.5-slash.patch b/mingw32-bzip2-1.0.5-slash.patch
new file mode 100644
index 00000000000..3b5ed14e172
--- /dev/null
+++ b/mingw32-bzip2-1.0.5-slash.patch
@@ -0,0 +1,11 @@
+--- bzip2-1.0.5.orig/bzip2.c 2007-12-09 12:22:06.000000000 +0000
++++ bzip2-1.0.5/bzip2.c 2008-09-25 12:31:02.000000000 +0100
+@@ -128,7 +128,7 @@
+ #if BZ_LCCWIN32
+ # include <io.h>
+ # include <fcntl.h>
+-# include <sys\stat.h>
++# include <sys/stat.h>
+
+ # define NORETURN /**/
+ # define PATH_SEP '\\'