qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel][PATCH] Re: [4792] Change the way audio is configured


From: Stefan Weil
Subject: Re: [Qemu-devel][PATCH] Re: [4792] Change the way audio is configured
Date: Fri, 27 Jun 2008 22:03:13 +0200
User-agent: Mozilla-Thunderbird 2.0.0.14 (X11/20080509)

Laurent Vivier schrieb:

Le 27 juin 08 à 17:34, consul a écrit :

audio/audio.c:42: error: `AUDIO_DRIVERS' undeclared here (not in a function)
audio/audio.c:42: error: initializer element is not constant
audio/audio.c:42: error: (near initialization for `drvtab[0]')

Paste error?

No you have to re-run "./configure".

Here is a small patch which automatically calls configure when the file changes. It also tells users to run configure when they call make without a configuration.

The patch is not perfect: it tries to call configure with the last options, but it will fail at options containing white space. These are rarely used, so it is
still useful.

Stefan

Index: Makefile
===================================================================
--- Makefile    (revision 4795)
+++ Makefile    (working copy)
@@ -1,6 +1,6 @@
 # Makefile for QEMU.
 
-include config-host.mak
+-include config-host.mak
 
 .PHONY: all clean distclean dvi info install install-doc tar tarbin \
        speed test html dvi info
@@ -180,6 +180,15 @@
 dyngen$(EXESUF): dyngen.c
        $(HOST_CC) $(CFLAGS) $(CPPFLAGS) -o $@ $^
 
+config-host.mak: configure
+ifneq ($(wildcard config-host.mak),)
+       @echo $@ is out-of-date, running configure
+       @fgrep "Configured with:" $@ | sed s/.*Configured.with:.// | sh
+else
+       @echo "Please call configure before running make!"
+       @exit 1
+endif
+
 clean:
 # avoid old build problems by removing potentially incorrect old files
        rm -f config.mak config.h op-i386.h opc-i386.h gen-op-i386.h op-arm.h 
opc-arm.h gen-op-arm.h

reply via email to

[Prev in Thread] Current Thread [Next in Thread]