[gecko-sharp2] - Remove libdir patches with some sed magic - Renumber patch2 to patch0

Paul F. Johnson pfj at fedoraproject.org
Sat Oct 23 20:26:47 UTC 2010


commit a741fc3100c8debca12afa389db434ece5b5e6a7
Author: Paul F. Johnson <paul at all-the-johnsons.co.uk>
Date:   Sat Oct 23 21:26:45 2010 +0100

    - Remove libdir patches with some sed magic
    - Renumber patch2 to patch0

 gecko-sharp2.spec |   26 +++++++++++++++++---------
 1 files changed, 17 insertions(+), 9 deletions(-)
---
diff --git a/gecko-sharp2.spec b/gecko-sharp2.spec
index acfb7fb..4e98ec1 100644
--- a/gecko-sharp2.spec
+++ b/gecko-sharp2.spec
@@ -1,6 +1,6 @@
 Name:           gecko-sharp2
 Version:        0.13
-Release:        16%{?dist}
+Release:        16.1%{?dist}
 Summary:        Gecko bindings for Mono
 
 Group:          System Environment/Libraries
@@ -9,9 +9,7 @@ URL:            http://www.mono-project.com/
 Source0:        http://ftp.novell.com/pub/mono/sources/gecko-sharp2/gecko-sharp-2.0-%{version}.tar.bz2
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
-Patch1: 	gecko-sharp-libdir.patch
-Patch2: 	gecko-sharp-2.0-0.12-xulrunner.patch
-Patch3:		geckosharp2-doc.patch
+Patch0: 	gecko-sharp-2.0-0.12-xulrunner.patch
 
 BuildRequires:  gtk-sharp2-devel
 BuildRequires:  gtk2-devel
@@ -43,11 +41,17 @@ for writing gecko-sharp2 applications.
 
 %prep
 %setup -n gecko-sharp-2.0-%{version}
-sed -i -e 's!@LIBDIR@!%{_libdir}!' %{PATCH3}
-%patch3 -p1 -b .docdir
-sed -i -e 's!%{_libdir}!@LIBDIR@!' %{PATCH3}
-%patch1 -p1 -b .libdir
-%patch2 -p1 -b .xl
+%patch0 -p1 -b .xl
+
+find . -name Makefile.in -or -name \*.pc.in \
+       -or -name Makefile.am \
+       | while read f ;
+         do
+           sed -i -e 's!$(prefix)/lib/!%{_libdir}/!' \
+               -e 's!${prefix}/lib/!%{_libdir}/!' \
+               -e 's!${exec_prefix}/lib!%{_libdir}!' \
+               -e 's!${exec_prefix}/lib/!%{_libdir}/!' "$f" 1>/dev/null
+         done
 
 %build
 autoreconf --force --install
@@ -75,6 +79,10 @@ rm -rf $RPM_BUILD_ROOT
 %{_libdir}/pkgconfig/*-sharp-2.0.pc
 
 %changelog
+* Sat Oct 23 2010 Paul F. Johnson <paul at all-the-johnsons.co.uk> 0.13-16.1
+- Remove libdir patches with some sed magic
+- Renumber patch2 to patch0
+
 * Sat Oct 23 2010 Paul F. Johnson <paul at all-the-johnsons.co.uk> 0.13-16
 - Add monodoc patch
 


More information about the scm-commits mailing list