public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: app-emulation/spice-vdagent/files/, app-emulation/spice-vdagent/
@ 2016-06-14 19:02 Matthias Maier
  0 siblings, 0 replies; 2+ messages in thread
From: Matthias Maier @ 2016-06-14 19:02 UTC (permalink / raw
  To: gentoo-commits

commit:     8a280a29f985b5caa977ef4c7624fca8f3bdda07
Author:     Matthias Maier <tamiko <AT> gentoo <DOT> org>
AuthorDate: Tue Jun 14 18:45:32 2016 +0000
Commit:     Matthias Maier <tamiko <AT> gentoo <DOT> org>
CommitDate: Tue Jun 14 19:02:29 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8a280a29

app-emulation/spice-vdagent: bump to 0.17.0

Package-Manager: portage-2.2.28

 app-emulation/spice-vdagent/Manifest               |  1 +
 .../spice-vdagent/files/spice-vdagent.confd        |  7 ---
 .../{spice-vdagent.initd => spice-vdagent.initd-3} | 19 ++++++--
 .../spice-vdagent/spice-vdagent-0.17.0.ebuild      | 56 ++++++++++++++++++++++
 4 files changed, 72 insertions(+), 11 deletions(-)

diff --git a/app-emulation/spice-vdagent/Manifest b/app-emulation/spice-vdagent/Manifest
index 628197d..92e95de 100644
--- a/app-emulation/spice-vdagent/Manifest
+++ b/app-emulation/spice-vdagent/Manifest
@@ -1 +1,2 @@
 DIST spice-vdagent-0.16.0.tar.bz2 128174 SHA256 5b951646e0bd996afda2d063e706fa2aad2655af5bdd1b6525260ab50be30f7d SHA512 033fe60f152daceb05b51963b78daf6f757d0ad26398f47479c957c5c0f1735e26019c05ef30e485317ba75dd1a57ee1bffbab20eb2c46614d88ed7401795a97 WHIRLPOOL b94a60e15eb0ea107e974ad68bd07296eec9e08840afb2e57da64b35f26a613637975791e1a615af260acf9345ec016564ab15d96a00443665b5d1880b267d71
+DIST spice-vdagent-0.17.0.tar.bz2 130413 SHA256 f14a8bd8cdee10641aabd9ba32461a5844eab0fddb2a10c1d31386e7a9f7b33d SHA512 b26e44f6463ba70d5815956b301cc2351db22de41ed2ce8b2828d9bfa1cc581c86acd433f8f0d35d552d20f6ca140f88fa39b079ba26e9166dc07ad35bee502e WHIRLPOOL b83d034897c0a9ebc224072214081847ab0276edde82ad0d94d107421971fe64afc03ba3f7464735911fd57cf7a05b0cfcb0ecbb32eb4d55adc8abcf23fe8d09

diff --git a/app-emulation/spice-vdagent/files/spice-vdagent.confd b/app-emulation/spice-vdagent/files/spice-vdagent.confd
deleted file mode 100644
index 326f894..0000000
--- a/app-emulation/spice-vdagent/files/spice-vdagent.confd
+++ /dev/null
@@ -1,7 +0,0 @@
-
-# The virtual communication port provided by the hypervisor/vm
-PORT="/dev/virtio-ports/com.redhat.spice.0"
-
-# extra arguments for spice-vdagentd
-SPICE_VDAGENT_ARGS=""
-

diff --git a/app-emulation/spice-vdagent/files/spice-vdagent.initd b/app-emulation/spice-vdagent/files/spice-vdagent.initd-3
similarity index 71%
rename from app-emulation/spice-vdagent/files/spice-vdagent.initd
rename to app-emulation/spice-vdagent/files/spice-vdagent.initd-3
index d9ab902..02902fe 100644
--- a/app-emulation/spice-vdagent/files/spice-vdagent.initd
+++ b/app-emulation/spice-vdagent/files/spice-vdagent.initd-3
@@ -1,5 +1,5 @@
 #!/sbin/openrc-run
-# Copyright 1999-2011 Gentoo Foundation
+# Copyright 1999-2012 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 
@@ -10,15 +10,22 @@ depend() {
 PIDFILE="/var/run/spice-vdagentd/spice-vdagentd.pid"
 
 start() {
+    PORT="${PORT:-/dev/virtio-ports/com.redhat.spice.0}"
+    DEVICE="${DEVICE:-/dev/uinput}"
+
     ebegin "Checking for required modules and devices"
 
-    if [[ ! -d /sys/module/uinput ]] ; then
+    if [ ! -d /sys/module/uinput ]; then
+        modprobe -q uinput
+    fi
+
+    if [ ! -d /sys/module/uinput ]; then
         eerror "Module 'uinput' not loaded or not enabled in the kernel"
         eend 1
         return 1
     fi
 
-    if [[ ! -c "${PORT}" ]] ; then
+    if [ ! -c "${PORT}" ] ; then
         eerror "Required virtio port does not exist. Make sure you"
         eerror "started the virtual machine with appropriate parameters."
         eend 1
@@ -26,6 +33,10 @@ start() {
     fi
     eend 0
 
+    if [ ! -c ${DEVICE} -a -c /dev/input/uinput ]; then
+        DEVICE=/dev/input/uinput
+    fi
+
     # recreate the directory since /var/run may reside on a ramdisk
     mkdir -p /var/run/spice-vdagentd
 
@@ -37,7 +48,7 @@ start() {
         --start \
         --pidfile "${PIDFILE}" \
         --exec /usr/sbin/spice-vdagentd \
-        -- ${SPICE_VDAGENT_ARGS}
+        -- -u "${DEVICE}" ${SPICE_VDAGENT_ARGS}
     eend $?
 }
 

diff --git a/app-emulation/spice-vdagent/spice-vdagent-0.17.0.ebuild b/app-emulation/spice-vdagent/spice-vdagent-0.17.0.ebuild
new file mode 100644
index 0000000..07947b0
--- /dev/null
+++ b/app-emulation/spice-vdagent/spice-vdagent-0.17.0.ebuild
@@ -0,0 +1,56 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit linux-info
+
+DESCRIPTION="SPICE VD Linux Guest Agent"
+HOMEPAGE="http://spice-space.org/"
+SRC_URI="http://spice-space.org/download/releases/${P}.tar.bz2"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="+consolekit selinux systemd"
+
+CDEPEND="media-libs/alsa-lib
+	x11-libs/libXfixes
+	x11-libs/libXrandr
+	x11-libs/libX11
+	x11-libs/libXinerama
+	>=x11-libs/libpciaccess-0.10
+	>=app-emulation/spice-protocol-0.12.8
+	consolekit? ( sys-auth/consolekit sys-apps/dbus )
+	systemd? ( sys-apps/systemd )"
+DEPEND="virtual/pkgconfig
+	${CDEPEND}"
+RDEPEND="${CDEPEND}
+	selinux? ( sec-policy/selinux-vdagent )"
+
+CONFIG_CHECK="~INPUT_UINPUT ~VIRTIO_CONSOLE"
+ERROR_INPUT_UINPUT="User level input support is required"
+ERROR_VIRTIO_CONSOLE="VirtIO console/serial device support is required"
+
+src_configure() {
+	local opt="--with-session-info=none --with-init-script=systemd"
+
+	use systemd && opt+=" --with-session-info=systemd"
+	use consolekit && opt+=" --with-session-info=console-kit"
+
+	econf \
+		--localstatedir=/var \
+		${opt}
+}
+
+src_install() {
+	default
+
+	rm -rf "${D}"/etc/{rc,tmpfiles}.d
+
+	keepdir /var/log/spice-vdagentd
+
+	newinitd "${FILESDIR}/${PN}.initd-3" "${PN}"
+	newconfd "${FILESDIR}/${PN}.confd-2" "${PN}"
+}


^ permalink raw reply related	[flat|nested] 2+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-emulation/spice-vdagent/files/, app-emulation/spice-vdagent/
@ 2019-07-28 19:39 Matthias Maier
  0 siblings, 0 replies; 2+ messages in thread
From: Matthias Maier @ 2019-07-28 19:39 UTC (permalink / raw
  To: gentoo-commits

commit:     b3b3e1d9a13c389f17e01c78c6c1a996d08420b5
Author:     Matthias Maier <tamiko <AT> gentoo <DOT> org>
AuthorDate: Sun Jul 28 19:01:38 2019 +0000
Commit:     Matthias Maier <tamiko <AT> gentoo <DOT> org>
CommitDate: Sun Jul 28 19:37:44 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b3b3e1d9

app-emulation/spice-vdagent: fix init script

Closes: https://bugs.gentoo.org/670576
Package-Manager: Portage-2.3.69, Repoman-2.3.16
Signed-off-by: Matthias Maier <tamiko <AT> gentoo.org>

 .../spice-vdagent/files/spice-vdagent.initd-4      | 60 ++++++++++++++++++++++
 .../spice-vdagent/spice-vdagent-0.19.0.ebuild      |  2 +-
 2 files changed, 61 insertions(+), 1 deletion(-)

diff --git a/app-emulation/spice-vdagent/files/spice-vdagent.initd-4 b/app-emulation/spice-vdagent/files/spice-vdagent.initd-4
new file mode 100644
index 00000000000..ee416dacd89
--- /dev/null
+++ b/app-emulation/spice-vdagent/files/spice-vdagent.initd-4
@@ -0,0 +1,60 @@
+#!/sbin/openrc-run
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+depend() {
+    after dbus
+}
+
+PIDFILE="/var/run/spice-vdagentd/spice-vdagentd.pid"
+
+start() {
+    PORT="${PORT:-/dev/virtio-ports/com.redhat.spice.0}"
+    DEVICE="${DEVICE:-/dev/uinput}"
+
+    ebegin "Checking for required modules and devices"
+
+    if [ ! -d /sys/module/uinput ]; then
+        modprobe -q uinput
+    fi
+
+    if [ ! -e /dev/uinput ]; then
+        eerror "Module 'uinput' not loaded or not enabled in the kernel"
+        eend 1
+        return 1
+    fi
+
+    if [ ! -c "${PORT}" ] ; then
+        eerror "Required virtio port does not exist. Make sure you"
+        eerror "started the virtual machine with appropriate parameters."
+        eend 1
+        return 1
+    fi
+    eend 0
+
+    if [ ! -c ${DEVICE} -a -c /dev/input/uinput ]; then
+        DEVICE=/dev/input/uinput
+    fi
+
+    # recreate the directory since /var/run may reside on a ramdisk
+    mkdir -p /var/run/spice-vdagentd
+
+    # cleanup stalled socket
+    rm -f /var/run/spice-vdagentd/spice-vdagent-sock
+
+    ebegin "Starting spice VD agent daemon"
+    start-stop-daemon \
+        --start \
+        --pidfile "${PIDFILE}" \
+        --exec /usr/sbin/spice-vdagentd \
+        -- -u "${DEVICE}" ${SPICE_VDAGENT_ARGS}
+    eend $?
+}
+
+stop() {
+    ebegin "Stopping spice VD agent daemon"
+    start-stop-daemon \
+        --stop \
+        --pidfile "${PIDFILE}"
+    eend $?
+}

diff --git a/app-emulation/spice-vdagent/spice-vdagent-0.19.0.ebuild b/app-emulation/spice-vdagent/spice-vdagent-0.19.0.ebuild
index 07401dc2494..d62b552d79d 100644
--- a/app-emulation/spice-vdagent/spice-vdagent-0.19.0.ebuild
+++ b/app-emulation/spice-vdagent/spice-vdagent-0.19.0.ebuild
@@ -65,6 +65,6 @@ src_install() {
 
 	keepdir /var/log/spice-vdagentd
 
-	newinitd "${FILESDIR}/${PN}.initd-3" "${PN}"
+	newinitd "${FILESDIR}/${PN}.initd-4" "${PN}"
 	newconfd "${FILESDIR}/${PN}.confd-2" "${PN}"
 }


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-07-28 19:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-06-14 19:02 [gentoo-commits] repo/gentoo:master commit in: app-emulation/spice-vdagent/files/, app-emulation/spice-vdagent/ Matthias Maier
  -- strict thread matches above, loose matches on Subject: below --
2019-07-28 19:39 Matthias Maier

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox