Re: Cross Distro Spec Files



> collaborate with James on a cross-distro spec file for some of the
> basic stuff in jhbuild- maybe gucharmap and the core dependencies?

Here's a patch against gucharmap HEAD to add this facility
-- 
James Ogley james usr-local-bin org
GNOME for SuSE: http://usr-local-bin.org/rpms
diff -ruN gucharmap.orig/gucharmap.spec.in gucharmap/gucharmap.spec.in
--- gucharmap.orig/gucharmap.spec.in	2003-05-04 00:15:38.000000000 +0100
+++ gucharmap/gucharmap.spec.in	2005-06-15 06:58:16.000000000 +0100
@@ -1,5 +1,23 @@
 # DarContact: Noah Levitt <nlevitt аt columbia.edu>
 
+%{?_with_suse:%define suse 1}
+%{!?_with_suse:%define suse 0}
+%if %{suse}
+%define prefix      /opt/gnome
+%define sysconfdir  /etc%{prefix}
+%define bindir      %{prefix}/bin
+%define datadir     %{prefix}/share
+%define libdir      %{prefix}/lib
+%define includedir  %{prefix}/include
+%else
+%define prefix      %{_prefix}
+%define sysconfdir  %{_sysconfdir}
+%define bindir      %{_bindir}
+%define datadir     %{_datadir}
+%define libdir      %{_libdir}
+%define includedir  %{_includedir}
+%endif
+
 Summary: A featureful Unicode character map. 
 Name: gucharmap
 Version: @VERSION@
@@ -13,7 +31,7 @@
 
 Source: http://ftp.gnome.org/pub/gnome/sources/gucharmap/0.6/%{name}-%{version}.tar.bz2
 BuildRoot: %{_tmppath}/root-%{name}-%{version}
-Prefix: %{_prefix}
+Prefix: %{prefix}
 
 %description
 gucharmap is a featureful Unicode character map and font viewer.
@@ -31,7 +49,7 @@
 %setup
 
 %build
-%configure
+./configure --prefix=%prefix --sysconfdir=%sysconfdir
 %{__make} %{?_smp_mflags}
 
 %install
@@ -54,21 +72,24 @@
 %defattr(-, root, root, 0755)
 %doc ChangeLog COPYING* README TODO
 %config %{_sysconfdir}/gucharmap/
-%{_bindir}/*
-%{_libdir}/*.so.*
-%{_libdir}/gucharmap/immodules/im-gucharmap.so
-%{_datadir}/pixmaps/*
-%{_datadir}/applications/*
+%{bindir}/*
+%{libdir}/*.so.*
+%{libdir}/gucharmap/immodules/im-gucharmap.so
+%{datadir}/pixmaps/*
+%{datadir}/applications/*
 
 %files devel
 %defattr(-, root, root, 0755)
-%{_libdir}/*.a
-%{_libdir}/*.so
-%{_libdir}/pkgconfig/*
-%{_includedir}/%{name}/
-#exclude %{_libdir}/*.la
+%{libdir}/*.a
+%{libdir}/*.so
+%{libdir}/pkgconfig/*
+%{includedir}/%{name}/
+#exclude %{libdir}/*.la
 
 %changelog
+* Wed Jun 15 2005 James Ogley <james usr-local-bin org>
+- Add GPP rpm-fu allowing --with suse to be specified.
+
 * Fri May 02 2003 Dag Wieers <dag wieers com> - 0.6.0-0
 - Updated to release 0.6.0.
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]