Patchwork [26/29] package/qemu: add option to install tools on the target

login
register
mail settings
Submitter Yann E. MORIN
Date Jan. 29, 2013, 10:44 p.m.
Message ID <7b23992399e493c0c3f92dae39ec27b80e19ee7b.1359498903.git.yann.morin.1998@free.fr>
Download mbox | patch
Permalink /patch/216715/
State Changes Requested
Headers show

Comments

Yann E. MORIN - Jan. 29, 2013, 10:44 p.m.
Usually, tools on the target are not needed, so they are disabled
by default. Add an option to install them on the target.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
---
 package/qemu/Config.in |    6 ++++++
 package/qemu/qemu.mk   |    7 ++++++-
 2 files changed, 12 insertions(+), 1 deletions(-)

Patch

diff --git a/package/qemu/Config.in b/package/qemu/Config.in
index f71311d..022b07b 100644
--- a/package/qemu/Config.in
+++ b/package/qemu/Config.in
@@ -271,6 +271,12 @@  config BR2_PACKAGE_QEMU_SECCOMP
 	  Say 'y' here to have QEMU to use the Linux kernel's seccomp filter,
 	  to more tightly confine the VMs.
 
+config BR2_PACKAGE_QEMU_TOOLS_ON_TARGET
+	bool "tools on target"
+	help
+	  Say 'y' here to also install QEMU tools (qemu-{img,io,nbd}) on the
+	  target.
+
 config BR2_PACKAGE_QEMU_BLOBS
 	bool "Install binary blobs"
 	default y
diff --git a/package/qemu/qemu.mk b/package/qemu/qemu.mk
index 90b1ebf..d745e0d 100644
--- a/package/qemu/qemu.mk
+++ b/package/qemu/qemu.mk
@@ -258,6 +258,12 @@  else
 QEMU_OPTS += --disable-seccomp
 endif
 
+ifeq ($(BR2_PACKAGE_QEMU_TOOLS_ON_TARGET),y)
+QEMU_OPTS += --enable-tools
+else
+QEMU_OPTS += --disable-tools
+endif
+
 ifeq ($(BR2_PACKAGE_QEMU_BLOBS),)
 QEMU_OPTS += --disable-blobs
 endif
@@ -352,7 +358,6 @@  define QEMU_CONFIGURE_CMDS
 	        --disable-smartcard                 \
 	        --disable-strip                     \
 	        --disable-sparse                    \
-	        --disable-tools                     \
 	        $(QEMU_OPTS)                        \
 	)
 endef