X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=Makefile;h=c830d7a46c162835399fba2feb187b480e8109ca;hb=5a38cb5940f71254e7dcc4bce7ffca8c2102f0ec;hp=4b72a4ca562f64264bd456f524c323a41f8bda73;hpb=5b66d7ae89411c01657ebfe76b9a8be346a4b1be;p=mirror_qemu.git diff --git a/Makefile b/Makefile index 4b72a4ca56..c830d7a46c 100644 --- a/Makefile +++ b/Makefile @@ -26,6 +26,7 @@ endif CONFIG_SOFTMMU := $(if $(filter %-softmmu,$(TARGET_DIRS)),y) CONFIG_USER_ONLY := $(if $(filter %-user,$(TARGET_DIRS)),y) +CONFIG_XEN := $(CONFIG_XEN_BACKEND) CONFIG_ALL=y -include config-all-devices.mak -include config-all-disas.mak @@ -50,24 +51,24 @@ endif include $(SRC_PATH)/rules.mak -GENERATED_HEADERS = qemu-version.h config-host.h qemu-options.def -GENERATED_HEADERS += qmp-commands.h qapi-types.h qapi-visit.h qapi-event.h -GENERATED_SOURCES += qmp-marshal.c qapi-types.c qapi-visit.c qapi-event.c -GENERATED_HEADERS += qmp-introspect.h -GENERATED_SOURCES += qmp-introspect.c +GENERATED_FILES = qemu-version.h config-host.h qemu-options.def +GENERATED_FILES += qmp-commands.h qapi-types.h qapi-visit.h qapi-event.h +GENERATED_FILES += qmp-marshal.c qapi-types.c qapi-visit.c qapi-event.c +GENERATED_FILES += qmp-introspect.h +GENERATED_FILES += qmp-introspect.c -GENERATED_HEADERS += trace/generated-tcg-tracers.h +GENERATED_FILES += trace/generated-tcg-tracers.h -GENERATED_HEADERS += trace/generated-helpers-wrappers.h -GENERATED_HEADERS += trace/generated-helpers.h -GENERATED_SOURCES += trace/generated-helpers.c +GENERATED_FILES += trace/generated-helpers-wrappers.h +GENERATED_FILES += trace/generated-helpers.h +GENERATED_FILES += trace/generated-helpers.c ifdef CONFIG_TRACE_UST -GENERATED_HEADERS += trace-ust-all.h -GENERATED_SOURCES += trace-ust-all.c +GENERATED_FILES += trace-ust-all.h +GENERATED_FILES += trace-ust-all.c endif -GENERATED_HEADERS += module_block.h +GENERATED_FILES += module_block.h TRACE_HEADERS = trace-root.h $(trace-events-subdirs:%=%/trace.h) TRACE_SOURCES = trace-root.c $(trace-events-subdirs:%=%/trace.c) @@ -80,11 +81,15 @@ ifdef CONFIG_TRACE_UST TRACE_HEADERS += trace-ust-root.h $(trace-events-subdirs:%=%/trace-ust.h) endif -GENERATED_HEADERS += $(TRACE_HEADERS) -GENERATED_SOURCES += $(TRACE_SOURCES) +GENERATED_FILES += $(TRACE_HEADERS) +GENERATED_FILES += $(TRACE_SOURCES) +GENERATED_FILES += $(BUILD_DIR)/trace-events-all trace-group-name = $(shell dirname $1 | sed -e 's/[^a-zA-Z0-9]/_/g') +tracetool-y = $(SRC_PATH)/scripts/tracetool.py +tracetool-y += $(shell find $(SRC_PATH)/scripts/tracetool -name "*.py") + %/trace.h: %/trace.h-timestamp @cmp $< $@ >/dev/null 2>&1 || cp $< $@ %/trace.h-timestamp: $(SRC_PATH)/%/trace-events $(tracetool-y) @@ -299,7 +304,11 @@ qemu-version.h: FORCE printf '""\n'; \ fi; \ fi) > $@.tmp) - $(call quiet-command, cmp -s $@ $@.tmp || mv $@.tmp $@) + $(call quiet-command, if ! cmp -s $@ $@.tmp; then \ + mv $@.tmp $@; \ + else \ + rm $@.tmp; \ + fi) config-host.h: config-host.h-timestamp config-host.h-timestamp: config-host.mak @@ -337,7 +346,7 @@ dtc/%: mkdir -p $@ $(SUBDIR_RULES): libqemuutil.a libqemustub.a $(common-obj-y) $(chardev-obj-y) \ - $(qom-obj-y) $(crypto-aes-obj-$(CONFIG_USER_ONLY)) $(trace-obj-y) + $(qom-obj-y) $(crypto-aes-obj-$(CONFIG_USER_ONLY)) ROMSUBDIR_RULES=$(patsubst %,romsubdir-%, $(ROMS)) # Only keep -O and -g cflags @@ -357,11 +366,11 @@ Makefile: $(version-obj-y) # Build libraries libqemustub.a: $(stub-obj-y) -libqemuutil.a: $(util-obj-y) +libqemuutil.a: $(util-obj-y) $(trace-obj-y) ###################################################################### -COMMON_LDADDS = $(trace-obj-y) libqemuutil.a libqemustub.a +COMMON_LDADDS = libqemuutil.a libqemustub.a qemu-img.o: qemu-img-cmds.h @@ -383,7 +392,6 @@ qemu-ga$(EXESUF): QEMU_CFLAGS += -I qga/qapi-generated gen-out-type = $(subst .,-,$(suffix $@)) qapi-py = $(SRC_PATH)/scripts/qapi.py $(SRC_PATH)/scripts/ordereddict.py -qapi-py += $(SRC_PATH)/scripts/qapi2texi.py qga/qapi-generated/qga-qapi-types.c qga/qapi-generated/qga-qapi-types.h :\ $(SRC_PATH)/qga/qapi-schema.json $(SRC_PATH)/scripts/qapi-types.py $(qapi-py) @@ -481,11 +489,10 @@ clean: rm -f fsdev/*.pod rm -f qemu-img-cmds.h rm -f ui/shader/*-vert.h ui/shader/*-frag.h - @# May not be present in GENERATED_HEADERS + @# May not be present in GENERATED_FILES rm -f trace/generated-tracers-dtrace.dtrace* rm -f trace/generated-tracers-dtrace.h* - rm -f $(foreach f,$(GENERATED_HEADERS),$(f) $(f)-timestamp) - rm -f $(foreach f,$(GENERATED_SOURCES),$(f) $(f)-timestamp) + rm -f $(foreach f,$(GENERATED_FILES),$(f) $(f)-timestamp) rm -rf qapi-generated rm -rf qga/qapi-generated for d in $(ALL_SUBDIRS); do \ @@ -512,7 +519,7 @@ distclean: clean rm -f qemu-doc.vr qemu-doc.txt rm -f config.log rm -f linux-headers/asm - rm -f qemu-ga-qapi.texi qemu-qapi.texi + rm -f docs/qemu-ga-qapi.texi docs/qemu-qmp-qapi.texi docs/version.texi rm -f docs/qemu-qmp-ref.7 docs/qemu-ga-ref.7 rm -f docs/qemu-qmp-ref.txt docs/qemu-ga-ref.txt rm -f docs/qemu-qmp-ref.pdf docs/qemu-ga-ref.pdf @@ -545,7 +552,8 @@ multiboot.bin linuxboot.bin linuxboot_dma.bin kvmvapic.bin \ s390-ccw.img \ spapr-rtas.bin slof.bin skiboot.lid \ palcode-clipper \ -u-boot.e500 +u-boot.e500 \ +qemu_vga.ndrv else BLOBS= endif @@ -589,8 +597,7 @@ endif endif -install: all $(if $(BUILD_DOCS),install-doc) \ -install-datadir install-localstatedir +install: all $(if $(BUILD_DOCS),install-doc) install-datadir install-localstatedir ifneq ($(TOOLS),) $(call install-prog,$(subst qemu-ga,qemu-ga$(EXESUF),$(TOOLS)),$(DESTDIR)$(bindir)) endif @@ -659,8 +666,11 @@ ui/console-gl.o: $(SRC_PATH)/ui/console-gl.c \ # documentation MAKEINFO=makeinfo -MAKEINFOFLAGS=--no-split --number-sections -D 'VERSION $(VERSION)' -TEXIFLAG=$(if $(V),,--quiet) --command='@set VERSION $(VERSION)' +MAKEINFOFLAGS=--no-split --number-sections -I docs +TEXIFLAG=$(if $(V),,--quiet) + +docs/version.texi: $(SRC_PATH)/VERSION + $(call quiet-command,echo "@set VERSION $(VERSION)" > $@,"GEN","$@") %.html: %.texi $(call quiet-command,LC_ALL=C $(MAKEINFO) $(MAKEINFOFLAGS) --no-headers \ @@ -674,7 +684,10 @@ TEXIFLAG=$(if $(V),,--quiet) --command='@set VERSION $(VERSION)' --plaintext $< -o $@,"GEN","$@") %.pdf: %.texi - $(call quiet-command,texi2pdf $(TEXIFLAG) -I $(SRC_PATH) -I . $< -o $@,"GEN","$@") + $(call quiet-command,texi2pdf $(TEXIFLAG) -I $(SRC_PATH) -I docs $< -o $@,"GEN","$@") + +docs/qemu-ga-ref.html docs/qemu-ga-ref.info docs/qemu-ga-ref.txt docs/qemu-ga-ref.pdf docs/qemu-ga-ref.7.pod: docs/version.texi +docs/qemu-qmp-ref.html docs/qemu-qmp-ref.info docs/qemu-qmp-ref.txt docs/qemu-qmp-ref.pdf docs/qemu-qmp-ref.pod: docs/version.texi qemu-options.texi: $(SRC_PATH)/qemu-options.hx $(SRC_PATH)/scripts/hxtool $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -t < $< > $@,"GEN","$@") @@ -688,10 +701,12 @@ qemu-monitor-info.texi: $(SRC_PATH)/hmp-commands-info.hx $(SRC_PATH)/scripts/hxt qemu-img-cmds.texi: $(SRC_PATH)/qemu-img-cmds.hx $(SRC_PATH)/scripts/hxtool $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -t < $< > $@,"GEN","$@") -qemu-qapi.texi: $(qapi-modules) $(qapi-py) +docs/qemu-qmp-qapi.texi docs/qemu-ga-qapi.texi: $(SRC_PATH)/scripts/qapi2texi.py $(qapi-py) + +docs/qemu-qmp-qapi.texi: $(qapi-modules) $(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/qapi2texi.py $< > $@,"GEN","$@") -qemu-ga-qapi.texi: $(SRC_PATH)/qga/qapi-schema.json $(qapi-py) +docs/qemu-ga-qapi.texi: $(SRC_PATH)/qga/qapi-schema.json $(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/qapi2texi.py $< > $@,"GEN","$@") qemu.1: qemu-doc.texi qemu-options.texi qemu-monitor.texi qemu-monitor-info.texi @@ -712,10 +727,10 @@ qemu-doc.html qemu-doc.info qemu-doc.pdf qemu-doc.txt: \ qemu-monitor-info.texi docs/qemu-ga-ref.dvi docs/qemu-ga-ref.html docs/qemu-ga-ref.info docs/qemu-ga-ref.pdf docs/qemu-ga-ref.txt docs/qemu-ga-ref.7: \ -docs/qemu-ga-ref.texi qemu-ga-qapi.texi +docs/qemu-ga-ref.texi docs/qemu-ga-qapi.texi docs/qemu-qmp-ref.dvi docs/qemu-qmp-ref.html docs/qemu-qmp-ref.info docs/qemu-qmp-ref.pdf docs/qemu-qmp-ref.txt docs/qemu-qmp-ref.7: \ -docs/qemu-qmp-ref.texi qemu-qapi.texi +docs/qemu-qmp-ref.texi docs/qemu-qmp-qapi.texi ifdef CONFIG_WIN32 @@ -777,7 +792,7 @@ endif # CONFIG_WIN # Add a dependency on the generated files, so that they are always # rebuilt before other object files ifneq ($(filter-out $(UNCHECKED_GOALS),$(MAKECMDGOALS)),$(if $(MAKECMDGOALS),,fail)) -Makefile: $(GENERATED_HEADERS) +Makefile: $(GENERATED_FILES) endif .SECONDARY: $(TRACE_HEADERS) $(TRACE_HEADERS:%=%-timestamp) \