[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-trivial] [PATCH] Makefiles: convert some obj-specific CFLAGS t
From: |
Fam Zheng |
Subject: |
Re: [Qemu-trivial] [PATCH] Makefiles: convert some obj-specific CFLAGS to use new foo.o-cflags syntax |
Date: |
Sun, 4 May 2014 09:45:39 +0800 |
User-agent: |
Mutt/1.5.23 (2014-03-12) |
On Fri, 05/02 15:40, Michael Tokarev wrote:
> Current Makefile system allows using foo.o-cflags variables to store
> object-specific CFLAGS. Convert some usages of old syntax
> (using QEMU_CFLAGS += construct) to the new syntax.
Thanks for doing this! Two minor comments below, but not showstopper,
Reviewed-by: Fam Zheng <address@hidden>
>
> Do not touch multifile modules for now, as build system isn't ready for this.
>
> Signed-off-by: Michael Tokarev <address@hidden>
> ---
> Makefile | 6 ------
> Makefile.objs | 2 ++
> audio/Makefile.objs | 2 +-
> backends/Makefile.objs | 2 +-
> disas/Makefile.objs | 2 +-
> ui/Makefile.objs | 2 +-
> 6 files changed, 6 insertions(+), 10 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index 423e373..0e32b27 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -148,10 +148,6 @@ endif
>
> all: $(DOCS) $(TOOLS) $(HELPERS-y) recurse-all modules
>
> -vl.o: QEMU_CFLAGS+=$(GPROF_CFLAGS)
> -
> -vl.o: QEMU_CFLAGS+=$(SDL_CFLAGS)
> -
> config-host.h: config-host.h-timestamp
> config-host.h-timestamp: config-host.mak
> qemu-options.def: $(SRC_PATH)/qemu-options.hx
> @@ -195,8 +191,6 @@ ALL_SUBDIRS=$(TARGET_DIRS) $(patsubst %,pc-bios/%,
> $(ROMS))
>
> recurse-all: $(SUBDIR_RULES) $(ROMSUBDIR_RULES)
>
> -bt-host.o: QEMU_CFLAGS += $(BLUEZ_CFLAGS)
> -
> $(BUILD_DIR)/version.o: $(SRC_PATH)/version.rc $(BUILD_DIR)/config-host.h |
> $(BUILD_DIR)/version.lo
> $(call quiet-command,$(WINDRES) -I$(BUILD_DIR) -o $@ $<," RC
> version.o")
> $(BUILD_DIR)/version.lo: $(SRC_PATH)/version.rc $(BUILD_DIR)/config-host.h
> diff --git a/Makefile.objs b/Makefile.objs
> index a6e0e2a..f0069ba 100644
> --- a/Makefile.objs
> +++ b/Makefile.objs
> @@ -64,9 +64,11 @@ common-obj-y += hw/
>
> common-obj-y += ui/
> common-obj-y += bt-host.o bt-vhci.o
> +bt-host.o-cflags := $(BLUEZ_CFLAGS)
>
> common-obj-y += dma-helpers.o
> common-obj-y += vl.o
> +vl.o-cflags := $(GPROF_CFLAGS) $(SDL_CFLAGS)
> common-obj-y += tpm.o
>
> common-obj-$(CONFIG_SLIRP) += slirp/
> diff --git a/audio/Makefile.objs b/audio/Makefile.objs
> index d71a877..bdb12c6 100644
> --- a/audio/Makefile.objs
> +++ b/audio/Makefile.objs
> @@ -14,4 +14,4 @@ common-obj-$(CONFIG_AUDIO_WIN_INT) += audio_win_int.o
> common-obj-y += wavcapture.o
>
> $(obj)/audio.o $(obj)/fmodaudio.o: QEMU_CFLAGS += $(FMOD_CFLAGS)
> -$(obj)/sdlaudio.o: QEMU_CFLAGS += $(SDL_CFLAGS)
> +sdlaudio.o-cflags := $(SDL_CFLAGS)
s/ / /
> diff --git a/backends/Makefile.objs b/backends/Makefile.objs
> index 42557d5..bbe8a2d 100644
> --- a/backends/Makefile.objs
> +++ b/backends/Makefile.objs
> @@ -3,6 +3,6 @@ common-obj-$(CONFIG_POSIX) += rng-random.o
>
> common-obj-y += msmouse.o
> common-obj-$(CONFIG_BRLAPI) += baum.o
> -$(obj)/baum.o: QEMU_CFLAGS += $(SDL_CFLAGS)
> +baum.o-cflags := $(SDL_CFLAGS)
Could remove the ending whitespace since you are touch this line.
Thanks,
Fam
>
> common-obj-$(CONFIG_TPM) += tpm.o
> diff --git a/disas/Makefile.objs b/disas/Makefile.objs
> index 41c2374..8dae4da 100644
> --- a/disas/Makefile.objs
> +++ b/disas/Makefile.objs
> @@ -4,7 +4,7 @@ common-obj-$(CONFIG_ARM_DIS) += arm.o
> common-obj-$(CONFIG_ARM_A64_DIS) += arm-a64.o
> common-obj-$(CONFIG_ARM_A64_DIS) += libvixl/
> libvixldir = $(SRC_PATH)/disas/libvixl
> -$(obj)/arm-a64.o: QEMU_CFLAGS += -I$(libvixldir)
> +arm-a64.o-cflags := -I$(libvixldir)
> common-obj-$(CONFIG_CRIS_DIS) += cris.o
> common-obj-$(CONFIG_HPPA_DIS) += hppa.o
> common-obj-$(CONFIG_I386_DIS) += i386.o
> diff --git a/ui/Makefile.objs b/ui/Makefile.objs
> index 6f2294e..4af420b 100644
> --- a/ui/Makefile.objs
> +++ b/ui/Makefile.objs
> @@ -17,4 +17,4 @@ common-obj-$(CONFIG_GTK) += gtk.o x_keymap.o
>
> $(obj)/sdl.o $(obj)/sdl_zoom.o $(obj)/sdl2.o: QEMU_CFLAGS += $(SDL_CFLAGS)
>
> -$(obj)/gtk.o: QEMU_CFLAGS += $(GTK_CFLAGS) $(VTE_CFLAGS)
> +gtk.o-cflags := $(GTK_CFLAGS) $(VTE_CFLAGS)
> --
> 1.7.10.4
>