pbrook | 0cb3fb1 | 2006-05-14 12:07:53 +0000 | [diff] [blame] | 1 | # Makefile for QEMU. |
| 2 | |
Stefan Weil | 519e169 | 2011-09-16 21:50:43 +0200 | [diff] [blame] | 3 | # Always point to the root of the build tree (needs GNU make). |
| 4 | BUILD_DIR=$(CURDIR) |
Lluís Vilanova | 388d475 | 2011-09-15 22:45:35 +0200 | [diff] [blame] | 5 | |
Fam Zheng | eaa2ddb | 2015-05-22 13:35:07 +0800 | [diff] [blame] | 6 | # Before including a proper config-host.mak, assume we are in the source tree |
| 7 | SRC_PATH=. |
| 8 | |
Fam Zheng | 324027c | 2016-06-01 12:25:17 +0800 | [diff] [blame] | 9 | UNCHECKED_GOALS := %clean TAGS cscope ctags docker docker-% |
Fam Zheng | eaa2ddb | 2015-05-22 13:35:07 +0800 | [diff] [blame] | 10 | |
Lluís Vilanova | 250b086 | 2012-03-06 19:50:38 +0100 | [diff] [blame] | 11 | # All following code might depend on configuration variables |
aurel32 | 55d7e8f | 2009-04-15 14:42:57 +0000 | [diff] [blame] | 12 | ifneq ($(wildcard config-host.mak),) |
Paul Brook | 1ad2134 | 2009-05-19 16:17:58 +0100 | [diff] [blame] | 13 | # Put the all: rule here so that config-host.mak can contain dependencies. |
Stefan Weil | 8f67aa8 | 2012-07-09 20:36:36 +0200 | [diff] [blame] | 14 | all: |
pbrook | ad06484 | 2006-04-16 12:41:07 +0000 | [diff] [blame] | 15 | include config-host.mak |
Peter Maydell | d1bd242 | 2012-10-19 14:54:23 +0100 | [diff] [blame] | 16 | |
| 17 | # Check that we're not trying to do an out-of-tree build from |
| 18 | # a tree that's been used for an in-tree build. |
| 19 | ifneq ($(realpath $(SRC_PATH)),$(realpath .)) |
| 20 | ifneq ($(wildcard $(SRC_PATH)/config-host.mak),) |
| 21 | $(error This is an out of tree build but your source tree ($(SRC_PATH)) \ |
| 22 | seems to have been used for an in-tree build. You can fix this by running \ |
| 23 | "make distclean && rm -rf *-linux-user *-softmmu" in your source tree) |
| 24 | endif |
| 25 | endif |
| 26 | |
Paolo Bonzini | f3aa844 | 2013-04-16 10:50:38 +0200 | [diff] [blame] | 27 | CONFIG_SOFTMMU := $(if $(filter %-softmmu,$(TARGET_DIRS)),y) |
| 28 | CONFIG_USER_ONLY := $(if $(filter %-user,$(TARGET_DIRS)),y) |
| 29 | CONFIG_ALL=y |
| 30 | -include config-all-devices.mak |
| 31 | -include config-all-disas.mak |
| 32 | |
Paolo Bonzini | 59bc10e | 2010-01-04 11:02:28 +0100 | [diff] [blame] | 33 | config-host.mak: $(SRC_PATH)/configure |
Juan Quintela | e5efe7f | 2009-10-07 02:40:59 +0200 | [diff] [blame] | 34 | @echo $@ is out-of-date, running configure |
Stefan Weil | bdf523e | 2013-10-20 18:39:21 +0200 | [diff] [blame] | 35 | @# TODO: The next lines include code which supports a smooth |
| 36 | @# transition from old configurations without config.status. |
| 37 | @# This code can be removed after QEMU 1.7. |
| 38 | @if test -x config.status; then \ |
| 39 | ./config.status; \ |
| 40 | else \ |
| 41 | sed -n "/.*Configured with/s/[^:]*: //p" $@ | sh; \ |
| 42 | fi |
aurel32 | 55d7e8f | 2009-04-15 14:42:57 +0000 | [diff] [blame] | 43 | else |
| 44 | config-host.mak: |
Fam Zheng | eaa2ddb | 2015-05-22 13:35:07 +0800 | [diff] [blame] | 45 | ifneq ($(filter-out $(UNCHECKED_GOALS),$(MAKECMDGOALS)),$(if $(MAKECMDGOALS),,fail)) |
aurel32 | 55d7e8f | 2009-04-15 14:42:57 +0000 | [diff] [blame] | 46 | @echo "Please call configure before running make!" |
| 47 | @exit 1 |
| 48 | endif |
Mike Frysinger | 7748b8c | 2012-09-16 16:07:13 -0400 | [diff] [blame] | 49 | endif |
bellard | 766a487 | 2003-02-18 23:35:48 +0000 | [diff] [blame] | 50 | |
Fam Zheng | fb57c88 | 2016-06-01 12:25:16 +0800 | [diff] [blame] | 51 | include $(SRC_PATH)/rules.mak |
| 52 | |
Fam Zheng | 67a1de0 | 2016-06-01 17:44:21 +0800 | [diff] [blame] | 53 | GENERATED_HEADERS = qemu-version.h config-host.h qemu-options.def |
Wenchao Xia | 21cd70d | 2014-06-18 08:43:28 +0200 | [diff] [blame] | 54 | GENERATED_HEADERS += qmp-commands.h qapi-types.h qapi-visit.h qapi-event.h |
| 55 | GENERATED_SOURCES += qmp-marshal.c qapi-types.c qapi-visit.c qapi-event.c |
Markus Armbruster | 39a1815 | 2015-09-16 13:06:28 +0200 | [diff] [blame] | 56 | GENERATED_HEADERS += qmp-introspect.h |
| 57 | GENERATED_SOURCES += qmp-introspect.c |
Lluís Vilanova | eac236e | 2012-12-14 20:13:09 +0100 | [diff] [blame] | 58 | |
Lluís Vilanova | 45be2f5 | 2013-03-05 14:47:32 +0100 | [diff] [blame] | 59 | GENERATED_HEADERS += trace/generated-events.h |
| 60 | GENERATED_SOURCES += trace/generated-events.c |
| 61 | |
Lluís Vilanova | eac236e | 2012-12-14 20:13:09 +0100 | [diff] [blame] | 62 | GENERATED_HEADERS += trace/generated-tracers.h |
Lluís Vilanova | 5b80827 | 2014-05-27 15:02:14 +0200 | [diff] [blame] | 63 | ifeq ($(findstring dtrace,$(TRACE_BACKENDS)),dtrace) |
Lluís Vilanova | eac236e | 2012-12-14 20:13:09 +0100 | [diff] [blame] | 64 | GENERATED_HEADERS += trace/generated-tracers-dtrace.h |
| 65 | endif |
| 66 | GENERATED_SOURCES += trace/generated-tracers.c |
Lluís Vilanova | 250b086 | 2012-03-06 19:50:38 +0100 | [diff] [blame] | 67 | |
Lluís Vilanova | 465830f | 2014-05-30 14:12:13 +0200 | [diff] [blame] | 68 | GENERATED_HEADERS += trace/generated-tcg-tracers.h |
| 69 | |
Lluís Vilanova | f465422 | 2014-05-30 14:12:01 +0200 | [diff] [blame] | 70 | GENERATED_HEADERS += trace/generated-helpers-wrappers.h |
Lluís Vilanova | 707c8a9 | 2014-05-30 14:11:50 +0200 | [diff] [blame] | 71 | GENERATED_HEADERS += trace/generated-helpers.h |
Lluís Vilanova | 341ea69 | 2014-05-30 14:11:56 +0200 | [diff] [blame] | 72 | GENERATED_SOURCES += trace/generated-helpers.c |
Lluís Vilanova | 707c8a9 | 2014-05-30 14:11:50 +0200 | [diff] [blame] | 73 | |
Lluís Vilanova | 5b80827 | 2014-05-27 15:02:14 +0200 | [diff] [blame] | 74 | ifeq ($(findstring ust,$(TRACE_BACKENDS)),ust) |
Mohamad Gebai | e6bf23f | 2014-01-29 22:47:56 -0500 | [diff] [blame] | 75 | GENERATED_HEADERS += trace/generated-ust-provider.h |
| 76 | GENERATED_SOURCES += trace/generated-ust.c |
| 77 | endif |
| 78 | |
Juan Quintela | d9ace8b | 2009-10-06 21:11:15 +0200 | [diff] [blame] | 79 | # Don't try to regenerate Makefile or configure |
| 80 | # We don't generate any of them |
| 81 | Makefile: ; |
| 82 | configure: ; |
| 83 | |
aliguori | 818220f | 2008-09-24 01:13:40 +0000 | [diff] [blame] | 84 | .PHONY: all clean cscope distclean dvi html info install install-doc \ |
Fam Zheng | d41d4da | 2016-06-01 17:44:20 +0800 | [diff] [blame] | 85 | pdf recurse-all speed test dist msi FORCE |
pbrook | 0cb3fb1 | 2006-05-14 12:07:53 +0000 | [diff] [blame] | 86 | |
Paolo Bonzini | fec90ff | 2012-05-29 11:49:50 +0200 | [diff] [blame] | 87 | $(call set-vpath, $(SRC_PATH)) |
pbrook | 8c462f8 | 2007-11-18 21:12:37 +0000 | [diff] [blame] | 88 | |
Juan Quintela | 3e2e0e6 | 2009-08-03 14:47:06 +0200 | [diff] [blame] | 89 | LIBS+=-lz $(LIBS_TOOLS) |
Juan Quintela | 67c0f08 | 2009-07-27 16:12:51 +0200 | [diff] [blame] | 90 | |
Corey Bryant | 7b93fad | 2012-01-26 09:42:24 -0500 | [diff] [blame] | 91 | HELPERS-$(CONFIG_LINUX) = qemu-bridge-helper$(EXESUF) |
| 92 | |
pbrook | cc8ae6d | 2006-04-23 17:57:59 +0000 | [diff] [blame] | 93 | ifdef BUILD_DOCS |
Marc-André Lureau | 665b5d0 | 2015-08-27 01:34:59 +0200 | [diff] [blame] | 94 | DOCS=qemu-doc.html qemu-tech.html qemu.1 qemu-img.1 qemu-nbd.8 qemu-ga.8 |
| 95 | DOCS+=qmp-commands.txt |
Meador Inge | 983eef5 | 2012-02-24 14:00:42 +0530 | [diff] [blame] | 96 | ifdef CONFIG_VIRTFS |
M. Mohan Kumar | a2d8f1b | 2011-12-14 13:58:47 +0530 | [diff] [blame] | 97 | DOCS+=fsdev/virtfs-proxy-helper.1 |
Meador Inge | 983eef5 | 2012-02-24 14:00:42 +0530 | [diff] [blame] | 98 | endif |
pbrook | cc8ae6d | 2006-04-23 17:57:59 +0000 | [diff] [blame] | 99 | else |
| 100 | DOCS= |
| 101 | endif |
bellard | 7d13299 | 2003-03-06 23:23:54 +0000 | [diff] [blame] | 102 | |
Lluís Vilanova | 388d475 | 2011-09-15 22:45:35 +0200 | [diff] [blame] | 103 | SUBDIR_MAKEFLAGS=$(if $(V),,--no-print-directory) BUILD_DIR=$(BUILD_DIR) |
Juan Quintela | 1f3d3c8 | 2009-10-07 02:41:02 +0200 | [diff] [blame] | 104 | SUBDIR_DEVICES_MAK=$(patsubst %, %/config-devices.mak, $(TARGET_DIRS)) |
Andreas Färber | 8807080 | 2013-02-21 16:26:46 +0100 | [diff] [blame] | 105 | SUBDIR_DEVICES_MAK_DEP=$(patsubst %, %-config-devices.mak.d, $(TARGET_DIRS)) |
Juan Quintela | 1f3d3c8 | 2009-10-07 02:41:02 +0200 | [diff] [blame] | 106 | |
Stefan Weil | 8bdd3d4 | 2012-09-14 19:02:30 +0200 | [diff] [blame] | 107 | ifeq ($(SUBDIR_DEVICES_MAK),) |
| 108 | config-all-devices.mak: |
| 109 | $(call quiet-command,echo '# no devices' > $@," GEN $@") |
| 110 | else |
Juan Quintela | 1f3d3c8 | 2009-10-07 02:41:02 +0200 | [diff] [blame] | 111 | config-all-devices.mak: $(SUBDIR_DEVICES_MAK) |
Paolo Bonzini | bb585a7 | 2013-04-03 17:53:21 +0200 | [diff] [blame] | 112 | $(call quiet-command, sed -n \ |
| 113 | 's|^\([^=]*\)=\(.*\)$$|\1:=$$(findstring y,$$(\1)\2)|p' \ |
| 114 | $(SUBDIR_DEVICES_MAK) | sort -u > $@, \ |
| 115 | " GEN $@") |
Stefan Weil | 8bdd3d4 | 2012-09-14 19:02:30 +0200 | [diff] [blame] | 116 | endif |
Juan Quintela | 1f3d3c8 | 2009-10-07 02:41:02 +0200 | [diff] [blame] | 117 | |
Paul Brook | bd9141b | 2010-11-26 18:47:45 +0000 | [diff] [blame] | 118 | -include $(SUBDIR_DEVICES_MAK_DEP) |
| 119 | |
Paolo Bonzini | 0ab0c99 | 2016-06-07 13:25:58 +0200 | [diff] [blame] | 120 | %/config-devices.mak: default-configs/%.mak $(SRC_PATH)/scripts/make_device_config.sh |
Paolo Bonzini | 15564d8 | 2015-03-12 16:00:05 +0100 | [diff] [blame] | 121 | $(call quiet-command, \ |
| 122 | $(SHELL) $(SRC_PATH)/scripts/make_device_config.sh $< $*-config-devices.mak.d $@ > $@.tmp, " GEN $@.tmp") |
Michael S. Tsirkin | 12ccfec | 2015-02-19 08:48:46 +0100 | [diff] [blame] | 123 | $(call quiet-command, if test -f $@; then \ |
Blue Swirl | 904fe1f | 2010-10-02 14:28:08 +0000 | [diff] [blame] | 124 | if cmp -s $@.old $@; then \ |
Paul Brook | bd9141b | 2010-11-26 18:47:45 +0000 | [diff] [blame] | 125 | mv $@.tmp $@; \ |
| 126 | cp -p $@ $@.old; \ |
Stefan Weil | 012f087 | 2009-12-20 15:39:03 +0100 | [diff] [blame] | 127 | else \ |
| 128 | if test -f $@.old; then \ |
| 129 | echo "WARNING: $@ (user modified) out of date.";\ |
| 130 | else \ |
| 131 | echo "WARNING: $@ out of date.";\ |
| 132 | fi; \ |
| 133 | echo "Run \"make defconfig\" to regenerate."; \ |
| 134 | rm $@.tmp; \ |
| 135 | fi; \ |
Paul Brook | a992fe3 | 2009-11-22 16:25:30 +0000 | [diff] [blame] | 136 | else \ |
Stefan Weil | 012f087 | 2009-12-20 15:39:03 +0100 | [diff] [blame] | 137 | mv $@.tmp $@; \ |
| 138 | cp -p $@ $@.old; \ |
Stefan Weil | f6288b9 | 2015-07-18 16:54:32 +0200 | [diff] [blame] | 139 | fi, " GEN $@"); |
Paul Brook | a992fe3 | 2009-11-22 16:25:30 +0000 | [diff] [blame] | 140 | |
| 141 | defconfig: |
| 142 | rm -f config-all-devices.mak $(SUBDIR_DEVICES_MAK) |
| 143 | |
Paolo Bonzini | 992aeb8 | 2012-12-21 08:34:49 +0100 | [diff] [blame] | 144 | ifneq ($(wildcard config-host.mak),) |
| 145 | include $(SRC_PATH)/Makefile.objs |
Fam Zheng | ba1183d | 2014-02-10 14:48:52 +0800 | [diff] [blame] | 146 | endif |
| 147 | |
| 148 | dummy := $(call unnest-vars,, \ |
| 149 | stub-obj-y \ |
| 150 | util-obj-y \ |
| 151 | qga-obj-y \ |
David Marchand | a75eb03 | 2014-09-08 11:17:48 +0200 | [diff] [blame] | 152 | ivshmem-client-obj-y \ |
| 153 | ivshmem-server-obj-y \ |
Tomoki Sekiyama | 577a672 | 2014-03-26 14:28:45 -0400 | [diff] [blame] | 154 | qga-vss-dll-obj-y \ |
Fam Zheng | ba1183d | 2014-02-10 14:48:52 +0800 | [diff] [blame] | 155 | block-obj-y \ |
Fam Zheng | cc47569 | 2014-02-10 14:48:59 +0800 | [diff] [blame] | 156 | block-obj-m \ |
Daniel P. Berrange | fb37726 | 2015-09-02 10:57:27 +0100 | [diff] [blame] | 157 | crypto-obj-y \ |
| 158 | crypto-aes-obj-y \ |
Daniel P. Berrange | 0c7012e | 2015-09-02 11:18:16 +0100 | [diff] [blame] | 159 | qom-obj-y \ |
Daniel P. Berrange | 666a3af | 2015-02-27 16:19:33 +0000 | [diff] [blame] | 160 | io-obj-y \ |
Fam Zheng | cc47569 | 2014-02-10 14:48:59 +0800 | [diff] [blame] | 161 | common-obj-y \ |
| 162 | common-obj-m) |
Fam Zheng | ba1183d | 2014-02-10 14:48:52 +0800 | [diff] [blame] | 163 | |
| 164 | ifneq ($(wildcard config-host.mak),) |
Fam Zheng | 46e7b70 | 2016-06-01 10:23:31 +0800 | [diff] [blame] | 165 | include $(SRC_PATH)/tests/Makefile.include |
Paolo Bonzini | 992aeb8 | 2012-12-21 08:34:49 +0100 | [diff] [blame] | 166 | endif |
Paolo Bonzini | 992aeb8 | 2012-12-21 08:34:49 +0100 | [diff] [blame] | 167 | |
Fam Zheng | 1796926 | 2014-02-10 14:48:56 +0800 | [diff] [blame] | 168 | all: $(DOCS) $(TOOLS) $(HELPERS-y) recurse-all modules |
pbrook | b9dea4f | 2006-05-13 16:54:03 +0000 | [diff] [blame] | 169 | |
Fam Zheng | 67a1de0 | 2016-06-01 17:44:21 +0800 | [diff] [blame] | 170 | qemu-version.h: FORCE |
| 171 | $(call quiet-command, \ |
| 172 | (cd $(SRC_PATH); \ |
| 173 | printf '#define QEMU_PKGVERSION '; \ |
| 174 | if test -n "$(PKGVERSION)"; then \ |
| 175 | printf '"$(PKGVERSION)"\n'; \ |
| 176 | else \ |
| 177 | if test -d .git; then \ |
| 178 | printf '" ('; \ |
| 179 | git describe --match 'v*' 2>/dev/null | tr -d '\n'; \ |
| 180 | if ! git diff-index --quiet HEAD &>/dev/null; then \ |
| 181 | printf -- '-dirty'; \ |
| 182 | fi; \ |
| 183 | printf ')"\n'; \ |
| 184 | else \ |
| 185 | printf '""\n'; \ |
| 186 | fi; \ |
| 187 | fi) > $@.tmp) |
| 188 | $(call quiet-command, cmp --quiet $@ $@.tmp || mv $@.tmp $@) |
| 189 | |
Juan Quintela | 1215c6e | 2009-10-07 02:40:58 +0200 | [diff] [blame] | 190 | config-host.h: config-host.h-timestamp |
| 191 | config-host.h-timestamp: config-host.mak |
Paolo Bonzini | 077de81 | 2016-06-07 13:27:04 +0200 | [diff] [blame] | 192 | qemu-options.def: $(SRC_PATH)/qemu-options.hx $(SRC_PATH)/scripts/hxtool |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 193 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -h < $< > $@," GEN $@") |
Juan Quintela | 1215c6e | 2009-10-07 02:40:58 +0200 | [diff] [blame] | 194 | |
pbrook | cec7d0b | 2008-05-28 16:44:57 +0000 | [diff] [blame] | 195 | SUBDIR_RULES=$(patsubst %,subdir-%, $(TARGET_DIRS)) |
Andreas Färber | 916359f | 2013-02-21 16:26:47 +0100 | [diff] [blame] | 196 | SOFTMMU_SUBDIR_RULES=$(filter %-softmmu,$(SUBDIR_RULES)) |
| 197 | |
Stefan Weil | 57f45b6 | 2014-02-27 21:28:03 +0100 | [diff] [blame] | 198 | $(SOFTMMU_SUBDIR_RULES): $(block-obj-y) |
Daniel P. Berrange | fb37726 | 2015-09-02 10:57:27 +0100 | [diff] [blame] | 199 | $(SOFTMMU_SUBDIR_RULES): $(crypto-obj-y) |
Daniel P. Berrange | 666a3af | 2015-02-27 16:19:33 +0000 | [diff] [blame] | 200 | $(SOFTMMU_SUBDIR_RULES): $(io-obj-y) |
Andreas Färber | 916359f | 2013-02-21 16:26:47 +0100 | [diff] [blame] | 201 | $(SOFTMMU_SUBDIR_RULES): config-all-devices.mak |
pbrook | cec7d0b | 2008-05-28 16:44:57 +0000 | [diff] [blame] | 202 | |
Paolo Bonzini | 4115852 | 2012-05-29 12:41:34 +0200 | [diff] [blame] | 203 | subdir-%: |
Paul Brook | 0087375 | 2009-05-07 02:00:31 +0100 | [diff] [blame] | 204 | $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C $* V="$(V)" TARGET_DIR="$*/" all,) |
pbrook | 4aa4253 | 2006-05-13 13:55:08 +0000 | [diff] [blame] | 205 | |
Gerd Hoffmann | e2134eb | 2012-09-25 16:04:58 +0200 | [diff] [blame] | 206 | subdir-pixman: pixman/Makefile |
| 207 | $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C pixman V="$(V)" all,) |
| 208 | |
| 209 | pixman/Makefile: $(SRC_PATH)/pixman/configure |
Gerd Hoffmann | f9943cd | 2013-01-04 10:15:53 +0100 | [diff] [blame] | 210 | (cd pixman; CFLAGS="$(CFLAGS) -fPIC $(extra_cflags) $(extra_ldflags)" $(SRC_PATH)/pixman/configure $(AUTOCONF_HOST) --disable-gtk --disable-shared --enable-static) |
Gerd Hoffmann | e2134eb | 2012-09-25 16:04:58 +0200 | [diff] [blame] | 211 | |
| 212 | $(SRC_PATH)/pixman/configure: |
| 213 | (cd $(SRC_PATH)/pixman; autoreconf -v --install) |
| 214 | |
Peter Crosthwaite | a540f15 | 2013-04-18 14:47:31 +1000 | [diff] [blame] | 215 | DTC_MAKE_ARGS=-I$(SRC_PATH)/dtc VPATH=$(SRC_PATH)/dtc -C dtc V="$(V)" LIBFDT_srcdir=$(SRC_PATH)/dtc/libfdt |
Peter Maydell | 965f486 | 2013-06-21 14:00:17 +0100 | [diff] [blame] | 216 | DTC_CFLAGS=$(CFLAGS) $(QEMU_CFLAGS) |
| 217 | DTC_CPPFLAGS=-I$(BUILD_DIR)/dtc -I$(SRC_PATH)/dtc -I$(SRC_PATH)/dtc/libfdt |
Peter Crosthwaite | a540f15 | 2013-04-18 14:47:31 +1000 | [diff] [blame] | 218 | |
| 219 | subdir-dtc:dtc/libfdt dtc/tests |
Peter Maydell | 965f486 | 2013-06-21 14:00:17 +0100 | [diff] [blame] | 220 | $(call quiet-command,$(MAKE) $(DTC_MAKE_ARGS) CPPFLAGS="$(DTC_CPPFLAGS)" CFLAGS="$(DTC_CFLAGS)" LDFLAGS="$(LDFLAGS)" ARFLAGS="$(ARFLAGS)" CC="$(CC)" AR="$(AR)" LD="$(LD)" $(SUBDIR_MAKEFLAGS) libfdt/libfdt.a,) |
Peter Crosthwaite | a540f15 | 2013-04-18 14:47:31 +1000 | [diff] [blame] | 221 | |
| 222 | dtc/%: |
| 223 | mkdir -p $@ |
| 224 | |
Daniel P. Berrange | 57f5462 | 2015-09-18 11:01:35 +0100 | [diff] [blame] | 225 | $(SUBDIR_RULES): libqemuutil.a libqemustub.a $(common-obj-y) $(qom-obj-y) $(crypto-aes-obj-$(CONFIG_USER_ONLY)) |
Blue Swirl | add1615 | 2009-09-27 16:26:02 +0000 | [diff] [blame] | 226 | |
Paul Brook | c05ac89 | 2009-07-31 13:18:32 +0100 | [diff] [blame] | 227 | ROMSUBDIR_RULES=$(patsubst %,romsubdir-%, $(ROMS)) |
| 228 | romsubdir-%: |
| 229 | $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C pc-bios/$* V="$(V)" TARGET_DIR="$*/",) |
| 230 | |
| 231 | ALL_SUBDIRS=$(TARGET_DIRS) $(patsubst %,pc-bios/%, $(ROMS)) |
| 232 | |
| 233 | recurse-all: $(SUBDIR_RULES) $(ROMSUBDIR_RULES) |
bellard | 83f6409 | 2006-08-01 16:21:11 +0000 | [diff] [blame] | 234 | |
Vasily Efimov | 23cab7b | 2015-02-18 15:59:37 +0300 | [diff] [blame] | 235 | $(BUILD_DIR)/version.o: $(SRC_PATH)/version.rc config-host.h | $(BUILD_DIR)/version.lo |
Stefan Weil | 7e75e33 | 2013-08-16 21:51:53 +0200 | [diff] [blame] | 236 | $(call quiet-command,$(WINDRES) -I$(BUILD_DIR) -o $@ $<," RC version.o") |
Vasily Efimov | 23cab7b | 2015-02-18 15:59:37 +0300 | [diff] [blame] | 237 | $(BUILD_DIR)/version.lo: $(SRC_PATH)/version.rc config-host.h |
Stefan Weil | 7e75e33 | 2013-08-16 21:51:53 +0200 | [diff] [blame] | 238 | $(call quiet-command,$(WINDRES) -I$(BUILD_DIR) -o $@ $<," RC version.lo") |
Marc-André Lureau | 5354e4d | 2013-02-25 23:31:13 +0100 | [diff] [blame] | 239 | |
Paolo Bonzini | fba90ac | 2013-05-01 18:30:15 +0200 | [diff] [blame] | 240 | Makefile: $(version-obj-y) $(version-lobj-y) |
Paolo Bonzini | 3bc2f57 | 2012-11-16 18:35:27 +0100 | [diff] [blame] | 241 | |
| 242 | ###################################################################### |
Paolo Bonzini | 8a09070 | 2012-12-20 15:40:20 +0100 | [diff] [blame] | 243 | # Build libraries |
Paolo Bonzini | 3bc2f57 | 2012-11-16 18:35:27 +0100 | [diff] [blame] | 244 | |
| 245 | libqemustub.a: $(stub-obj-y) |
Fam Zheng | 169a24a | 2014-08-07 10:34:41 +0800 | [diff] [blame] | 246 | libqemuutil.a: $(util-obj-y) |
Paolo Bonzini | 3bc2f57 | 2012-11-16 18:35:27 +0100 | [diff] [blame] | 247 | |
Fam Zheng | e26110c | 2014-02-10 14:48:57 +0800 | [diff] [blame] | 248 | block-modules = $(foreach o,$(block-obj-m),"$(basename $(subst /,-,$o))",) NULL |
| 249 | util/module.o-cflags = -D'CONFIG_BLOCK_MODULES=$(block-modules)' |
| 250 | |
bellard | 4fb240a | 2007-11-07 19:24:02 +0000 | [diff] [blame] | 251 | ###################################################################### |
| 252 | |
Juan Quintela | 3c089e1 | 2010-01-20 20:54:18 +0100 | [diff] [blame] | 253 | qemu-img.o: qemu-img-cmds.h |
Stuart Brady | 153859b | 2009-06-07 00:42:17 +0100 | [diff] [blame] | 254 | |
Daniel P. Berrange | 064097d | 2016-02-10 18:41:01 +0000 | [diff] [blame] | 255 | qemu-img$(EXESUF): qemu-img.o $(block-obj-y) $(crypto-obj-y) $(io-obj-y) $(qom-obj-y) libqemuutil.a libqemustub.a |
| 256 | qemu-nbd$(EXESUF): qemu-nbd.o $(block-obj-y) $(crypto-obj-y) $(io-obj-y) $(qom-obj-y) libqemuutil.a libqemustub.a |
| 257 | qemu-io$(EXESUF): qemu-io.o $(block-obj-y) $(crypto-obj-y) $(io-obj-y) $(qom-obj-y) libqemuutil.a libqemustub.a |
aliguori | 0a8e1ac | 2009-04-05 18:41:23 +0000 | [diff] [blame] | 258 | |
Daniel P. Berrange | a2d96af | 2016-03-07 20:25:19 +0000 | [diff] [blame] | 259 | qemu-bridge-helper$(EXESUF): qemu-bridge-helper.o libqemuutil.a libqemustub.a |
Corey Bryant | 7b93fad | 2012-01-26 09:42:24 -0500 | [diff] [blame] | 260 | |
Wei Liu | 2209bd0 | 2015-11-30 16:14:29 +0000 | [diff] [blame] | 261 | fsdev/virtfs-proxy-helper$(EXESUF): fsdev/virtfs-proxy-helper.o fsdev/9p-marshal.o fsdev/9p-iov-marshal.o libqemuutil.a libqemustub.a |
M. Mohan Kumar | 17bff52 | 2011-12-14 13:58:42 +0530 | [diff] [blame] | 262 | fsdev/virtfs-proxy-helper$(EXESUF): LIBS += -lcap |
| 263 | |
Paolo Bonzini | 077de81 | 2016-06-07 13:27:04 +0200 | [diff] [blame] | 264 | qemu-img-cmds.h: $(SRC_PATH)/qemu-img-cmds.hx $(SRC_PATH)/scripts/hxtool |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 265 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -h < $< > $@," GEN $@") |
Stuart Brady | 153859b | 2009-06-07 00:42:17 +0100 | [diff] [blame] | 266 | |
Michael Roth | 957f1f9 | 2011-08-11 15:38:12 -0500 | [diff] [blame] | 267 | qemu-ga$(EXESUF): LIBS = $(LIBS_QGA) |
Dunrong Huang | 54c2e50 | 2012-07-29 03:11:24 +0800 | [diff] [blame] | 268 | qemu-ga$(EXESUF): QEMU_CFLAGS += -I qga/qapi-generated |
Michael Roth | 640e540 | 2011-07-19 14:50:44 -0500 | [diff] [blame] | 269 | |
Avi Kivity | 19bf7c8 | 2011-12-28 12:26:58 +0200 | [diff] [blame] | 270 | gen-out-type = $(subst .,-,$(suffix $@)) |
Avi Kivity | 8d3bc51 | 2011-12-27 16:02:16 +0200 | [diff] [blame] | 271 | |
Stefan Hajnoczi | 0521d37 | 2012-08-10 14:08:42 +0100 | [diff] [blame] | 272 | qapi-py = $(SRC_PATH)/scripts/qapi.py $(SRC_PATH)/scripts/ordereddict.py |
| 273 | |
Dunrong Huang | 54c2e50 | 2012-07-29 03:11:24 +0800 | [diff] [blame] | 274 | qga/qapi-generated/qga-qapi-types.c qga/qapi-generated/qga-qapi-types.h :\ |
Paolo Bonzini | 2870dc3 | 2012-10-24 11:26:49 +0200 | [diff] [blame] | 275 | $(SRC_PATH)/qga/qapi-schema.json $(SRC_PATH)/scripts/qapi-types.py $(qapi-py) |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 276 | $(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/qapi-types.py \ |
Markus Armbruster | 16d80f6 | 2015-04-02 13:32:16 +0200 | [diff] [blame] | 277 | $(gen-out-type) -o qga/qapi-generated -p "qga-" $<, \ |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 278 | " GEN $@") |
Dunrong Huang | 54c2e50 | 2012-07-29 03:11:24 +0800 | [diff] [blame] | 279 | qga/qapi-generated/qga-qapi-visit.c qga/qapi-generated/qga-qapi-visit.h :\ |
Paolo Bonzini | 2870dc3 | 2012-10-24 11:26:49 +0200 | [diff] [blame] | 280 | $(SRC_PATH)/qga/qapi-schema.json $(SRC_PATH)/scripts/qapi-visit.py $(qapi-py) |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 281 | $(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/qapi-visit.py \ |
Markus Armbruster | 16d80f6 | 2015-04-02 13:32:16 +0200 | [diff] [blame] | 282 | $(gen-out-type) -o qga/qapi-generated -p "qga-" $<, \ |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 283 | " GEN $@") |
Dunrong Huang | 54c2e50 | 2012-07-29 03:11:24 +0800 | [diff] [blame] | 284 | qga/qapi-generated/qga-qmp-commands.h qga/qapi-generated/qga-qmp-marshal.c :\ |
Paolo Bonzini | 2870dc3 | 2012-10-24 11:26:49 +0200 | [diff] [blame] | 285 | $(SRC_PATH)/qga/qapi-schema.json $(SRC_PATH)/scripts/qapi-commands.py $(qapi-py) |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 286 | $(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/qapi-commands.py \ |
Markus Armbruster | 16d80f6 | 2015-04-02 13:32:16 +0200 | [diff] [blame] | 287 | $(gen-out-type) -o qga/qapi-generated -p "qga-" $<, \ |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 288 | " GEN $@") |
Michael Roth | e3d4d25 | 2011-07-19 15:41:55 -0500 | [diff] [blame] | 289 | |
Max Reitz | be13d46 | 2014-06-18 08:43:26 +0200 | [diff] [blame] | 290 | qapi-modules = $(SRC_PATH)/qapi-schema.json $(SRC_PATH)/qapi/common.json \ |
Wenchao Xia | f668470 | 2014-06-18 08:43:32 +0200 | [diff] [blame] | 291 | $(SRC_PATH)/qapi/block.json $(SRC_PATH)/qapi/block-core.json \ |
Daniel P. Berrange | 48befbc | 2015-11-19 17:18:39 +0000 | [diff] [blame] | 292 | $(SRC_PATH)/qapi/event.json $(SRC_PATH)/qapi/introspect.json \ |
Lluís Vilanova | 423aeaf | 2016-02-04 19:29:17 +0100 | [diff] [blame] | 293 | $(SRC_PATH)/qapi/crypto.json $(SRC_PATH)/qapi/rocker.json \ |
| 294 | $(SRC_PATH)/qapi/trace.json |
Max Reitz | be13d46 | 2014-06-18 08:43:26 +0200 | [diff] [blame] | 295 | |
Michael S. Tsirkin | 599825c | 2011-11-16 23:58:18 +0200 | [diff] [blame] | 296 | qapi-types.c qapi-types.h :\ |
Max Reitz | be13d46 | 2014-06-18 08:43:26 +0200 | [diff] [blame] | 297 | $(qapi-modules) $(SRC_PATH)/scripts/qapi-types.py $(qapi-py) |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 298 | $(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/qapi-types.py \ |
Markus Armbruster | 16d80f6 | 2015-04-02 13:32:16 +0200 | [diff] [blame] | 299 | $(gen-out-type) -o "." -b $<, \ |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 300 | " GEN $@") |
Michael S. Tsirkin | 599825c | 2011-11-16 23:58:18 +0200 | [diff] [blame] | 301 | qapi-visit.c qapi-visit.h :\ |
Max Reitz | be13d46 | 2014-06-18 08:43:26 +0200 | [diff] [blame] | 302 | $(qapi-modules) $(SRC_PATH)/scripts/qapi-visit.py $(qapi-py) |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 303 | $(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/qapi-visit.py \ |
Markus Armbruster | 16d80f6 | 2015-04-02 13:32:16 +0200 | [diff] [blame] | 304 | $(gen-out-type) -o "." -b $<, \ |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 305 | " GEN $@") |
Wenchao Xia | 21cd70d | 2014-06-18 08:43:28 +0200 | [diff] [blame] | 306 | qapi-event.c qapi-event.h :\ |
| 307 | $(qapi-modules) $(SRC_PATH)/scripts/qapi-event.py $(qapi-py) |
| 308 | $(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/qapi-event.py \ |
Markus Armbruster | 16d80f6 | 2015-04-02 13:32:16 +0200 | [diff] [blame] | 309 | $(gen-out-type) -o "." $<, \ |
Wenchao Xia | 21cd70d | 2014-06-18 08:43:28 +0200 | [diff] [blame] | 310 | " GEN $@") |
Michael S. Tsirkin | 599825c | 2011-11-16 23:58:18 +0200 | [diff] [blame] | 311 | qmp-commands.h qmp-marshal.c :\ |
Max Reitz | be13d46 | 2014-06-18 08:43:26 +0200 | [diff] [blame] | 312 | $(qapi-modules) $(SRC_PATH)/scripts/qapi-commands.py $(qapi-py) |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 313 | $(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/qapi-commands.py \ |
Markus Armbruster | 16d80f6 | 2015-04-02 13:32:16 +0200 | [diff] [blame] | 314 | $(gen-out-type) -o "." -m $<, \ |
Lluís Vilanova | 0a60774 | 2014-05-02 15:52:24 +0200 | [diff] [blame] | 315 | " GEN $@") |
Markus Armbruster | 39a1815 | 2015-09-16 13:06:28 +0200 | [diff] [blame] | 316 | qmp-introspect.h qmp-introspect.c :\ |
| 317 | $(qapi-modules) $(SRC_PATH)/scripts/qapi-introspect.py $(qapi-py) |
| 318 | $(call quiet-command,$(PYTHON) $(SRC_PATH)/scripts/qapi-introspect.py \ |
| 319 | $(gen-out-type) -o "." $<, \ |
| 320 | " GEN $@") |
Anthony Liguori | e319360 | 2011-09-02 12:34:47 -0500 | [diff] [blame] | 321 | |
Dunrong Huang | 54c2e50 | 2012-07-29 03:11:24 +0800 | [diff] [blame] | 322 | QGALIB_GEN=$(addprefix qga/qapi-generated/, qga-qapi-types.h qga-qapi-visit.h qga-qmp-commands.h) |
Paolo Bonzini | 4115852 | 2012-05-29 12:41:34 +0200 | [diff] [blame] | 323 | $(qga-obj-y) qemu-ga.o: $(QGALIB_GEN) |
Michael Roth | 957f1f9 | 2011-08-11 15:38:12 -0500 | [diff] [blame] | 324 | |
Michael Roth | fafcaf1 | 2015-09-07 18:47:05 -0500 | [diff] [blame] | 325 | qemu-ga$(EXESUF): $(qga-obj-y) libqemuutil.a libqemustub.a |
| 326 | $(call LINK, $^) |
Michael Roth | 48ff7a6 | 2011-07-20 15:19:37 -0500 | [diff] [blame] | 327 | |
Yossi Hindin | 9dacf32 | 2015-05-06 14:57:40 +0300 | [diff] [blame] | 328 | ifdef QEMU_GA_MSI_ENABLED |
| 329 | QEMU_GA_MSI=qemu-ga-$(ARCH).msi |
| 330 | |
Leonid Bloch | 0a18750 | 2015-07-29 20:10:51 +0300 | [diff] [blame] | 331 | msi: $(QEMU_GA_MSI) |
Yossi Hindin | 9dacf32 | 2015-05-06 14:57:40 +0300 | [diff] [blame] | 332 | |
Michael Roth | fafcaf1 | 2015-09-07 18:47:05 -0500 | [diff] [blame] | 333 | $(QEMU_GA_MSI): qemu-ga.exe $(QGA_VSS_PROVIDER) |
Yossi Hindin | 9dacf32 | 2015-05-06 14:57:40 +0300 | [diff] [blame] | 334 | |
Yossi Hindin | 9dacf32 | 2015-05-06 14:57:40 +0300 | [diff] [blame] | 335 | $(QEMU_GA_MSI): config-host.mak |
| 336 | |
Leonid Bloch | decdfbd | 2015-08-26 15:07:16 +0300 | [diff] [blame] | 337 | $(QEMU_GA_MSI): $(SRC_PATH)/qga/installer/qemu-ga.wxs |
| 338 | $(call quiet-command,QEMU_GA_VERSION="$(QEMU_GA_VERSION)" QEMU_GA_MANUFACTURER="$(QEMU_GA_MANUFACTURER)" QEMU_GA_DISTRO="$(QEMU_GA_DISTRO)" BUILD_DIR="$(BUILD_DIR)" \ |
Yossi Hindin | 9dacf32 | 2015-05-06 14:57:40 +0300 | [diff] [blame] | 339 | wixl -o $@ $(QEMU_GA_MSI_ARCH) $(QEMU_GA_MSI_WITH_VSS) $(QEMU_GA_MSI_MINGW_DLL_PATH) $<, " WIXL $@") |
| 340 | else |
| 341 | msi: |
Michael Roth | 15b19ed | 2015-08-26 17:05:01 -0500 | [diff] [blame] | 342 | @echo "MSI build not configured or dependency resolution failed (reconfigure with --enable-guest-agent-msi option)" |
Yossi Hindin | 9dacf32 | 2015-05-06 14:57:40 +0300 | [diff] [blame] | 343 | endif |
| 344 | |
Michael Roth | fafcaf1 | 2015-09-07 18:47:05 -0500 | [diff] [blame] | 345 | ifneq ($(EXESUF),) |
| 346 | .PHONY: qemu-ga |
| 347 | qemu-ga: qemu-ga$(EXESUF) $(QGA_VSS_PROVIDER) $(QEMU_GA_MSI) |
| 348 | endif |
| 349 | |
Daniel P. Berrange | a2d96af | 2016-03-07 20:25:19 +0000 | [diff] [blame] | 350 | ivshmem-client$(EXESUF): $(ivshmem-client-obj-y) libqemuutil.a libqemustub.a |
David Marchand | a75eb03 | 2014-09-08 11:17:48 +0200 | [diff] [blame] | 351 | $(call LINK, $^) |
| 352 | ivshmem-server$(EXESUF): $(ivshmem-server-obj-y) libqemuutil.a libqemustub.a |
| 353 | $(call LINK, $^) |
| 354 | |
bellard | 31e31b8 | 2003-02-18 22:55:36 +0000 | [diff] [blame] | 355 | clean: |
bellard | 2d80ae8 | 2003-08-11 23:01:33 +0000 | [diff] [blame] | 356 | # avoid old build problems by removing potentially incorrect old files |
Juan Quintela | 25be210f | 2009-10-07 02:41:00 +0200 | [diff] [blame] | 357 | rm -f config.mak op-i386.h opc-i386.h gen-op-i386.h op-arm.h opc-arm.h gen-op-arm.h |
Michael S. Tsirkin | df2943b | 2010-10-26 17:53:41 +0200 | [diff] [blame] | 358 | rm -f qemu-options.def |
Yossi Hindin | 9dacf32 | 2015-05-06 14:57:40 +0300 | [diff] [blame] | 359 | rm -f *.msi |
Fam Zheng | f4b11ee | 2014-03-17 09:35:22 +0800 | [diff] [blame] | 360 | find . \( -name '*.l[oa]' -o -name '*.so' -o -name '*.dll' -o -name '*.mo' -o -name '*.[oda]' \) -type f -exec rm {} + |
Tomoki Sekiyama | b39297a | 2013-08-07 11:40:18 -0400 | [diff] [blame] | 361 | rm -f $(filter-out %.tlb,$(TOOLS)) $(HELPERS-y) qemu-ga TAGS cscope.* *.pod *~ */*~ |
Stefan Weil | 8b6bfc7 | 2013-07-25 18:24:58 +0200 | [diff] [blame] | 362 | rm -f fsdev/*.pod |
| 363 | rm -rf .libs */.libs |
Blue Swirl | 07b44ce | 2009-06-09 18:45:16 +0000 | [diff] [blame] | 364 | rm -f qemu-img-cmds.h |
Gerd Hoffmann | d98bc0b | 2015-01-16 13:59:17 +0100 | [diff] [blame] | 365 | rm -f ui/shader/*-vert.h ui/shader/*-frag.h |
Lluís Vilanova | 19ac36b | 2012-04-18 20:15:39 +0200 | [diff] [blame] | 366 | @# May not be present in GENERATED_HEADERS |
Lluís Vilanova | eac236e | 2012-12-14 20:13:09 +0100 | [diff] [blame] | 367 | rm -f trace/generated-tracers-dtrace.dtrace* |
| 368 | rm -f trace/generated-tracers-dtrace.h* |
Lluís Vilanova | 19ac36b | 2012-04-18 20:15:39 +0200 | [diff] [blame] | 369 | rm -f $(foreach f,$(GENERATED_HEADERS),$(f) $(f)-timestamp) |
| 370 | rm -f $(foreach f,$(GENERATED_SOURCES),$(f) $(f)-timestamp) |
Stefan Weil | 8f0e5c6bb | 2012-06-09 09:08:39 +0200 | [diff] [blame] | 371 | rm -rf qapi-generated |
Dunrong Huang | 54c2e50 | 2012-07-29 03:11:24 +0800 | [diff] [blame] | 372 | rm -rf qga/qapi-generated |
Stefan Hajnoczi | 781c0c3 | 2013-01-15 08:47:26 +0100 | [diff] [blame] | 373 | for d in $(ALL_SUBDIRS); do \ |
Magnus Damm | fc8e320 | 2009-11-13 18:51:05 +0900 | [diff] [blame] | 374 | if test -d $$d; then $(MAKE) -C $$d $@ || exit 1; fi; \ |
Michael S. Tsirkin | df2943b | 2010-10-26 17:53:41 +0200 | [diff] [blame] | 375 | rm -f $$d/qemu-options.def; \ |
bellard | 626df76 | 2003-08-10 21:39:31 +0000 | [diff] [blame] | 376 | done |
Peter Maydell | 168340b | 2016-05-17 12:27:31 +0100 | [diff] [blame] | 377 | rm -f $(SUBDIR_DEVICES_MAK) config-all-devices.mak |
bellard | 31e31b8 | 2003-02-18 22:55:36 +0000 | [diff] [blame] | 378 | |
Anthony Liguori | 34bb443 | 2012-07-17 13:33:32 -0500 | [diff] [blame] | 379 | VERSION ?= $(shell cat VERSION) |
| 380 | |
| 381 | dist: qemu-$(VERSION).tar.bz2 |
| 382 | |
| 383 | qemu-%.tar.bz2: |
| 384 | $(SRC_PATH)/scripts/make-release "$(SRC_PATH)" "$(patsubst qemu-%.tar.bz2,%,$@)" |
| 385 | |
bellard | 7d13299 | 2003-03-06 23:23:54 +0000 | [diff] [blame] | 386 | distclean: clean |
Pavel Butsykin | 2cd8af2 | 2015-09-10 18:39:01 +0300 | [diff] [blame] | 387 | rm -f config-host.mak config-host.h* config-host.ld $(DOCS) qemu-options.texi qemu-img-cmds.texi qemu-monitor.texi qemu-monitor-info.texi |
Thomas Huth | ae21935 | 2014-12-15 11:19:46 +0100 | [diff] [blame] | 388 | rm -f config-all-devices.mak config-all-disas.mak config.status |
| 389 | rm -f po/*.mo tests/qemu-iotests/common.env |
Magnus Damm | fc8e320 | 2009-11-13 18:51:05 +0900 | [diff] [blame] | 390 | rm -f roms/seabios/config.mak roms/vgabios/config.mak |
Brad Hards | 7a734b8 | 2011-04-13 16:42:16 +1000 | [diff] [blame] | 391 | rm -f qemu-doc.info qemu-doc.aux qemu-doc.cp qemu-doc.cps qemu-doc.dvi |
| 392 | rm -f qemu-doc.fn qemu-doc.fns qemu-doc.info qemu-doc.ky qemu-doc.kys |
| 393 | rm -f qemu-doc.log qemu-doc.pdf qemu-doc.pg qemu-doc.toc qemu-doc.tp |
| 394 | rm -f qemu-doc.vr |
Alexandre Raymond | 793553a | 2011-07-25 23:56:02 -0400 | [diff] [blame] | 395 | rm -f config.log |
Peter Maydell | 67ed96f | 2012-02-01 18:50:42 +0000 | [diff] [blame] | 396 | rm -f linux-headers/asm |
Hidetoshi Seto | e1a068b | 2010-07-08 14:26:18 +0900 | [diff] [blame] | 397 | rm -f qemu-tech.info qemu-tech.aux qemu-tech.cp qemu-tech.dvi qemu-tech.fn qemu-tech.info qemu-tech.ky qemu-tech.log qemu-tech.pdf qemu-tech.pg qemu-tech.toc qemu-tech.tp qemu-tech.vr |
Paolo Bonzini | 8e98e2e | 2012-10-24 11:16:01 +0200 | [diff] [blame] | 398 | for d in $(TARGET_DIRS); do \ |
bellard | bc1b050 | 2003-10-28 00:12:52 +0000 | [diff] [blame] | 399 | rm -rf $$d || exit 1 ; \ |
bellard | 76bc683 | 2003-08-10 23:41:46 +0000 | [diff] [blame] | 400 | done |
Tomoki Sekiyama | d9840e2 | 2013-08-07 11:40:03 -0400 | [diff] [blame] | 401 | rm -Rf .sdk |
Ed Maste | fb8597b | 2015-04-01 13:58:38 -0400 | [diff] [blame] | 402 | if test -f pixman/config.log; then $(MAKE) -C pixman distclean; fi |
| 403 | if test -f dtc/version_gen.h; then $(MAKE) $(DTC_MAKE_ARGS) clean; fi |
bellard | 7d13299 | 2003-03-06 23:23:54 +0000 | [diff] [blame] | 404 | |
bellard | fed4a9a | 2004-12-12 22:18:34 +0000 | [diff] [blame] | 405 | KEYMAPS=da en-gb et fr fr-ch is lt modifiers no pt-br sv \ |
| 406 | ar de en-us fi fr-be hr it lv nl pl ru th \ |
Frédéric Boiteux | 471fbf4 | 2012-06-08 20:06:25 +0200 | [diff] [blame] | 407 | common de-ch es fo fr-ca hu ja mk nl-be pt sl tr \ |
Jan Krupa | 3751e72 | 2013-10-16 14:40:04 +0200 | [diff] [blame] | 408 | bepo cz |
bellard | fed4a9a | 2004-12-12 22:18:34 +0000 | [diff] [blame] | 409 | |
ths | 7775534 | 2008-11-27 15:45:16 +0000 | [diff] [blame] | 410 | ifdef INSTALL_BLOBS |
Eduardo Habkost | bf2eaf7 | 2013-12-09 21:33:34 -0200 | [diff] [blame] | 411 | BLOBS=bios.bin bios-256k.bin sgabios.bin vgabios.bin vgabios-cirrus.bin \ |
Gerd Hoffmann | 7a4dfd1 | 2014-09-10 13:04:17 +0200 | [diff] [blame] | 412 | vgabios-stdvga.bin vgabios-vmware.bin vgabios-qxl.bin vgabios-virtio.bin \ |
Eduardo Habkost | 75fb3d2 | 2016-01-23 14:02:12 -0200 | [diff] [blame] | 413 | acpi-dsdt.aml \ |
Mark Cave-Ayland | 9eb08a4 | 2013-10-15 21:03:04 +0100 | [diff] [blame] | 414 | ppc_rom.bin openbios-sparc32 openbios-sparc64 openbios-ppc QEMU,tcx.bin QEMU,cgthree.bin \ |
Alex Williamson | 5ee8ad7 | 2011-04-18 11:46:01 -0600 | [diff] [blame] | 415 | pxe-e1000.rom pxe-eepro100.rom pxe-ne2k_pci.rom \ |
| 416 | pxe-pcnet.rom pxe-rtl8139.rom pxe-virtio.rom \ |
Sander Eikelenboom | 9fd0297 | 2013-04-08 23:08:13 +0200 | [diff] [blame] | 417 | efi-e1000.rom efi-eepro100.rom efi-ne2k_pci.rom \ |
| 418 | efi-pcnet.rom efi-rtl8139.rom efi-virtio.rom \ |
Anthony Liguori | f7da9c1 | 2013-06-07 13:24:17 -0500 | [diff] [blame] | 419 | qemu-icon.bmp qemu_logo_no_text.svg \ |
Michal Simek | 00914b7 | 2011-03-14 11:29:19 +0100 | [diff] [blame] | 420 | bamboo.dtb petalogix-s3adsp1800.dtb petalogix-ml605.dtb \ |
Jan Kiszka | 2a2af96 | 2012-02-17 18:31:18 +0100 | [diff] [blame] | 421 | multiboot.bin linuxboot.bin kvmvapic.bin \ |
Alexander Graf | 0c1fecdd | 2013-04-22 21:10:50 +0200 | [diff] [blame] | 422 | s390-ccw.img \ |
Richard Henderson | 753d11f | 2011-06-24 11:58:37 -0700 | [diff] [blame] | 423 | spapr-rtas.bin slof.bin \ |
Cole Robinson | 0c6ab8c | 2014-07-04 15:43:18 -0400 | [diff] [blame] | 424 | palcode-clipper \ |
| 425 | u-boot.e500 |
ths | 7775534 | 2008-11-27 15:45:16 +0000 | [diff] [blame] | 426 | else |
| 427 | BLOBS= |
| 428 | endif |
| 429 | |
pbrook | 38954dc | 2006-04-30 23:54:18 +0000 | [diff] [blame] | 430 | install-doc: $(DOCS) |
Eduardo Habkost | d7dd65b | 2012-04-18 16:55:44 -0300 | [diff] [blame] | 431 | $(INSTALL_DIR) "$(DESTDIR)$(qemu_docdir)" |
| 432 | $(INSTALL_DATA) qemu-doc.html qemu-tech.html "$(DESTDIR)$(qemu_docdir)" |
Luiz Capitulino | d076a2a | 2013-09-10 16:56:14 -0400 | [diff] [blame] | 433 | $(INSTALL_DATA) qmp-commands.txt "$(DESTDIR)$(qemu_docdir)" |
Juan Quintela | 96d409e | 2009-08-03 14:47:00 +0200 | [diff] [blame] | 434 | ifdef CONFIG_POSIX |
aliguori | 58f8aea | 2009-04-18 15:36:02 +0000 | [diff] [blame] | 435 | $(INSTALL_DIR) "$(DESTDIR)$(mandir)/man1" |
Andreas Färber | 8a3e8f7 | 2013-06-11 13:13:58 +0200 | [diff] [blame] | 436 | $(INSTALL_DATA) qemu.1 "$(DESTDIR)$(mandir)/man1" |
| 437 | ifneq ($(TOOLS),) |
| 438 | $(INSTALL_DATA) qemu-img.1 "$(DESTDIR)$(mandir)/man1" |
aliguori | 58f8aea | 2009-04-18 15:36:02 +0000 | [diff] [blame] | 439 | $(INSTALL_DIR) "$(DESTDIR)$(mandir)/man8" |
| 440 | $(INSTALL_DATA) qemu-nbd.8 "$(DESTDIR)$(mandir)/man8" |
pbrook | 38954dc | 2006-04-30 23:54:18 +0000 | [diff] [blame] | 441 | endif |
Marc-André Lureau | 665b5d0 | 2015-08-27 01:34:59 +0200 | [diff] [blame] | 442 | ifneq (,$(findstring qemu-ga,$(TOOLS))) |
| 443 | $(INSTALL_DATA) qemu-ga.8 "$(DESTDIR)$(mandir)/man8" |
| 444 | endif |
Andreas Färber | 8a3e8f7 | 2013-06-11 13:13:58 +0200 | [diff] [blame] | 445 | endif |
M. Mohan Kumar | a2d8f1b | 2011-12-14 13:58:47 +0530 | [diff] [blame] | 446 | ifdef CONFIG_VIRTFS |
| 447 | $(INSTALL_DIR) "$(DESTDIR)$(mandir)/man1" |
| 448 | $(INSTALL_DATA) fsdev/virtfs-proxy-helper.1 "$(DESTDIR)$(mandir)/man1" |
| 449 | endif |
john cooper | b5ec5ce | 2010-02-20 11:14:59 -0600 | [diff] [blame] | 450 | |
Eduardo Habkost | e2d87bf | 2012-05-02 13:07:30 -0300 | [diff] [blame] | 451 | install-datadir: |
| 452 | $(INSTALL_DIR) "$(DESTDIR)$(qemu_datadir)" |
| 453 | |
Laszlo Ersek | f2e3978 | 2013-05-18 07:13:14 +0200 | [diff] [blame] | 454 | install-localstatedir: |
| 455 | ifdef CONFIG_POSIX |
| 456 | ifneq (,$(findstring qemu-ga,$(TOOLS))) |
| 457 | $(INSTALL_DIR) "$(DESTDIR)$(qemu_localstatedir)"/run |
| 458 | endif |
| 459 | endif |
| 460 | |
Eduardo Habkost | e2d87bf | 2012-05-02 13:07:30 -0300 | [diff] [blame] | 461 | |
Ikey Doherty | 1b93c9a | 2015-05-26 13:54:06 +0100 | [diff] [blame] | 462 | install: all $(if $(BUILD_DOCS),install-doc) \ |
Laszlo Ersek | f2e3978 | 2013-05-18 07:13:14 +0200 | [diff] [blame] | 463 | install-datadir install-localstatedir |
ths | 932a79d | 2007-10-20 18:29:34 +0000 | [diff] [blame] | 464 | ifneq ($(TOOLS),) |
Michael Roth | 68aa262 | 2015-11-23 15:48:58 -0600 | [diff] [blame] | 465 | $(call install-prog,$(subst qemu-ga,qemu-ga$(EXESUF),$(TOOLS)),$(DESTDIR)$(bindir)) |
ths | 932a79d | 2007-10-20 18:29:34 +0000 | [diff] [blame] | 466 | endif |
Fam Zheng | e3be6f0 | 2014-02-10 14:48:58 +0800 | [diff] [blame] | 467 | ifneq ($(CONFIG_MODULES),) |
| 468 | $(INSTALL_DIR) "$(DESTDIR)$(qemu_moddir)" |
Michael Tokarev | 2115182 | 2014-05-08 14:56:58 +0400 | [diff] [blame] | 469 | for s in $(modules-m:.mo=$(DSOSUF)); do \ |
| 470 | t="$(DESTDIR)$(qemu_moddir)/$$(echo $$s | tr / -)"; \ |
Michael Tokarev | 264f8b4 | 2014-05-08 15:06:03 +0400 | [diff] [blame] | 471 | $(INSTALL_LIB) $$s "$$t"; \ |
Michael Tokarev | 2115182 | 2014-05-08 14:56:58 +0400 | [diff] [blame] | 472 | test -z "$(STRIP)" || $(STRIP) "$$t"; \ |
Fam Zheng | e3be6f0 | 2014-02-10 14:48:58 +0800 | [diff] [blame] | 473 | done |
| 474 | endif |
Corey Bryant | 7b93fad | 2012-01-26 09:42:24 -0500 | [diff] [blame] | 475 | ifneq ($(HELPERS-y),) |
Michael Tokarev | 0d65942 | 2014-06-22 10:55:23 +0400 | [diff] [blame] | 476 | $(call install-prog,$(HELPERS-y),$(DESTDIR)$(libexecdir)) |
Corey Bryant | 7b93fad | 2012-01-26 09:42:24 -0500 | [diff] [blame] | 477 | endif |
ths | 7775534 | 2008-11-27 15:45:16 +0000 | [diff] [blame] | 478 | ifneq ($(BLOBS),) |
ths | 7775534 | 2008-11-27 15:45:16 +0000 | [diff] [blame] | 479 | set -e; for x in $(BLOBS); do \ |
Eduardo Habkost | 6aae2a2 | 2012-04-18 16:55:41 -0300 | [diff] [blame] | 480 | $(INSTALL_DATA) $(SRC_PATH)/pc-bios/$$x "$(DESTDIR)$(qemu_datadir)"; \ |
pbrook | ad06484 | 2006-04-16 12:41:07 +0000 | [diff] [blame] | 481 | done |
ths | 7775534 | 2008-11-27 15:45:16 +0000 | [diff] [blame] | 482 | endif |
Anthony Liguori | 834574e | 2013-02-20 07:43:24 -0600 | [diff] [blame] | 483 | ifeq ($(CONFIG_GTK),y) |
| 484 | $(MAKE) -C po $@ |
| 485 | endif |
Eduardo Habkost | 6aae2a2 | 2012-04-18 16:55:41 -0300 | [diff] [blame] | 486 | $(INSTALL_DIR) "$(DESTDIR)$(qemu_datadir)/keymaps" |
blueswir1 | 18be8d7 | 2008-03-05 18:16:09 +0000 | [diff] [blame] | 487 | set -e; for x in $(KEYMAPS); do \ |
Eduardo Habkost | 6aae2a2 | 2012-04-18 16:55:41 -0300 | [diff] [blame] | 488 | $(INSTALL_DATA) $(SRC_PATH)/pc-bios/keymaps/$$x "$(DESTDIR)$(qemu_datadir)/keymaps"; \ |
pbrook | ad06484 | 2006-04-16 12:41:07 +0000 | [diff] [blame] | 489 | done |
Daniel P. Berrange | 1412cf5 | 2016-06-16 09:39:47 +0100 | [diff] [blame] | 490 | $(INSTALL_DATA) $(BUILD_DIR)/trace-events-all "$(DESTDIR)$(qemu_datadir)/trace-events-all" |
bellard | 626df76 | 2003-08-10 21:39:31 +0000 | [diff] [blame] | 491 | for d in $(TARGET_DIRS); do \ |
Lluís Vilanova | 6570025 | 2014-01-20 12:21:54 +0100 | [diff] [blame] | 492 | $(MAKE) $(SUBDIR_MAKEFLAGS) TARGET_DIR=$$d/ -C $$d $@ || exit 1 ; \ |
bellard | 626df76 | 2003-08-10 21:39:31 +0000 | [diff] [blame] | 493 | done |
bellard | 612384d | 2003-03-22 17:31:19 +0000 | [diff] [blame] | 494 | |
bellard | 367e86e | 2003-03-01 17:13:26 +0000 | [diff] [blame] | 495 | # various test targets |
bellard | 9b0b820 | 2007-11-14 10:34:57 +0000 | [diff] [blame] | 496 | test speed: all |
Anthony Liguori | c09015d | 2012-01-10 13:10:42 -0600 | [diff] [blame] | 497 | $(MAKE) -C tests/tcg $@ |
bellard | 31e31b8 | 2003-02-18 22:55:36 +0000 | [diff] [blame] | 498 | |
Fam Zheng | ae5fdc8 | 2015-05-22 13:35:08 +0800 | [diff] [blame] | 499 | .PHONY: ctags |
| 500 | ctags: |
Sergey Fedorov | ac99c62 | 2016-06-09 20:58:35 +0300 | [diff] [blame] | 501 | rm -f tags |
Fam Zheng | ae5fdc8 | 2015-05-22 13:35:08 +0800 | [diff] [blame] | 502 | find "$(SRC_PATH)" -name '*.[hc]' -exec ctags --append {} + |
| 503 | |
Alexandre Bique | 21d4e8e | 2009-08-07 15:43:11 +0100 | [diff] [blame] | 504 | .PHONY: TAGS |
ths | 5fafdf2 | 2007-09-16 21:08:06 +0000 | [diff] [blame] | 505 | TAGS: |
Sergey Fedorov | ac99c62 | 2016-06-09 20:58:35 +0300 | [diff] [blame] | 506 | rm -f TAGS |
David Gibson | b1999e8 | 2013-03-12 13:57:28 +1100 | [diff] [blame] | 507 | find "$(SRC_PATH)" -name '*.[hc]' -exec etags --append {} + |
bellard | 31e31b8 | 2003-02-18 22:55:36 +0000 | [diff] [blame] | 508 | |
bellard | 6688bc6 | 2005-08-21 09:23:39 +0000 | [diff] [blame] | 509 | cscope: |
Fam Zheng | eaa2ddb | 2015-05-22 13:35:07 +0800 | [diff] [blame] | 510 | rm -f "$(SRC_PATH)"/cscope.* |
| 511 | find "$(SRC_PATH)/" -name "*.[chsS]" -print | sed 's,^\./,,' > "$(SRC_PATH)/cscope.files" |
| 512 | cscope -b -i"$(SRC_PATH)/cscope.files" |
bellard | 6688bc6 | 2005-08-21 09:23:39 +0000 | [diff] [blame] | 513 | |
Gerd Hoffmann | d98bc0b | 2015-01-16 13:59:17 +0100 | [diff] [blame] | 514 | # opengl shader programs |
| 515 | ui/shader/%-vert.h: $(SRC_PATH)/ui/shader/%.vert $(SRC_PATH)/scripts/shaderinclude.pl |
| 516 | @mkdir -p $(dir $@) |
| 517 | $(call quiet-command,\ |
| 518 | perl $(SRC_PATH)/scripts/shaderinclude.pl $< > $@,\ |
| 519 | " VERT $@") |
| 520 | |
| 521 | ui/shader/%-frag.h: $(SRC_PATH)/ui/shader/%.frag $(SRC_PATH)/scripts/shaderinclude.pl |
| 522 | @mkdir -p $(dir $@) |
| 523 | $(call quiet-command,\ |
| 524 | perl $(SRC_PATH)/scripts/shaderinclude.pl $< > $@,\ |
| 525 | " FRAG $@") |
| 526 | |
Gerd Hoffmann | cd2bc88 | 2015-01-09 11:40:23 +0100 | [diff] [blame] | 527 | ui/console-gl.o: $(SRC_PATH)/ui/console-gl.c \ |
| 528 | ui/shader/texture-blit-vert.h ui/shader/texture-blit-frag.h |
| 529 | |
bellard | 3ef693a | 2003-03-23 20:17:16 +0000 | [diff] [blame] | 530 | # documentation |
Stefan Weil | 01668d9 | 2010-03-04 22:21:02 +0100 | [diff] [blame] | 531 | MAKEINFO=makeinfo |
| 532 | MAKEINFOFLAGS=--no-headers --no-split --number-sections |
Stefan Weil | 20cc999 | 2010-01-29 23:16:50 +0100 | [diff] [blame] | 533 | TEXIFLAG=$(if $(V),,--quiet) |
| 534 | %.dvi: %.texi |
| 535 | $(call quiet-command,texi2dvi $(TEXIFLAG) -I . $<," GEN $@") |
| 536 | |
bellard | 1f67313 | 2004-04-04 15:21:17 +0000 | [diff] [blame] | 537 | %.html: %.texi |
Stefan Weil | 952ef67 | 2012-03-27 19:15:27 +0200 | [diff] [blame] | 538 | $(call quiet-command,LC_ALL=C $(MAKEINFO) $(MAKEINFOFLAGS) --html $< -o $@, \ |
Stefan Weil | 01668d9 | 2010-03-04 22:21:02 +0100 | [diff] [blame] | 539 | " GEN $@") |
bellard | 3ef693a | 2003-03-23 20:17:16 +0000 | [diff] [blame] | 540 | |
bellard | f354832 | 2006-04-30 22:51:54 +0000 | [diff] [blame] | 541 | %.info: %.texi |
Stefan Weil | 01668d9 | 2010-03-04 22:21:02 +0100 | [diff] [blame] | 542 | $(call quiet-command,$(MAKEINFO) $< -o $@," GEN $@") |
bellard | f354832 | 2006-04-30 22:51:54 +0000 | [diff] [blame] | 543 | |
Stefan Weil | 20cc999 | 2010-01-29 23:16:50 +0100 | [diff] [blame] | 544 | %.pdf: %.texi |
| 545 | $(call quiet-command,texi2pdf $(TEXIFLAG) -I . $<," GEN $@") |
blueswir1 | 5824d65 | 2009-03-28 06:44:27 +0000 | [diff] [blame] | 546 | |
Paolo Bonzini | 077de81 | 2016-06-07 13:27:04 +0200 | [diff] [blame] | 547 | qemu-options.texi: $(SRC_PATH)/qemu-options.hx $(SRC_PATH)/scripts/hxtool |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 548 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -t < $< > $@," GEN $@") |
bellard | f354832 | 2006-04-30 22:51:54 +0000 | [diff] [blame] | 549 | |
Paolo Bonzini | 077de81 | 2016-06-07 13:27:04 +0200 | [diff] [blame] | 550 | qemu-monitor.texi: $(SRC_PATH)/hmp-commands.hx $(SRC_PATH)/scripts/hxtool |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 551 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -t < $< > $@," GEN $@") |
Blue Swirl | 2313086 | 2009-06-06 08:22:04 +0000 | [diff] [blame] | 552 | |
Paolo Bonzini | 077de81 | 2016-06-07 13:27:04 +0200 | [diff] [blame] | 553 | qemu-monitor-info.texi: $(SRC_PATH)/hmp-commands-info.hx $(SRC_PATH)/scripts/hxtool |
Pavel Butsykin | 2cd8af2 | 2015-09-10 18:39:01 +0300 | [diff] [blame] | 554 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -t < $< > $@," GEN $@") |
| 555 | |
Paolo Bonzini | 077de81 | 2016-06-07 13:27:04 +0200 | [diff] [blame] | 556 | qmp-commands.txt: $(SRC_PATH)/qmp-commands.hx $(SRC_PATH)/scripts/hxtool |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 557 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -q < $< > $@," GEN $@") |
Jan Kiszka | b40292e | 2010-05-31 14:43:31 -0300 | [diff] [blame] | 558 | |
Paolo Bonzini | 077de81 | 2016-06-07 13:27:04 +0200 | [diff] [blame] | 559 | qemu-img-cmds.texi: $(SRC_PATH)/qemu-img-cmds.hx $(SRC_PATH)/scripts/hxtool |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 560 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -t < $< > $@," GEN $@") |
Stuart Brady | 153859b | 2009-06-07 00:42:17 +0100 | [diff] [blame] | 561 | |
Pavel Butsykin | 2cd8af2 | 2015-09-10 18:39:01 +0300 | [diff] [blame] | 562 | qemu.1: qemu-doc.texi qemu-options.texi qemu-monitor.texi qemu-monitor-info.texi |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 563 | $(call quiet-command, \ |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 564 | perl -Ww -- $(SRC_PATH)/scripts/texi2pod.pl $< qemu.pod && \ |
Michael Tokarev | 3179d69 | 2012-03-20 02:25:57 +0400 | [diff] [blame] | 565 | $(POD2MAN) --section=1 --center=" " --release=" " qemu.pod > $@, \ |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 566 | " GEN $@") |
Denis V. Lunev | eeb2b8f | 2016-06-17 17:44:09 +0300 | [diff] [blame] | 567 | qemu.1: qemu-option-trace.texi |
bellard | 5a67135 | 2003-10-01 00:13:48 +0000 | [diff] [blame] | 568 | |
Denis V. Lunev | 06a1e0c | 2016-06-17 17:44:14 +0300 | [diff] [blame] | 569 | qemu-img.1: qemu-img.texi qemu-option-trace.texi qemu-img-cmds.texi |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 570 | $(call quiet-command, \ |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 571 | perl -Ww -- $(SRC_PATH)/scripts/texi2pod.pl $< qemu-img.pod && \ |
Michael Tokarev | 3179d69 | 2012-03-20 02:25:57 +0400 | [diff] [blame] | 572 | $(POD2MAN) --section=1 --center=" " --release=" " qemu-img.pod > $@, \ |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 573 | " GEN $@") |
bellard | acd935e | 2004-11-15 22:57:26 +0000 | [diff] [blame] | 574 | |
M. Mohan Kumar | a2d8f1b | 2011-12-14 13:58:47 +0530 | [diff] [blame] | 575 | fsdev/virtfs-proxy-helper.1: fsdev/virtfs-proxy-helper.texi |
| 576 | $(call quiet-command, \ |
| 577 | perl -Ww -- $(SRC_PATH)/scripts/texi2pod.pl $< fsdev/virtfs-proxy-helper.pod && \ |
Michael Tokarev | 3179d69 | 2012-03-20 02:25:57 +0400 | [diff] [blame] | 578 | $(POD2MAN) --section=1 --center=" " --release=" " fsdev/virtfs-proxy-helper.pod > $@, \ |
M. Mohan Kumar | a2d8f1b | 2011-12-14 13:58:47 +0530 | [diff] [blame] | 579 | " GEN $@") |
| 580 | |
Denis V. Lunev | 39ca463 | 2016-06-17 17:44:12 +0300 | [diff] [blame] | 581 | qemu-nbd.8: qemu-nbd.texi qemu-option-trace.texi |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 582 | $(call quiet-command, \ |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 583 | perl -Ww -- $(SRC_PATH)/scripts/texi2pod.pl $< qemu-nbd.pod && \ |
Michael Tokarev | 3179d69 | 2012-03-20 02:25:57 +0400 | [diff] [blame] | 584 | $(POD2MAN) --section=8 --center=" " --release=" " qemu-nbd.pod > $@, \ |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 585 | " GEN $@") |
bellard | 7a5ca86 | 2008-05-27 21:13:40 +0000 | [diff] [blame] | 586 | |
Marc-André Lureau | 665b5d0 | 2015-08-27 01:34:59 +0200 | [diff] [blame] | 587 | qemu-ga.8: qemu-ga.texi |
| 588 | $(call quiet-command, \ |
| 589 | perl -Ww -- $(SRC_PATH)/scripts/texi2pod.pl $< qemu-ga.pod && \ |
| 590 | $(POD2MAN) --section=8 --center=" " --release=" " qemu-ga.pod > $@, \ |
| 591 | " GEN $@") |
| 592 | |
pbrook | 0cb3fb1 | 2006-05-14 12:07:53 +0000 | [diff] [blame] | 593 | dvi: qemu-doc.dvi qemu-tech.dvi |
pbrook | 0cb3fb1 | 2006-05-14 12:07:53 +0000 | [diff] [blame] | 594 | html: qemu-doc.html qemu-tech.html |
Stefan Weil | 20cc999 | 2010-01-29 23:16:50 +0100 | [diff] [blame] | 595 | info: qemu-doc.info qemu-tech.info |
| 596 | pdf: qemu-doc.pdf qemu-tech.pdf |
pbrook | 0cb3fb1 | 2006-05-14 12:07:53 +0000 | [diff] [blame] | 597 | |
Stefan Weil | 20cc999 | 2010-01-29 23:16:50 +0100 | [diff] [blame] | 598 | qemu-doc.dvi qemu-doc.html qemu-doc.info qemu-doc.pdf: \ |
Denis V. Lunev | eeb2b8f | 2016-06-17 17:44:09 +0300 | [diff] [blame] | 599 | qemu-img.texi qemu-nbd.texi qemu-options.texi qemu-option-trace.texi \ |
Pavel Butsykin | 2cd8af2 | 2015-09-10 18:39:01 +0300 | [diff] [blame] | 600 | qemu-monitor.texi qemu-img-cmds.texi qemu-ga.texi \ |
| 601 | qemu-monitor-info.texi |
aliguori | 818220f | 2008-09-24 01:13:40 +0000 | [diff] [blame] | 602 | |
Stefan Weil | f53ec69 | 2013-07-15 23:49:57 +0200 | [diff] [blame] | 603 | ifdef CONFIG_WIN32 |
| 604 | |
| 605 | INSTALLER = qemu-setup-$(VERSION)$(EXESUF) |
| 606 | |
| 607 | nsisflags = -V2 -NOCD |
| 608 | |
| 609 | ifneq ($(wildcard $(SRC_PATH)/dll),) |
| 610 | ifeq ($(ARCH),x86_64) |
| 611 | # 64 bit executables |
| 612 | DLL_PATH = $(SRC_PATH)/dll/w64 |
| 613 | nsisflags += -DW64 |
| 614 | else |
| 615 | # 32 bit executables |
| 616 | DLL_PATH = $(SRC_PATH)/dll/w32 |
| 617 | endif |
| 618 | endif |
| 619 | |
| 620 | .PHONY: installer |
| 621 | installer: $(INSTALLER) |
| 622 | |
| 623 | INSTDIR=/tmp/qemu-nsis |
| 624 | |
| 625 | $(INSTALLER): $(SRC_PATH)/qemu.nsi |
Ed Maste | fb8597b | 2015-04-01 13:58:38 -0400 | [diff] [blame] | 626 | $(MAKE) install prefix=${INSTDIR} |
Stefan Weil | f53ec69 | 2013-07-15 23:49:57 +0200 | [diff] [blame] | 627 | ifdef SIGNCODE |
| 628 | (cd ${INSTDIR}; \ |
| 629 | for i in *.exe; do \ |
| 630 | $(SIGNCODE) $${i}; \ |
| 631 | done \ |
| 632 | ) |
| 633 | endif # SIGNCODE |
| 634 | (cd ${INSTDIR}; \ |
| 635 | for i in qemu-system-*.exe; do \ |
| 636 | arch=$${i%.exe}; \ |
| 637 | arch=$${arch#qemu-system-}; \ |
| 638 | echo Section \"$$arch\" Section_$$arch; \ |
| 639 | echo SetOutPath \"\$$INSTDIR\"; \ |
| 640 | echo File \"\$${BINDIR}\\$$i\"; \ |
| 641 | echo SectionEnd; \ |
| 642 | done \ |
| 643 | ) >${INSTDIR}/system-emulations.nsh |
| 644 | makensis $(nsisflags) \ |
| 645 | $(if $(BUILD_DOCS),-DCONFIG_DOCUMENTATION="y") \ |
| 646 | $(if $(CONFIG_GTK),-DCONFIG_GTK="y") \ |
| 647 | -DBINDIR="${INSTDIR}" \ |
| 648 | $(if $(DLL_PATH),-DDLLDIR="$(DLL_PATH)") \ |
| 649 | -DSRCDIR="$(SRC_PATH)" \ |
| 650 | -DOUTFILE="$(INSTALLER)" \ |
Stefan Weil | 805d8a6 | 2015-05-03 19:57:09 +0200 | [diff] [blame] | 651 | -DDISPLAYVERSION="$(VERSION)" \ |
Stefan Weil | f53ec69 | 2013-07-15 23:49:57 +0200 | [diff] [blame] | 652 | $(SRC_PATH)/qemu.nsi |
| 653 | rm -r ${INSTDIR} |
| 654 | ifdef SIGNCODE |
| 655 | $(SIGNCODE) $(INSTALLER) |
| 656 | endif # SIGNCODE |
| 657 | endif # CONFIG_WIN |
| 658 | |
Anthony Liguori | cb5fc67 | 2012-07-17 18:58:20 -0500 | [diff] [blame] | 659 | # Add a dependency on the generated files, so that they are always |
| 660 | # rebuilt before other object files |
Fam Zheng | eaa2ddb | 2015-05-22 13:35:07 +0800 | [diff] [blame] | 661 | ifneq ($(filter-out $(UNCHECKED_GOALS),$(MAKECMDGOALS)),$(if $(MAKECMDGOALS),,fail)) |
Anthony Liguori | cb5fc67 | 2012-07-17 18:58:20 -0500 | [diff] [blame] | 662 | Makefile: $(GENERATED_HEADERS) |
Mike Frysinger | 7748b8c | 2012-09-16 16:07:13 -0400 | [diff] [blame] | 663 | endif |
Anthony Liguori | cb5fc67 | 2012-07-17 18:58:20 -0500 | [diff] [blame] | 664 | |
bellard | 4fb240a | 2007-11-07 19:24:02 +0000 | [diff] [blame] | 665 | # Include automatically generated dependency files |
Paolo Bonzini | 1435ddb | 2012-07-11 16:40:21 +0200 | [diff] [blame] | 666 | # Dependencies in Makefile.objs files come from our recursive subdir rules |
| 667 | -include $(wildcard *.d tests/*.d) |
Fam Zheng | 324027c | 2016-06-01 12:25:17 +0800 | [diff] [blame] | 668 | |
| 669 | include $(SRC_PATH)/tests/docker/Makefile.include |