Skip to content
Snippets Groups Projects
Commit d5ae8aaf authored by Laurent Léonard's avatar Laurent Léonard
Browse files

Drop patches

build-let-xgettext-see-strings-in-libvirt-guests.patch - fixed upstream http://libvirt.org/git/?p=libvirt.git;a=commit;h=7f193757efe572e0a8427e400fc8108bad50c8a9
libvirt-guests-remove-bashisms.patch - fixed upstream http://libvirt.org/git/?p=libvirt.git;a=commit;h=a9e31a476948bfcf27a2cca1ffa78d6a1b4b939c
parent 759fcdba
No related branches found
No related tags found
No related merge requests found
......@@ -16,10 +16,10 @@ Bug: https://bugzilla.redhat.com/show_bug.cgi?id=614420
1 files changed, 40 insertions(+), 7 deletions(-)
diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c
index ee2de4a..9788874 100644
index 4ca0d3b..27757ce 100644
--- a/src/remote/remote_driver.c
+++ b/src/remote/remote_driver.c
@@ -732,7 +732,8 @@ doRemoteOpen (virConnectPtr conn,
@@ -738,7 +738,8 @@ doRemoteOpen (virConnectPtr conn,
}
case trans_ssh: {
......@@ -29,7 +29,7 @@ index ee2de4a..9788874 100644
if (username) nr_args += 2; /* For -l username */
if (no_tty) nr_args += 5; /* For -T -o BatchMode=yes -e none */
@@ -765,12 +766,44 @@ doRemoteOpen (virConnectPtr conn,
@@ -771,12 +772,44 @@ doRemoteOpen (virConnectPtr conn,
cmd_argv[j++] = strdup ("none");
}
cmd_argv[j++] = strdup (priv->hostname);
......
......@@ -10,10 +10,10 @@ Closes: #598330
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/src/util/iptables.c b/src/util/iptables.c
index 6770fe0..1fce1ec 100644
index 59f5cc7..8c1f727 100644
--- a/src/util/iptables.c
+++ b/src/util/iptables.c
@@ -861,6 +861,7 @@ iptablesOutputFixUdpChecksum(iptablesContext *ctx,
@@ -870,6 +870,7 @@ iptablesOutputFixUdpChecksum(iptablesContext *ctx,
int port,
int action)
{
......@@ -21,7 +21,7 @@ index 6770fe0..1fce1ec 100644
char portstr[32];
snprintf(portstr, sizeof(portstr), "%d", port);
@@ -874,6 +875,9 @@ iptablesOutputFixUdpChecksum(iptablesContext *ctx,
@@ -883,6 +884,9 @@ iptablesOutputFixUdpChecksum(iptablesContext *ctx,
"--destination-port", portstr,
"--jump", "CHECKSUM", "--checksum-fill",
NULL);
......
......@@ -8,16 +8,16 @@ unbreaks dnsmasq >= 2.56
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c
index 7d43ef5..8499ae4 100644
index c4ee1e8..c8b1e12 100644
--- a/src/network/bridge_driver.c
+++ b/src/network/bridge_driver.c
@@ -466,7 +466,7 @@ networkBuildDnsmasqArgv(virNetworkObjPtr network,
@@ -468,7 +468,7 @@ networkBuildDnsmasqArgv(virNetworkObjPtr network,
virCommandAddArgPair(cmd, "--pid-file", pidfile);
/* *no* conf file */
- virCommandAddArgList(cmd, "--conf-file=", "", NULL);
+ virCommandAddArgList(cmd, "--conf-file=", NULL);
/*
* XXX does not actually work, due to some kind of
virCommandAddArgList(cmd,
"--except-interface", "lo",
--
......@@ -12,7 +12,7 @@ Closes: #517059
5 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/xen/xen_hypervisor.c b/src/xen/xen_hypervisor.c
index ead8ee9..33f280a 100644
index 4a0924f..4d27d92 100644
--- a/src/xen/xen_hypervisor.c
+++ b/src/xen/xen_hypervisor.c
@@ -2269,7 +2269,7 @@ xenHypervisorBuildCapabilities(virConnectPtr conn,
......
From: =?UTF-8?q?Laurent=20L=C3=A9onard?= <laurent@open-minds.org>
Date: Tue, 4 Jan 2011 19:13:56 +0100
Subject: libvirt-guests: remove bashisms
* tools/libvirt-guests.init.sh: Use only POSIX shell features, which
includes using gettext.sh for translation rather than $"".
* tools/Makefile.am (libvirt-guests.init): Supply a few more substitutions.
* po/POTFILES.in: Mark that libvirt-guests.init needs translation.
Signed-off-by: Eric Blake <eblake@redhat.com>
Origin: upstream, http://libvirt.org/git/?p=libvirt.git;a=commit;h=a9e31a476948bfcf27a2cca1ffa78d6a1b4b939c
---
po/POTFILES.in | 1 +
tools/Makefile.am | 9 +++--
tools/libvirt-guests.init.in | 72 ++++++++++++++++++++++++-----------------
3 files changed, 49 insertions(+), 33 deletions(-)
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 3d7bc8b..9d9a86f 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -118,4 +118,5 @@ src/xen/xs_internal.c
src/xenapi/xenapi_driver.c
src/xenapi/xenapi_utils.c
tools/console.c
+tools/libvirt-guests.init.in
tools/virsh.c
diff --git a/tools/Makefile.am b/tools/Makefile.am
index 271c11b..87cf9bd 100644
--- a/tools/Makefile.am
+++ b/tools/Makefile.am
@@ -146,9 +146,12 @@ BUILT_SOURCES += libvirt-guests.init
libvirt-guests.init: libvirt-guests.init.in $(top_builddir)/config.status
$(AM_V_GEN)sed \
- -e s!\@localstatedir\@!@localstatedir@!g \
- -e s!\@sbindir\@!@sbindir@!g \
- -e s!\@sysconfdir\@!@sysconfdir@!g \
+ -e 's!\@PACKAGE\@!$(PACKAGE)!g' \
+ -e 's!\@bindir\@!$(bindir)!g' \
+ -e 's!\@localedir\@!$(localedir)!g' \
+ -e 's!\@localstatedir\@!$(localstatedir)!g' \
+ -e 's!\@sbindir\@!$(sbindir)!g' \
+ -e 's!\@sysconfdir\@!$(sysconfdir)!g' \
< $< > $@-t && \
chmod a+x $@-t && \
mv $@-t $@
diff --git a/tools/libvirt-guests.init.in b/tools/libvirt-guests.init.in
index e28938d..8823d06 100644
--- a/tools/libvirt-guests.init.in
+++ b/tools/libvirt-guests.init.in
@@ -24,20 +24,27 @@
# See http://libvirt.org
#
-sysconfdir=@sysconfdir@
-localstatedir=@localstatedir@
-libvirtd=@sbindir@/libvirtd
+sysconfdir="@sysconfdir@"
+localstatedir="@localstatedir@"
+libvirtd="@sbindir@"/libvirtd
# Source function library.
test ! -r "$sysconfdir"/rc.d/init.d/functions ||
- . "$sysconfdir"/rc.d/init.d/functions
+ . "$sysconfdir"/rc.d/init.d/functions
+
+# Source gettext library.
+# Make sure this file is recognized as having translations: _("dummy")
+. "@bindir@"/gettext.sh
+
+export TEXTDOMAIN="@PACKAGE@" TEXTDOMAINDIR="@localedir@"
URIS=default
ON_BOOT=start
ON_SHUTDOWN=suspend
SHUTDOWN_TIMEOUT=0
-test -f "$sysconfdir"/sysconfig/libvirt-guests && . "$sysconfdir"/sysconfig/libvirt-guests
+test -f "$sysconfdir"/sysconfig/libvirt-guests &&
+ . "$sysconfdir"/sysconfig/libvirt-guests
LISTFILE="$localstatedir"/lib/libvirt/libvirt-guests
VAR_SUBSYS_LIBVIRT_GUESTS="$localstatedir"/lock/subsys/libvirt-guests
@@ -129,7 +136,8 @@ start() {
[ -f "$LISTFILE" ] || { started; return 0; }
if [ "x$ON_BOOT" != xstart ]; then
- echo $"libvirt-guests is configured not to start any guests on boot"
+ gettext "libvirt-guests is configured not to start any guests on boot"
+ echo
rm -f "$LISTFILE"
started
return 0
@@ -144,20 +152,20 @@ start() {
fi
done
if ! $configured; then
- echo $"Ignoring guests on $uri URI"
+ eval_gettext "Ignoring guests on \$uri URI"; echo
continue
fi
- echo $"Resuming guests on $uri URI..."
+ eval_gettext "Resuming guests on \$uri URI..."; echo
for guest in $list; do
name=$(guest_name $uri $guest)
- echo -n $"Resuming guest $name: "
+ eval_gettext "Resuming guest \$name: "
if guest_is_on $uri $guest; then
if $guest_running; then
- echo $"already active"
+ gettext "already active"; echo
else
retval run_virsh $uri start "$name" >/dev/null && \
- echo $"done"
+ gettext "done"; echo
fi
fi
done
@@ -173,8 +181,8 @@ suspend_guest()
guest=$2
name=$(guest_name $uri $guest)
- label=$"Suspending $name: "
- echo -n "$label"
+ label=$(eval_gettext "Suspending \$name: ")
+ printf %s "$label"
run_virsh $uri managedsave $guest >/dev/null &
virsh_pid=$!
while true; do
@@ -188,7 +196,7 @@ suspend_guest()
printf '\r%s%-12s ' "$label" "..."
fi
done
- retval wait $virsh_pid && printf '\r%s%-12s\n' "$label" $"done"
+ retval wait $virsh_pid && printf '\r%s%-12s\n' "$label" "$(gettext "done")"
}
shutdown_guest()
@@ -197,13 +205,13 @@ shutdown_guest()
guest=$2
name=$(guest_name $uri $guest)
- label=$"Shutting down $name: "
- echo -n "$label"
+ label=$(eval_gettext "Shutting down \$name: ")
+ printf %s "$label"
retval run_virsh $uri shutdown $guest >/dev/null || return
timeout=$SHUTDOWN_TIMEOUT
while [ $timeout -gt 0 ]; do
sleep 1
- timeout=$[timeout - 1]
+ timeout=$((timeout - 1))
guest_is_on $uri $guest || return
$guest_running || break
printf '\r%s%-12d ' "$label" $timeout
@@ -211,9 +219,10 @@ shutdown_guest()
if guest_is_on $uri $guest; then
if $guest_running; then
- printf '\r%s%-12s\n' "$label" $"failed to shutdown in time"
+ printf '\r%s%-12s\n' "$label" \
+ "$(gettext "failed to shutdown in time")"
else
- printf '\r%s%-12s\n' "$label" $"done"
+ printf '\r%s%-12s\n' "$label" "$(gettext "done")"
fi
fi
}
@@ -226,7 +235,8 @@ stop() {
if [ "x$ON_SHUTDOWN" = xshutdown ]; then
suspending=false
if [ $SHUTDOWN_TIMEOUT -le 0 ]; then
- echo $"Shutdown action requested but SHUTDOWN_TIMEOUT was not set"
+ gettext "Shutdown action requested but SHUTDOWN_TIMEOUT was not set"
+ echo
RETVAL=6
return
fi
@@ -234,10 +244,10 @@ stop() {
: >"$LISTFILE"
for uri in $URIS; do
- echo -n $"Running guests on $uri URI: "
+ eval_gettext "Running guests on \$uri URI: "
if [ "x$uri" = xdefault ] && [ ! -x "$libvirtd" ]; then
- echo $"libvirtd not installed; skipping this URI."
+ gettext "libvirtd not installed; skipping this URI."; echo
continue
fi
@@ -246,11 +256,11 @@ stop() {
empty=true
for uuid in $list; do
$empty || printf ", "
- echo -n $(guest_name $uri $uuid)
+ printf %s "$(guest_name $uri $uuid)"
empty=false
done
if $empty; then
- echo $"no running guests."
+ gettext "no running guests."; echo
else
echo
echo $uri $list >>"$LISTFILE"
@@ -260,9 +270,9 @@ stop() {
while read uri list; do
if $suspending; then
- echo $"Suspending guests on $uri URI..."
+ eval_gettext "Suspending guests on \$uri URI..."; echo
else
- echo $"Shutting down guests on $uri URI..."
+ eval_gettext "Shutting down guests on \$uri URI..."; echo
fi
for guest in $list; do
@@ -290,13 +300,13 @@ gueststatus() {
# since there is no external daemon process matching this init script.
rh_status() {
if [ -f "$LISTFILE" ]; then
- echo $"stopped, with saved guests"
+ gettext "stopped, with saved guests"; echo
RETVAL=3
else
if [ -f "$VAR_SUBSYS_LIBVIRT_GUESTS" ]; then
- echo $"started"
+ gettext "started"; echo
else
- echo $"stopped, with no saved guests"
+ gettext "stopped, with no saved guests"; echo
fi
RETVAL=0
fi
@@ -305,7 +315,9 @@ rh_status() {
# usage [val]
# Display usage string, then exit with VAL (defaults to 2).
usage() {
- echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload|gueststatus|shutdown}"
+ program_name=$0
+ eval_gettext "Usage: \$program_name {start|stop|status|restart|"\
+"condrestart|try-restart|reload|force-reload|gueststatus|shutdown}"; echo
exit ${1-2}
}
--
......@@ -41,10 +41,10 @@ to savely detect that the command 'info migrate' is not implemented.
1 files changed, 9 insertions(+), 1 deletions(-)
diff --git a/src/qemu/qemu_monitor_text.c b/src/qemu/qemu_monitor_text.c
index 11a9391..5feb029 100644
index 6d0ba4c..72455ac 100644
--- a/src/qemu/qemu_monitor_text.c
+++ b/src/qemu/qemu_monitor_text.c
@@ -1125,7 +1125,15 @@ int qemuMonitorTextGetMigrationStatus(qemuMonitorPtr mon,
@@ -1194,7 +1194,15 @@ int qemuMonitorTextGetMigrationStatus(qemuMonitorPtr mon,
*total *= 1024;
}
......
......@@ -8,7 +8,7 @@ Subject: qemu-disable-network.diff
2 files changed, 0 insertions(+), 6 deletions(-)
diff --git a/src/Makefile.am b/src/Makefile.am
index c13724a..12b492b 100644
index 2f94efd..8f85aab 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1244,9 +1244,6 @@ if WITH_NETWORK
......@@ -22,10 +22,10 @@ index c13724a..12b492b 100644
uninstall-local::
diff --git a/src/Makefile.in b/src/Makefile.in
index ea9c404..9d8df32 100644
index bff8403..f146183 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -5426,9 +5426,6 @@ install-data-local:
@@ -5548,9 +5548,6 @@ install-data-local:
@WITH_NETWORK_TRUE@ cp $(DESTDIR)$(sysconfdir)/libvirt/qemu/networks/default.xml.t \
@WITH_NETWORK_TRUE@ $(DESTDIR)$(sysconfdir)/libvirt/qemu/networks/default.xml && \
@WITH_NETWORK_TRUE@ rm $(DESTDIR)$(sysconfdir)/libvirt/qemu/networks/default.xml.t; }
......
......@@ -7,7 +7,7 @@ Subject: remove-RHism.diff
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/tools/virsh.pod b/tools/virsh.pod
index 9c45a61..e3e9915 100644
index a2ca384..2086adb 100644
--- a/tools/virsh.pod
+++ b/tools/virsh.pod
@@ -97,7 +97,7 @@ Output elapsed time information for each command.
......
......@@ -5,7 +5,5 @@ fix-Debian-specific-path-to-hvm-loader.patch
Autodetect-if-the-remote-nc-command-supports-the-q-o.patch
patch-qemuMonitorTextGetMigrationStatus-to-intercept.patch
Disable-CHECKSUM-rule.patch
libvirt-guests-remove-bashisms.patch
build-let-xgettext-see-strings-in-libvirt-guests.patch
Debianize-libvirt-guests.patch
Don-t-pass-empty-arguments-to-dnsmasq.patch
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment