package/qemu: do not use autotools for qemu
authorYann E. MORIN <yann.morin.1998@free.fr>
Tue, 7 Oct 2014 22:38:10 +0000 (00:38 +0200)
committerPeter Korsgaard <peter@korsgaard.com>
Sun, 12 Oct 2014 16:41:26 +0000 (18:41 +0200)
Although QEMU has a ./configure script, it is not an autotools-package,
so switch to providing build and install commands, and to using
generic-package.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
package/qemu/qemu.mk

index 827bb77bce71818d86386b4d1572214834bb35bd..9654b9079e7de18d6e22af7f348c522cc07c4aa4 100644 (file)
@@ -59,22 +59,26 @@ ifeq ($(HOST_QEMU_ARCH),powerpc)
 endif
 HOST_QEMU_TARGETS = $(HOST_QEMU_ARCH)-linux-user
 
-# Note: although QEMU has a ./configure script, it is not a real autotools
-# package, and ./configure chokes on options such as --host or --target.
-# So, provide out own _CONFIGURE_CMDS to override the defaults.
 define HOST_QEMU_CONFIGURE_CMDS
-       (cd $(@D); $(HOST_CONFIGURE_OPTS) ./configure   \
+       cd $(@D); $(HOST_CONFIGURE_OPTS) ./configure    \
                --target-list="$(HOST_QEMU_TARGETS)"    \
                --prefix="$(HOST_DIR)/usr"              \
                --interp-prefix=$(STAGING_DIR)          \
                --cc="$(HOSTCC)"                        \
                --host-cc="$(HOSTCC)"                   \
                --extra-cflags="$(HOST_CFLAGS)"         \
-               --extra-ldflags="$(HOST_LDFLAGS)"       \
-       )
+               --extra-ldflags="$(HOST_LDFLAGS)"
 endef
 
-$(eval $(host-autotools-package))
+define HOST_QEMU_BUILD_CMDS
+       $(HOST_MAKE_ENV) $(MAKE) -C $(@D)
+endef
+
+define HOST_QEMU_INSTALL_CMDS
+       $(HOST_MAKE_ENV) $(MAKE) -C $(@D) DESTDIR=$(HOST_DIR) install
+endef
+
+$(eval $(host-generic-package))
 
 # variable used by other packages
 QEMU_USER = $(HOST_DIR)/usr/bin/qemu-$(HOST_QEMU_ARCH)