[packages/unalz] - new URLs - added system-zlib,types patches from Fedora - release 2

qboosh qboosh at pld-linux.org
Fri Nov 15 17:29:09 CET 2019


commit 5430d5d45a0f5de5839f3adc79bda31a7cc83ee7
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Fri Nov 15 17:29:19 2019 +0100

    - new URLs
    - added system-zlib,types patches from Fedora
    - release 2

 unalz-system-zlib.patch | 28 ++++++++++++++++++++++++++++
 unalz-types.patch       | 25 +++++++++++++++++++++++++
 unalz.spec              | 14 +++++++++-----
 3 files changed, 62 insertions(+), 5 deletions(-)
---
diff --git a/unalz.spec b/unalz.spec
index 5960c89..e68b437 100644
--- a/unalz.spec
+++ b/unalz.spec
@@ -2,12 +2,14 @@ Summary:	Utility for decompressing alzip format files
 Summary(pl.UTF-8):	Narzędzie do dekompresji plików w formacie alzip
 Name:		unalz
 Version:	0.65
-Release:	1
+Release:	2
 License:	BSD
 Group:		Applications/Archiving
-Source0:	http://www.kipple.pe.kr/win/unalz/%{name}-%{version}.tgz
+Source0:	https://kippler.com/win/unalz/%{name}-%{version}.tgz
 # Source0-md5:	e4db2c4e3c8f6f5ee414b68bc55288e5
-URL:		http://www.kipple.pe.kr/win/unalz/
+Patch0:		%{name}-system-zlib.patch
+Patch1:		%{name}-types.patch
+URL:		https://kippler.com/win/unalz/
 BuildRequires:	libstdc++-devel
 BuildRequires:	zlib-devel
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -20,14 +22,16 @@ Narzędzie do dekompresji plików w formacie alzip.
 
 %prep
 %setup -q -n %{name}
+%patch0 -p1
+%patch1 -p1
 
 %build
 %{__make} linux-utf8 \
 	CC="%{__cc}" \
 	CPP="%{__cxx}" \
 	CXX="%{__cxx}" \
-	CFLAGS="%{rpmcflags} -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64" \
-	CXXFLAGS="%{rpmcxxflags} -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64"
+	CFLAGS="%{rpmcflags} %{rpmcppflags} -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64" \
+	CXXFLAGS="%{rpmcxxflags} %{rpmcppflags} -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64"
 
 %install
 rm -rf $RPM_BUILD_ROOT
diff --git a/unalz-system-zlib.patch b/unalz-system-zlib.patch
new file mode 100644
index 0000000..25f2a9f
--- /dev/null
+++ b/unalz-system-zlib.patch
@@ -0,0 +1,28 @@
+diff -rupN unalz.old/Makefile unalz/Makefile
+--- unalz.old/Makefile	2006-04-23 01:01:27.000000000 -0400
++++ unalz/Makefile	2008-12-18 14:37:25.000000000 -0500
+@@ -1,9 +1,9 @@
+ CPP = g++
+ CC  = gcc
+-OBJ = main.o UnAlz.o UnAlzUtils.o UnAlzBz2decompress.o UnAlzBzip2.o UnAlzbzlib.o zlib/adler32.o zlib/crc32.o zlib/infback.o zlib/inffast.o zlib/inflate.o zlib/inftrees.o zlib/zutil.o bzip2/blocksort.o bzip2/compress.o bzip2/crctable.o bzip2/huffman.o bzip2/randtable.o
++OBJ = main.o UnAlz.o UnAlzUtils.o UnAlzBz2decompress.o UnAlzBzip2.o UnAlzbzlib.o bzip2/blocksort.o bzip2/compress.o bzip2/crctable.o bzip2/huffman.o bzip2/randtable.o
+ BIN = unalz
+-LDFLAGS = 
+-CFLAGS = -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 
++LDFLAGS += -lz
++CFLAGS += -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 
+ 
+ all:
+ 	@echo ""
+diff -rupN unalz.old/UnAlzBzip2.cpp unalz/UnAlzBzip2.cpp
+--- unalz.old/UnAlzBzip2.cpp	2007-04-12 08:04:56.000000000 -0400
++++ unalz/UnAlzBzip2.cpp	2008-12-18 14:29:55.000000000 -0500
+@@ -10,7 +10,7 @@
+ ////////////////////////////////////////////////////////////////////////////////////////////////////
+ 
+ //#include "stdafx.h"
+-#include "zlib/zlib.h"
++#include <zlib.h>
+ #include "bzip2/bzlib.h"
+ #include "bzip2/bzlib_private.h"
+ #include "UnAlz.h"
diff --git a/unalz-types.patch b/unalz-types.patch
new file mode 100644
index 0000000..3287b23
--- /dev/null
+++ b/unalz-types.patch
@@ -0,0 +1,25 @@
+From 7bf6a9b4b265374ab756fc3fed161b75d6eaee14 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar at redhat.com>
+Date: Tue, 7 Aug 2012 09:07:41 +0200
+Subject: [PATCH] zlib get_crc_table() return type can vary
+
+---
+ UnAlz.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/UnAlz.cpp b/UnAlz.cpp
+index ab675dd..2a49cf5 100755
+--- a/UnAlz.cpp
++++ b/UnAlz.cpp
+@@ -1907,7 +1907,7 @@ void CUnAlz::DecryptingData(int nSize, BYTE* data)
+ ////////////////////////////////////////////////////////////////////////////////////////////////////
+ UINT32 CUnAlz::CRC32(UINT32 l, BYTE c)
+ {
+-	const unsigned long *CRC_TABLE = get_crc_table();
++	const z_crc_t *CRC_TABLE = get_crc_table();
+ 	return CRC_TABLE[(l ^ c) & 0xff] ^ (l >> 8);
+ }
+ 
+-- 
+1.7.11.2
+
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/unalz.git/commitdiff/5430d5d45a0f5de5839f3adc79bda31a7cc83ee7



More information about the pld-cvs-commit mailing list