From 57e2f52f79269a8178048512589f8ffe946f91d4 Mon Sep 17 00:00:00 2001 From: Rex Dieter Date: Feb 08 2008 19:39:58 +0000 Subject: - fixup ggz integration (#431726) per http://fedoraproject.org/wiki/PackagingDrafts/GGZ --- diff --git a/freeciv.spec b/freeciv.spec index 922373d..4561d7d 100644 --- a/freeciv.spec +++ b/freeciv.spec @@ -1,6 +1,6 @@ Name: freeciv Version: 2.1.3 -Release: 2%{?dist} +Release: 3%{?dist} Summary: The Freeciv multi-player strategy game Group: Amusements/Games @@ -21,6 +21,9 @@ BuildRequires: ggz-gtk-client-devel BuildRequires: desktop-file-utils BuildRequires: gettext +Requires(post): ggz-client-lib +Requires(preun): ggz-client-lib + %description Freeciv is a turn-based, multi-player, X based strategy game. Freeciv @@ -55,6 +58,11 @@ desktop-file-install --vendor fedora --delete-original \ # Remove civmanual rm $RPM_BUILD_ROOT%{_bindir}/civmanual +# ggz config +# omit ggz.modules, to register at install, not build, time. +rm $RPM_BUILD_ROOT%{_sysconfdir}/ggz.modules +# include .dsc files +install -p -D -m644 data/civclient.dsc $RPM_BUILD_ROOT%{_ggz_datadir}/civclient.dsc %clean @@ -62,11 +70,16 @@ rm -rf $RPM_BUILD_ROOT %post +%{_ggz_config} --install --force --modfile=%{_ggz_datadir}/civclient.dsc || : touch --no-create %{_datadir}/icons/hicolor if [ -x %{_bindir}/gtk-update-icon-cache ]; then %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || : fi +%preun +if [ $1 -eq 0 ]; then +%{_ggz_config} --remove --modfile=%{_ggz_datadir}/civclient.dsc || : +fi %postun touch --no-create %{_datadir}/icons/hicolor @@ -94,10 +107,13 @@ fi %{_datadir}/pixmaps/%{name}-client.png %{_mandir}/man6/civserver.6.gz %{_mandir}/man6/civclient.6.gz -%config(noreplace) %{_sysconfdir}/ggz.modules +%{_ggz_datadir}/civclient.dsc %changelog +* Fri Feb 8 2008 Rex Dieter 2.1.3-3 +- fixup ggz integration (#431726) + * Mon Feb 4 2008 Brian Pepple - 2.1.3-2 - Add ggz gaming support.