- Fix broken multiline description in initscript lsb header (#648549)

This commit is contained in:
Hans de Goede 2010-11-10 09:31:42 +01:00
parent cbaebaf6b1
commit 3ec7519ac1
6 changed files with 186 additions and 0 deletions

1
.gitignore vendored
View File

@ -0,0 +1 @@
/spice-vdagent-0.6.3.tar.bz2

View File

@ -0,0 +1,41 @@
From 949a7110f5a389e7554b6d3b9bdfa262954b1669 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 1 Nov 2010 16:16:20 +0100
Subject: [PATCH 1/2] Install spice-vdagentd in /usr/sbin not /sbin
Now that it is no longer launched by a udev rule it does not need to be in
/sbin.
---
Makefile | 2 +-
spice-vdagentd.sh | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/Makefile b/Makefile
index 5a67890..0f3586e 100644
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
VERSION = 0.6.3
DESTDIR ?=
-sbindir ?= /sbin
+sbindir ?= /usr/sbin
bindir ?= /usr/bin
initdir ?= /etc/rc.d/init.d
xdgautostartdir ?= /etc/xdg/autostart
diff --git a/spice-vdagentd.sh b/spice-vdagentd.sh
index 7037b42..0a62c2b 100644
--- a/spice-vdagentd.sh
+++ b/spice-vdagentd.sh
@@ -24,7 +24,7 @@
# Source function library.
. /etc/rc.d/init.d/functions
-exec="/sbin/spice-vdagentd"
+exec="/usr/sbin/spice-vdagentd"
prog="spice-vdagentd"
port="/dev/virtio-ports/com.redhat.spice.0"
--
1.7.3.1

View File

@ -0,0 +1,28 @@
From c337c0b89c23395679accd8e24dea703fc21aa66 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 1 Nov 2010 16:17:20 +0100
Subject: [PATCH 2/2] Only start spice-vdagentd in runlevel 5
Having it in runlevels without X is not useful
---
spice-vdagentd.sh | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/spice-vdagentd.sh b/spice-vdagentd.sh
index 0a62c2b..a74bb63 100644
--- a/spice-vdagentd.sh
+++ b/spice-vdagentd.sh
@@ -13,8 +13,8 @@
# Required-Stop: $local_fs messagebus
# Should-Start: $local_fs messagebus
# Should-Stop: $local_fs messagebus
-# Default-Start: 2 3 4 5
-# Default-Stop: 0 1 6
+# Default-Start: 5
+# Default-Stop: 0 1 2 3 4 6
# Short-Description: Agent daemon for Spice guests
# Description: Together with a per X-session agent process the spice agent
# daemon enhances the spice guest user experience with client
--
1.7.3.1

View File

@ -0,0 +1,27 @@
From 1d9465f8822f3e241c8c22c862c873e37b49fb1b Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 8 Nov 2010 22:48:16 +0100
Subject: [PATCH] sysv initscript: fix lsb header multi line description
---
spice-vdagentd.sh | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/spice-vdagentd.sh b/spice-vdagentd.sh
index a74bb63..119a61a 100644
--- a/spice-vdagentd.sh
+++ b/spice-vdagentd.sh
@@ -17,8 +17,8 @@
# Default-Stop: 0 1 2 3 4 6
# Short-Description: Agent daemon for Spice guests
# Description: Together with a per X-session agent process the spice agent
-# daemon enhances the spice guest user experience with client
-# mouse mode, guest <-> client copy and paste support and more.
+# daemon enhances the spice guest user experience with client
+# mouse mode, guest <-> client copy and paste support and more.
### END INIT INFO
# Source function library.
--
1.7.3.2

View File

@ -0,0 +1 @@
dca976a6a92744462e1aed101f4ea467 spice-vdagent-0.6.3.tar.bz2

88
spice-vdagent.spec Normal file
View File

@ -0,0 +1,88 @@
Name: spice-vdagent
Version: 0.6.3
Release: 2%{?dist}
Summary: Agent for Spice guests
Group: Applications/System
License: GPLv3+
URL: http://spice-space.org/
Source0: http://spice-space.org/download/releases/%{name}-%{version}.tar.bz2
# 3 small fixes from upstream git
Patch0: 0001-Install-spice-vdagentd-in-usr-sbin-not-sbin.patch
Patch1: 0002-Only-start-spice-vdagentd-in-runlevel-5.patch
Patch2: 0003-sysv-initscript-fix-lsb-header-multi-line-descriptio.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: dbus-devel spice-protocol libXrandr-devel libXfixes-devel
BuildRequires: desktop-file-utils
Requires: ConsoleKit
Requires(post): chkconfig
Requires(postun): initscripts
Requires(preun): chkconfig
Requires(preun): initscripts
%description
Spice agent for Linux guests offering the following features:
Features:
* Client mouse mode (no need to grab mouse by client, no mouse lag)
this is handled by the daemon by feeding mouse events into the kernel
via uinput. This will only work if the active X-session is running a
spice-vdagent process so that its resolution can be determined.
* Automatic adjustment of the X-session resolution to the client resolution
* Support of copy and paste (text and images) between the active X-session
and the client
%prep
%setup -q
%patch0 -p1
%patch1 -p1
%patch2 -p1
%build
make %{?_smp_mflags} CFLAGS="$RPM_OPT_FLAGS"
%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
%clean
rm -rf $RPM_BUILD_ROOT
%post
/sbin/chkconfig --add spice-vdagentd
%preun
if [ $1 = 0 ] ; then
/sbin/service spice-vdagentd stop >/dev/null 2>&1
/sbin/chkconfig --del spice-vdagentd
fi
%postun
if [ "$1" -ge "1" ] ; then
/sbin/service spice-vdagentd condrestart >/dev/null 2>&1 || :
fi
%files
%defattr(-,root,root,-)
%doc COPYING ChangeLog README TODO
%{_initddir}/spice-vdagentd
%{_bindir}/spice-vdagent
%{_sbindir}/spice-vdagentd
%{_var}/run/spice-vdagentd
%{_sysconfdir}/xdg/autostart/spice-vdagent.desktop
# For /usr/share/gdm/autostart/LoginWindow/spice-vdagent.desktop
# We own the dir too, otherwise we must Require gdm
%{_datadir}/gdm
%changelog
* Mon Nov 8 2010 Hans de Goede <hdegoede@redhat.com> 0.6.3-2
- Fix broken multiline description in initscript lsb header (#648549)
* Sat Oct 30 2010 Hans de Goede <hdegoede@redhat.com> 0.6.3-1
- Initial Fedora package