package/qemu: add fine-grained target selection
authorYann E. MORIN <yann.morin.1998@free.fr>
Tue, 7 Oct 2014 22:38:14 +0000 (00:38 +0200)
committerPeter Korsgaard <peter@korsgaard.com>
Sun, 12 Oct 2014 16:59:37 +0000 (18:59 +0200)
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
package/qemu/Config.in
package/qemu/qemu.mk

index 96ec301fd782192a53dbfcaba1ab5f39f2f2078f..f29f8489aa8961bb8ee10b38b35774330e06da4e 100644 (file)
@@ -31,6 +31,25 @@ if BR2_PACKAGE_QEMU
 
 comment "Emulators selection"
 
+config BR2_PACKAGE_QEMU_CUSTOM_TARGETS
+       string "Enable specific targets"
+       help
+         Enter here the list of QEMU targets you want to build. For example:
+
+           System emulation      | User-land emulation
+           ----------------------+-----------------------
+           i386-softmmu          | i386-linux-user
+           arm-softmmu           | ppc-linux-user
+           x86_64-softmmu        | sparc-bsd-user
+           ...                   | ...
+
+config QEMU_FOO
+       bool # To break the indentation
+
+if BR2_PACKAGE_QEMU_CUSTOM_TARGETS = ""
+
+comment "... or you can select emulator families to enable, below:"
+
 config BR2_PACKAGE_QEMU_SYSTEM
        bool "Enable all systems emulation"
        help
@@ -43,4 +62,6 @@ config BR2_PACKAGE_QEMU_LINUX_USER
 
 # Note: bsd-user can not be build on Linux
 
+endif # BR2_PACKAGE_QEMU_CUSTOM_TARGETS == ""
+
 endif # BR2_PACKAGE_QEMU
index 9f761455c33ce6f36219e10f6a83eaf9b613a896..5d9fd48a638f80762687d3a2cad4a29989deb37a 100644 (file)
@@ -111,6 +111,10 @@ else
 QEMU_OPTS += --disable-linux-user
 endif
 
+ifneq ($(call qstrip,$(BR2_PACKAGE_QEMU_CUSTOM_TARGETS)),)
+QEMU_OPTS += --target-list="$(call qstrip,$(BR2_PACKAGE_QEMU_CUSTOM_TARGETS))"
+endif
+
 define QEMU_CONFIGURE_CMDS
        ( cd $(@D);                                 \
            LIBS='$(QEMU_LIBS)'                     \