[chmlib] Fixed rpath
Peter Lemenkov
peter at fedoraproject.org
Thu Aug 26 13:08:28 UTC 2010
commit 3f880708c6e4666ddf187035c60e907b74368603
Author: Peter Lemenkov <lemenkov at gmail.com>
Date: Thu Aug 26 17:08:20 2010 +0400
Fixed rpath
Signed-off-by: Peter Lemenkov <lemenkov at gmail.com>
...x-integer-types-problem-by-Goswin-von-Bre.patch | 72 ++++++++++++++++++++
...ract_chmLib-confusing-empty-files-with-di.patch | 39 +++++++++++
chmlib-chm_lib-fix_for_multiarch.diff | 46 -------------
chmlib.spec | 60 +++++++++-------
4 files changed, 145 insertions(+), 72 deletions(-)
---
diff --git a/chmlib-0001-Patch-to-fix-integer-types-problem-by-Goswin-von-Bre.patch b/chmlib-0001-Patch-to-fix-integer-types-problem-by-Goswin-von-Bre.patch
new file mode 100644
index 0000000..6efc554
--- /dev/null
+++ b/chmlib-0001-Patch-to-fix-integer-types-problem-by-Goswin-von-Bre.patch
@@ -0,0 +1,72 @@
+From 11f50f16714a584c482b6f7b469fb7edd611f869 Mon Sep 17 00:00:00 2001
+From: Jed Wing <jed.wing at gmail.com>
+Date: Wed, 27 May 2009 18:25:42 -0700
+Subject: [PATCH 1/4] Patch to fix integer types problem by Goswin von Brederlow.
+
+This came from Goswin von Brederlow <brederlo at informatik.uni-tuebingen.de> via
+Kartik Mistry, the maintainer of the Debian package of chmlib.
+---
+ src/chm_lib.c | 30 +++++++++++++-----------------
+ 1 files changed, 13 insertions(+), 17 deletions(-)
+
+diff --git a/src/chm_lib.c b/src/chm_lib.c
+index 6c6736c..ffd213c 100644
+--- a/src/chm_lib.c
++++ b/src/chm_lib.c
+@@ -56,6 +56,7 @@
+
+ #include "lzx.h"
+
++#include <stdint.h>
+ #include <stdlib.h>
+ #include <string.h>
+ #ifdef CHM_DEBUG
+@@ -149,22 +150,9 @@ typedef unsigned __int32 UInt32;
+ typedef __int64 Int64;
+ typedef unsigned __int64 UInt64;
+
+-/* I386, 32-bit, non-Windows */
+-/* Sparc */
+-/* MIPS */
+-/* PPC */
+-#elif __i386__ || __sun || __sgi || __ppc__
+-typedef unsigned char UChar;
+-typedef short Int16;
+-typedef unsigned short UInt16;
+-typedef long Int32;
+-typedef unsigned long UInt32;
+-typedef long long Int64;
+-typedef unsigned long long UInt64;
+-
+ /* x86-64 */
+ /* Note that these may be appropriate for other 64-bit machines. */
+-#elif __x86_64__ || __ia64__
++#elif defined(__LP64__)
+ typedef unsigned char UChar;
+ typedef short Int16;
+ typedef unsigned short UInt16;
+@@ -173,10 +161,18 @@ typedef unsigned int UInt32;
+ typedef long Int64;
+ typedef unsigned long UInt64;
+
++/* I386, 32-bit, non-Windows */
++/* Sparc */
++/* MIPS */
++/* PPC */
+ #else
+-
+-/* yielding an error is preferable to yielding incorrect behavior */
+-#error "Please define the sized types for your platform in chm_lib.c"
++typedef unsigned char UChar;
++typedef short Int16;
++typedef unsigned short UInt16;
++typedef long Int32;
++typedef unsigned long UInt32;
++typedef long long Int64;
++typedef unsigned long long UInt64;
+ #endif
+
+ /* GCC */
+--
+1.7.2.1
+
diff --git a/chmlib-0003-Fix-for-extract_chmLib-confusing-empty-files-with-di.patch b/chmlib-0003-Fix-for-extract_chmLib-confusing-empty-files-with-di.patch
new file mode 100644
index 0000000..3bc4466
--- /dev/null
+++ b/chmlib-0003-Fix-for-extract_chmLib-confusing-empty-files-with-di.patch
@@ -0,0 +1,39 @@
+From 9b479b4f3bbb08e8ab340d6ad626f3549b51d929 Mon Sep 17 00:00:00 2001
+From: Jed Wing <jed.wing at gmail.com>
+Date: Wed, 27 May 2009 18:41:10 -0700
+Subject: [PATCH 3/4] Fix for extract_chmLib confusing empty files with directories.
+
+Patch from Paul Wise <pabs at debian.org> via Kartik Mistry, the maintainer of the
+Debian chmlib package.
+---
+ src/extract_chmLib.c | 7 ++++++-
+ 1 files changed, 6 insertions(+), 1 deletions(-)
+
+diff --git a/src/extract_chmLib.c b/src/extract_chmLib.c
+index 078cc35..478c892 100644
+--- a/src/extract_chmLib.c
++++ b/src/extract_chmLib.c
+@@ -102,6 +102,7 @@ int _extract_callback(struct chmFile *h,
+ struct chmUnitInfo *ui,
+ void *context)
+ {
++ LONGUINT64 ui_path_len;
+ char buffer[32768];
+ struct extract_context *ctx = (struct extract_context *)context;
+ char *i;
+@@ -119,7 +120,11 @@ int _extract_callback(struct chmFile *h,
+ if (snprintf(buffer, sizeof(buffer), "%s%s", ctx->base_path, ui->path) > 1024)
+ return CHM_ENUMERATOR_FAILURE;
+
+- if (ui->length != 0)
++ /* Get the length of the path */
++ ui_path_len = strlen(ui->path)-1;
++
++ /* Distinguish between files and dirs */
++ if (ui->path[ui_path_len] != '/' )
+ {
+ FILE *fout;
+ LONGINT64 len, remain=ui->length;
+--
+1.7.2.1
+
diff --git a/chmlib.spec b/chmlib.spec
index 7baa1f7..42b17ec 100644
--- a/chmlib.spec
+++ b/chmlib.spec
@@ -1,12 +1,13 @@
Name: chmlib
Summary: Library for dealing with ITSS/CHM format files
Version: 0.40
-Release: 2%{?dist}
+Release: 3%{?dist}
License: LGPLv2+
Group: Development/Libraries
Url: http://www.jedrea.com/chmlib/
-Source: http://www.jedrea.com/chmlib/%{name}-%{version}.tar.bz2
-Patch0: chmlib-chm_lib-fix_for_multiarch.diff
+Source0: http://www.jedrea.com/chmlib/%{name}-%{version}.tar.bz2
+Patch1: chmlib-0001-Patch-to-fix-integer-types-problem-by-Goswin-von-Bre.patch
+Patch3: chmlib-0003-Fix-for-extract_chmLib-confusing-empty-files-with-di.patch
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%description
@@ -26,23 +27,26 @@ Files needed for developing apps using chmlib.
%prep
%setup -q
-%patch0 -p0
+%patch1 -p1 -b .types
+%patch3 -p1 -b .files_dirs
%build
%configure --enable-examples --disable-static
-%{__make} %{?_smp_mflags}
+sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
+sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
+make %{?_smp_mflags}
%install
-%{__rm} -rf %{buildroot}
-%{__make} DESTDIR=%{buildroot} install
-%{__rm} -f %{buildroot}/%{_libdir}/*.la
+rm -rf %{buildroot}
+make DESTDIR=%{buildroot} install
+rm -f %{buildroot}/%{_libdir}/*.la
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%clean
-%{__rm} -rf %{buildroot}
+rm -rf %{buildroot}
%files
%defattr(-,root,root,-)
@@ -60,57 +64,61 @@ Files needed for developing apps using chmlib.
%{_libdir}/libchm.so
%changelog
+* Thu Aug 26 2010 Peter Lemenkov <lemenkov at gmail.com> - 0.40-3
+- Removed rpath (see rhbz #569128)
+- Patches rebased
+
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.40-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
-* Thu May 28 2009 Peter Lemenkov <lemenkov at gmail.com> 0.40-1
+* Thu May 28 2009 Peter Lemenkov <lemenkov at gmail.com> - 0.40-1
- Ver. 0.40
* Mon Feb 23 2009 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.39-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
-* Sat Mar 29 2008 Peter Lemenkov <lemenkov at gmail.com> 0.39-7
+* Sat Mar 29 2008 Peter Lemenkov <lemenkov at gmail.com> - 0.39-7
- Enable utilities (close BZ#437151)
-* Sat Feb 9 2008 Peter Lemenkov <lemenkov at gmail.com> 0.39-6
+* Sat Feb 9 2008 Peter Lemenkov <lemenkov at gmail.com> - 0.39-6
- Rebuild for GCC 4.3
-* Sun Sep 30 2007 Peter Lemenkov <lemenkov at gmail.com> 0.39-5
+* Sun Sep 30 2007 Peter Lemenkov <lemenkov at gmail.com> - 0.39-5
- Changel license tag from LGPL to LGPLv2+
-* Sun Aug 5 2007 Peter Lemenkov <lemenkov at gmail.com> 0.39-4
+* Sun Aug 5 2007 Peter Lemenkov <lemenkov at gmail.com> - 0.39-4
- Better fix for multi-arch issues
-* Sat Aug 4 2007 Peter Lemenkov <lemenkov at gmail.com> 0.39-3
+* Sat Aug 4 2007 Peter Lemenkov <lemenkov at gmail.com> - 0.39-3
- Upstream URL changed
-* Thu Aug 02 2007 Oliver Falk <oliver at linux-kernel.at> 0.39-2
+* Thu Aug 02 2007 Oliver Falk <oliver at linux-kernel.at> - 0.39-2
- Add alpha fix
-* Thu Feb 1 2007 Peter Lemenkov <lemenkov at gmail.com> 0.39-1
+* Thu Feb 1 2007 Peter Lemenkov <lemenkov at gmail.com> - 0.39-1
- Ver. 0.39
-* Tue Sep 12 2006 Peter Lemenkov <lemenkov at gmail.com> 0.38-2%{?dist}
+* Tue Sep 12 2006 Peter Lemenkov <lemenkov at gmail.com> - 0.38-2
- rebuild for FC6
-* Wed Jun 28 2006 Peter Lemenkov <lemenkov at newmail.ru> 0.38-1%{?dist}
+* Wed Jun 28 2006 Peter Lemenkov <lemenkov at newmail.ru> - 0.38-1
- Version 0.38
-* Thu Mar 30 2006 Peter Lemenkov <lemenkov at newmail.ru> 0.37.4-6%{?dist}
+* Thu Mar 30 2006 Peter Lemenkov <lemenkov at newmail.ru> - 0.37.4-6
- rebuild
-* Mon Mar 27 2006 Peter Lemenkov <lemenkov at newmail.ru> 0.37.4-5%{?dist}
+* Mon Mar 27 2006 Peter Lemenkov <lemenkov at newmail.ru> - 0.37.4-5
- rebuild
-* Tue Jan 10 2006 Peter Lemenkov <lemenkov at newmail.ru> 0.37.4-4%{?dist}
-- Next try to fix powerpc-arch
+* Tue Jan 10 2006 Peter Lemenkov <lemenkov at newmail.ru> - 0.37.4-4
+- Next try to fix powerpc-arch
-* Mon Jan 09 2006 Peter Lemenkov <lemenkov at newmail.ru> 0.37.4-3%{?dist}
+* Mon Jan 09 2006 Peter Lemenkov <lemenkov at newmail.ru> - 0.37.4-3
- Typo fix
-* Mon Jan 09 2006 Peter Lemenkov <lemenkov at newmail.ru> 0.37.4-2%{?dist}
+* Mon Jan 09 2006 Peter Lemenkov <lemenkov at newmail.ru> - 0.37.4-2
- Fix for PPC-arch
-* Sat Nov 12 2005 Peter Lemenkov <lemenkov at newmail.ru> 0.37.4-1
+* Sat Nov 12 2005 Peter Lemenkov <lemenkov at newmail.ru> - 0.37.4-1
- Initial build for FC-Extras
More information about the scm-commits
mailing list