pbrook | 0cb3fb1 | 2006-05-14 12:07:53 +0000 | [diff] [blame] | 1 | # Makefile for QEMU. |
| 2 | |
Michael S. Tsirkin | df2943b | 2010-10-26 17:53:41 +0200 | [diff] [blame] | 3 | GENERATED_HEADERS = config-host.h trace.h qemu-options.def |
Daniel P. Berrange | b3d08c0 | 2010-11-12 13:20:24 +0000 | [diff] [blame] | 4 | ifeq ($(TRACE_BACKEND),dtrace) |
| 5 | GENERATED_HEADERS += trace-dtrace.h |
| 6 | endif |
Juan Quintela | f527c57 | 2009-11-05 17:19:57 +0100 | [diff] [blame] | 7 | |
aurel32 | 55d7e8f | 2009-04-15 14:42:57 +0000 | [diff] [blame] | 8 | ifneq ($(wildcard config-host.mak),) |
Paul Brook | 1ad2134 | 2009-05-19 16:17:58 +0100 | [diff] [blame] | 9 | # Put the all: rule here so that config-host.mak can contain dependencies. |
| 10 | all: build-all |
pbrook | ad06484 | 2006-04-16 12:41:07 +0000 | [diff] [blame] | 11 | include config-host.mak |
aliguori | 1775918 | 2009-01-21 18:12:52 +0000 | [diff] [blame] | 12 | include $(SRC_PATH)/rules.mak |
Paolo Bonzini | 59bc10e | 2010-01-04 11:02:28 +0100 | [diff] [blame] | 13 | config-host.mak: $(SRC_PATH)/configure |
Juan Quintela | e5efe7f | 2009-10-07 02:40:59 +0200 | [diff] [blame] | 14 | @echo $@ is out-of-date, running configure |
| 15 | @sed -n "/.*Configured with/s/[^:]*: //p" $@ | sh |
aurel32 | 55d7e8f | 2009-04-15 14:42:57 +0000 | [diff] [blame] | 16 | else |
| 17 | config-host.mak: |
| 18 | @echo "Please call configure before running make!" |
| 19 | @exit 1 |
| 20 | endif |
bellard | 766a487 | 2003-02-18 23:35:48 +0000 | [diff] [blame] | 21 | |
Juan Quintela | d9ace8b | 2009-10-06 21:11:15 +0200 | [diff] [blame] | 22 | # Don't try to regenerate Makefile or configure |
| 23 | # We don't generate any of them |
| 24 | Makefile: ; |
| 25 | configure: ; |
| 26 | |
aliguori | 818220f | 2008-09-24 01:13:40 +0000 | [diff] [blame] | 27 | .PHONY: all clean cscope distclean dvi html info install install-doc \ |
Stefan Weil | 20cc999 | 2010-01-29 23:16:50 +0100 | [diff] [blame] | 28 | pdf recurse-all speed tar tarbin test build-all |
pbrook | 0cb3fb1 | 2006-05-14 12:07:53 +0000 | [diff] [blame] | 29 | |
Paolo Bonzini | 076d247 | 2009-12-21 10:06:55 +0100 | [diff] [blame] | 30 | $(call set-vpath, $(SRC_PATH):$(SRC_PATH)/hw) |
pbrook | 8c462f8 | 2007-11-18 21:12:37 +0000 | [diff] [blame] | 31 | |
Juan Quintela | 3e2e0e6 | 2009-08-03 14:47:06 +0200 | [diff] [blame] | 32 | LIBS+=-lz $(LIBS_TOOLS) |
Juan Quintela | 67c0f08 | 2009-07-27 16:12:51 +0200 | [diff] [blame] | 33 | |
pbrook | cc8ae6d | 2006-04-23 17:57:59 +0000 | [diff] [blame] | 34 | ifdef BUILD_DOCS |
Jan Kiszka | b40292e | 2010-05-31 14:43:31 -0300 | [diff] [blame] | 35 | DOCS=qemu-doc.html qemu-tech.html qemu.1 qemu-img.1 qemu-nbd.8 QMP/qmp-commands.txt |
pbrook | cc8ae6d | 2006-04-23 17:57:59 +0000 | [diff] [blame] | 36 | else |
| 37 | DOCS= |
| 38 | endif |
bellard | 7d13299 | 2003-03-06 23:23:54 +0000 | [diff] [blame] | 39 | |
Juan Quintela | 1215c6e | 2009-10-07 02:40:58 +0200 | [diff] [blame] | 40 | SUBDIR_MAKEFLAGS=$(if $(V),,--no-print-directory) |
Juan Quintela | 1f3d3c8 | 2009-10-07 02:41:02 +0200 | [diff] [blame] | 41 | SUBDIR_DEVICES_MAK=$(patsubst %, %/config-devices.mak, $(TARGET_DIRS)) |
Paul Brook | bd9141b | 2010-11-26 18:47:45 +0000 | [diff] [blame] | 42 | SUBDIR_DEVICES_MAK_DEP=$(patsubst %, %/config-devices.mak.d, $(TARGET_DIRS)) |
Juan Quintela | 1f3d3c8 | 2009-10-07 02:41:02 +0200 | [diff] [blame] | 43 | |
| 44 | config-all-devices.mak: $(SUBDIR_DEVICES_MAK) |
Stefan Weil | 01d86a8 | 2009-11-19 20:19:56 +0100 | [diff] [blame] | 45 | $(call quiet-command,cat $(SUBDIR_DEVICES_MAK) | grep =y | sort -u > $@," GEN $@") |
Juan Quintela | 1f3d3c8 | 2009-10-07 02:41:02 +0200 | [diff] [blame] | 46 | |
Paul Brook | bd9141b | 2010-11-26 18:47:45 +0000 | [diff] [blame] | 47 | -include $(SUBDIR_DEVICES_MAK_DEP) |
| 48 | |
Paul Brook | a992fe3 | 2009-11-22 16:25:30 +0000 | [diff] [blame] | 49 | %/config-devices.mak: default-configs/%.mak |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 50 | $(call quiet-command,$(SHELL) $(SRC_PATH)/scripts/make_device_config.sh $@ $<, " GEN $@") |
Stefan Weil | 012f087 | 2009-12-20 15:39:03 +0100 | [diff] [blame] | 51 | @if test -f $@; then \ |
Blue Swirl | 904fe1f | 2010-10-02 14:28:08 +0000 | [diff] [blame] | 52 | if cmp -s $@.old $@; then \ |
Paul Brook | bd9141b | 2010-11-26 18:47:45 +0000 | [diff] [blame] | 53 | mv $@.tmp $@; \ |
| 54 | cp -p $@ $@.old; \ |
Stefan Weil | 012f087 | 2009-12-20 15:39:03 +0100 | [diff] [blame] | 55 | else \ |
| 56 | if test -f $@.old; then \ |
| 57 | echo "WARNING: $@ (user modified) out of date.";\ |
| 58 | else \ |
| 59 | echo "WARNING: $@ out of date.";\ |
| 60 | fi; \ |
| 61 | echo "Run \"make defconfig\" to regenerate."; \ |
| 62 | rm $@.tmp; \ |
| 63 | fi; \ |
Paul Brook | a992fe3 | 2009-11-22 16:25:30 +0000 | [diff] [blame] | 64 | else \ |
Stefan Weil | 012f087 | 2009-12-20 15:39:03 +0100 | [diff] [blame] | 65 | mv $@.tmp $@; \ |
| 66 | cp -p $@ $@.old; \ |
Paul Brook | a992fe3 | 2009-11-22 16:25:30 +0000 | [diff] [blame] | 67 | fi |
| 68 | |
| 69 | defconfig: |
| 70 | rm -f config-all-devices.mak $(SUBDIR_DEVICES_MAK) |
| 71 | |
Juan Quintela | 1f3d3c8 | 2009-10-07 02:41:02 +0200 | [diff] [blame] | 72 | -include config-all-devices.mak |
Juan Quintela | 1215c6e | 2009-10-07 02:40:58 +0200 | [diff] [blame] | 73 | |
Juan Quintela | f527c57 | 2009-11-05 17:19:57 +0100 | [diff] [blame] | 74 | build-all: $(DOCS) $(TOOLS) recurse-all |
pbrook | b9dea4f | 2006-05-13 16:54:03 +0000 | [diff] [blame] | 75 | |
Juan Quintela | 1215c6e | 2009-10-07 02:40:58 +0200 | [diff] [blame] | 76 | config-host.h: config-host.h-timestamp |
| 77 | config-host.h-timestamp: config-host.mak |
Blue Swirl | e14056a | 2010-11-01 18:09:38 +0000 | [diff] [blame] | 78 | qemu-options.def: $(SRC_PATH)/qemu-options.hx |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 79 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -h < $< > $@," GEN $@") |
Juan Quintela | 1215c6e | 2009-10-07 02:40:58 +0200 | [diff] [blame] | 80 | |
pbrook | cec7d0b | 2008-05-28 16:44:57 +0000 | [diff] [blame] | 81 | SUBDIR_RULES=$(patsubst %,subdir-%, $(TARGET_DIRS)) |
| 82 | |
Juan Quintela | f527c57 | 2009-11-05 17:19:57 +0100 | [diff] [blame] | 83 | subdir-%: $(GENERATED_HEADERS) |
Paul Brook | 0087375 | 2009-05-07 02:00:31 +0100 | [diff] [blame] | 84 | $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C $* V="$(V)" TARGET_DIR="$*/" all,) |
pbrook | 4aa4253 | 2006-05-13 13:55:08 +0000 | [diff] [blame] | 85 | |
Stefan Weil | b88bc80 | 2010-01-14 18:11:43 +0100 | [diff] [blame] | 86 | ifneq ($(wildcard config-host.mak),) |
Andreas Färber | 0e8c921 | 2010-01-06 20:24:05 +0100 | [diff] [blame] | 87 | include $(SRC_PATH)/Makefile.objs |
Stefan Weil | b88bc80 | 2010-01-14 18:11:43 +0100 | [diff] [blame] | 88 | endif |
Andreas Färber | 0e8c921 | 2010-01-06 20:24:05 +0100 | [diff] [blame] | 89 | |
| 90 | $(common-obj-y): $(GENERATED_HEADERS) |
Paolo Bonzini | 6774e44 | 2011-05-02 09:54:03 +0200 | [diff] [blame] | 91 | subdir-libcacard: $(oslib-obj-y) $(trace-obj-y) qemu-malloc.o qemu-timer-common.o |
| 92 | |
Andreas Färber | 91f1690 | 2010-09-12 17:21:36 +0200 | [diff] [blame] | 93 | $(filter %-softmmu,$(SUBDIR_RULES)): $(trace-obj-y) $(common-obj-y) subdir-libdis |
Paul Brook | c05ac89 | 2009-07-31 13:18:32 +0100 | [diff] [blame] | 94 | |
Andreas Färber | 91f1690 | 2010-09-12 17:21:36 +0200 | [diff] [blame] | 95 | $(filter %-user,$(SUBDIR_RULES)): $(GENERATED_HEADERS) $(trace-obj-y) subdir-libdis-user subdir-libuser |
Blue Swirl | add1615 | 2009-09-27 16:26:02 +0000 | [diff] [blame] | 96 | |
Paul Brook | c05ac89 | 2009-07-31 13:18:32 +0100 | [diff] [blame] | 97 | ROMSUBDIR_RULES=$(patsubst %,romsubdir-%, $(ROMS)) |
| 98 | romsubdir-%: |
| 99 | $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C pc-bios/$* V="$(V)" TARGET_DIR="$*/",) |
| 100 | |
| 101 | ALL_SUBDIRS=$(TARGET_DIRS) $(patsubst %,pc-bios/%, $(ROMS)) |
| 102 | |
| 103 | recurse-all: $(SUBDIR_RULES) $(ROMSUBDIR_RULES) |
bellard | 83f6409 | 2006-08-01 16:21:11 +0000 | [diff] [blame] | 104 | |
Juan Quintela | 98b068a | 2009-08-03 14:46:57 +0200 | [diff] [blame] | 105 | audio/audio.o audio/fmodaudio.o: QEMU_CFLAGS += $(FMOD_CFLAGS) |
Juan Quintela | 0e22fd2 | 2009-06-25 00:08:09 +0200 | [diff] [blame] | 106 | |
Juan Quintela | a558ee1 | 2009-08-03 14:46:21 +0200 | [diff] [blame] | 107 | QEMU_CFLAGS+=$(CURL_CFLAGS) |
Alexander Graf | 769ce76 | 2009-05-11 17:41:42 +0200 | [diff] [blame] | 108 | |
Anthony Liguori | e18df14 | 2011-07-19 14:50:29 -0500 | [diff] [blame] | 109 | QEMU_CFLAGS+=$(GLIB_CFLAGS) |
| 110 | |
Corentin Chary | 3e230dd | 2010-07-07 20:57:52 +0200 | [diff] [blame] | 111 | ui/cocoa.o: ui/cocoa.m |
bellard | 4fb240a | 2007-11-07 19:24:02 +0000 | [diff] [blame] | 112 | |
Corentin Chary | 3e230dd | 2010-07-07 20:57:52 +0200 | [diff] [blame] | 113 | ui/sdl.o audio/sdlaudio.o ui/sdl_zoom.o baum.o: QEMU_CFLAGS += $(SDL_CFLAGS) |
aliguori | 0483755 | 2009-03-06 20:27:10 +0000 | [diff] [blame] | 114 | |
Corentin Chary | 3e230dd | 2010-07-07 20:57:52 +0200 | [diff] [blame] | 115 | ui/vnc.o: QEMU_CFLAGS += $(VNC_TLS_CFLAGS) |
balrog | 4d3b6f6 | 2008-02-10 16:33:14 +0000 | [diff] [blame] | 116 | |
Juan Quintela | a558ee1 | 2009-08-03 14:46:21 +0200 | [diff] [blame] | 117 | bt-host.o: QEMU_CFLAGS += $(BLUEZ_CFLAGS) |
bellard | 4fb240a | 2007-11-07 19:24:02 +0000 | [diff] [blame] | 118 | |
Blue Swirl | 9fe6de9 | 2010-09-26 16:07:57 +0000 | [diff] [blame] | 119 | version.o: $(SRC_PATH)/version.rc config-host.mak |
| 120 | $(call quiet-command,$(WINDRES) -I. -o $@ $<," RC $(TARGET_DIR)$@") |
| 121 | |
| 122 | version-obj-$(CONFIG_WIN32) += version.o |
bellard | 4fb240a | 2007-11-07 19:24:02 +0000 | [diff] [blame] | 123 | ###################################################################### |
Alon Levy | 44dc0ca | 2011-05-15 11:51:28 +0300 | [diff] [blame] | 124 | # Support building shared library libcacard |
| 125 | |
| 126 | .PHONY: libcacard.la install-libcacard |
| 127 | ifeq ($(LIBTOOL),) |
| 128 | libcacard.la: |
| 129 | @echo "libtool is missing, please install and rerun configure"; exit 1 |
| 130 | |
| 131 | install-libcacard: |
| 132 | @echo "libtool is missing, please install and rerun configure"; exit 1 |
| 133 | else |
| 134 | libcacard.la: $(GENERATED_HEADERS) $(oslib-obj-y) qemu-malloc.o qemu-timer-common.o $(addsuffix .lo, $(basename $(trace-obj-y))) |
| 135 | $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C libcacard V="$(V)" TARGET_DIR="$*/" libcacard.la,) |
| 136 | |
| 137 | install-libcacard: libcacard.la |
| 138 | $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C libcacard V="$(V)" TARGET_DIR="$*/" install-libcacard,) |
| 139 | endif |
| 140 | ###################################################################### |
bellard | 4fb240a | 2007-11-07 19:24:02 +0000 | [diff] [blame] | 141 | |
Juan Quintela | 3c089e1 | 2010-01-20 20:54:18 +0100 | [diff] [blame] | 142 | qemu-img.o: qemu-img-cmds.h |
Michael Roth | 48ff7a6 | 2011-07-20 15:19:37 -0500 | [diff] [blame] | 143 | qemu-img.o qemu-tool.o qemu-nbd.o qemu-io.o cmd.o qemu-ga.o: $(GENERATED_HEADERS) |
Stuart Brady | 153859b | 2009-06-07 00:42:17 +0100 | [diff] [blame] | 144 | |
Jes Sorensen | c1b0b93 | 2010-10-26 10:39:19 +0200 | [diff] [blame] | 145 | qemu-img$(EXESUF): qemu-img.o qemu-tool.o qemu-error.o $(oslib-obj-y) $(trace-obj-y) $(block-obj-y) $(qobject-obj-y) $(version-obj-y) qemu-timer-common.o |
bellard | 4fb240a | 2007-11-07 19:24:02 +0000 | [diff] [blame] | 146 | |
Jes Sorensen | c1b0b93 | 2010-10-26 10:39:19 +0200 | [diff] [blame] | 147 | qemu-nbd$(EXESUF): qemu-nbd.o qemu-tool.o qemu-error.o $(oslib-obj-y) $(trace-obj-y) $(block-obj-y) $(qobject-obj-y) $(version-obj-y) qemu-timer-common.o |
aliguori | 3aa892d | 2009-01-21 18:13:02 +0000 | [diff] [blame] | 148 | |
Jes Sorensen | c1b0b93 | 2010-10-26 10:39:19 +0200 | [diff] [blame] | 149 | qemu-io$(EXESUF): qemu-io.o cmd.o qemu-tool.o qemu-error.o $(oslib-obj-y) $(trace-obj-y) $(block-obj-y) $(qobject-obj-y) $(version-obj-y) qemu-timer-common.o |
aliguori | 0a8e1ac | 2009-04-05 18:41:23 +0000 | [diff] [blame] | 150 | |
Stuart Brady | 153859b | 2009-06-07 00:42:17 +0100 | [diff] [blame] | 151 | qemu-img-cmds.h: $(SRC_PATH)/qemu-img-cmds.hx |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 152 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -h < $< > $@," GEN $@") |
Stuart Brady | 153859b | 2009-06-07 00:42:17 +0100 | [diff] [blame] | 153 | |
Jan Kiszka | 4091da4 | 2010-05-20 09:18:52 +0200 | [diff] [blame] | 154 | check-qint.o check-qstring.o check-qdict.o check-qlist.o check-qfloat.o check-qjson.o: $(GENERATED_HEADERS) |
| 155 | |
Anthony Liguori | ef749d0 | 2011-06-01 12:14:50 -0500 | [diff] [blame] | 156 | CHECK_PROG_DEPS = qemu-malloc.o $(oslib-obj-y) $(trace-obj-y) qemu-tool.o |
Luiz Capitulino | e71e00e | 2010-11-12 12:55:46 -0200 | [diff] [blame] | 157 | |
| 158 | check-qint: check-qint.o qint.o $(CHECK_PROG_DEPS) |
| 159 | check-qstring: check-qstring.o qstring.o $(CHECK_PROG_DEPS) |
| 160 | check-qdict: check-qdict.o qdict.o qfloat.o qint.o qstring.o qbool.o qlist.o $(CHECK_PROG_DEPS) |
| 161 | check-qlist: check-qlist.o qlist.o qint.o $(CHECK_PROG_DEPS) |
| 162 | check-qfloat: check-qfloat.o qfloat.o $(CHECK_PROG_DEPS) |
Anthony Liguori | ef749d0 | 2011-06-01 12:14:50 -0500 | [diff] [blame] | 163 | check-qjson: check-qjson.o qfloat.o qint.o qdict.o qstring.o qlist.o qbool.o qjson.o json-streamer.o json-lexer.o json-parser.o error.o qerror.o qemu-error.o $(CHECK_PROG_DEPS) |
Luiz Capitulino | 33837ba | 2009-08-28 15:27:29 -0300 | [diff] [blame] | 164 | |
Michael Roth | 640e540 | 2011-07-19 14:50:44 -0500 | [diff] [blame] | 165 | $(qapi-obj-y): $(GENERATED_HEADERS) |
| 166 | qapi-dir := qapi-generated |
Michael Roth | e3d4d25 | 2011-07-19 15:41:55 -0500 | [diff] [blame] | 167 | test-visitor.o test-qmp-commands.o qemu-ga$(EXESUF): QEMU_CFLAGS += -I $(qapi-dir) |
Michael Roth | 640e540 | 2011-07-19 14:50:44 -0500 | [diff] [blame] | 168 | |
| 169 | $(qapi-dir)/test-qapi-types.c: $(qapi-dir)/test-qapi-types.h |
| 170 | $(qapi-dir)/test-qapi-types.h: $(SRC_PATH)/qapi-schema-test.json $(SRC_PATH)/scripts/qapi-types.py |
| 171 | $(call quiet-command,python $(SRC_PATH)/scripts/qapi-types.py -o "$(qapi-dir)" -p "test-" < $<, " GEN $@") |
| 172 | $(qapi-dir)/test-qapi-visit.c: $(qapi-dir)/test-qapi-visit.h |
| 173 | $(qapi-dir)/test-qapi-visit.h: $(SRC_PATH)/qapi-schema-test.json $(SRC_PATH)/scripts/qapi-visit.py |
| 174 | $(call quiet-command,python $(SRC_PATH)/scripts/qapi-visit.py -o "$(qapi-dir)" -p "test-" < $<, " GEN $@") |
Michael Roth | 69ed836 | 2011-07-19 14:50:45 -0500 | [diff] [blame] | 175 | $(qapi-dir)/test-qmp-commands.h: $(qapi-dir)/test-qmp-marshal.c |
| 176 | $(qapi-dir)/test-qmp-marshal.c: $(SRC_PATH)/qapi-schema-test.json $(SRC_PATH)/scripts/qapi-commands.py |
| 177 | $(call quiet-command,python $(SRC_PATH)/scripts/qapi-commands.py -o "$(qapi-dir)" -p "test-" < $<, " GEN $@") |
Michael Roth | 640e540 | 2011-07-19 14:50:44 -0500 | [diff] [blame] | 178 | |
Michael Roth | e3d4d25 | 2011-07-19 15:41:55 -0500 | [diff] [blame] | 179 | $(qapi-dir)/qga-qapi-types.c: $(qapi-dir)/qga-qapi-types.h |
| 180 | $(qapi-dir)/qga-qapi-types.h: $(SRC_PATH)/qapi-schema-guest.json $(SRC_PATH)/scripts/qapi-types.py |
| 181 | $(call quiet-command,python $(SRC_PATH)/scripts/qapi-types.py -o "$(qapi-dir)" -p "qga-" < $<, " GEN $@") |
| 182 | $(qapi-dir)/qga-qapi-visit.c: $(qapi-dir)/qga-qapi-visit.h |
| 183 | $(qapi-dir)/qga-qapi-visit.h: $(SRC_PATH)/qapi-schema-guest.json $(SRC_PATH)/scripts/qapi-visit.py |
| 184 | $(call quiet-command,python $(SRC_PATH)/scripts/qapi-visit.py -o "$(qapi-dir)" -p "qga-" < $<, " GEN $@") |
| 185 | $(qapi-dir)/qga-qmp-marshal.c: $(SRC_PATH)/qapi-schema-guest.json $(SRC_PATH)/scripts/qapi-commands.py |
| 186 | $(call quiet-command,python $(SRC_PATH)/scripts/qapi-commands.py -o "$(qapi-dir)" -p "qga-" < $<, " GEN $@") |
| 187 | |
Michael Roth | 640e540 | 2011-07-19 14:50:44 -0500 | [diff] [blame] | 188 | test-visitor.o: $(addprefix $(qapi-dir)/, test-qapi-types.c test-qapi-types.h test-qapi-visit.c test-qapi-visit.h) $(qapi-obj-y) |
| 189 | test-visitor: test-visitor.o qfloat.o qint.o qdict.o qstring.o qlist.o qbool.o $(qapi-obj-y) error.o osdep.o qemu-malloc.o $(oslib-obj-y) qjson.o json-streamer.o json-lexer.o json-parser.o qerror.o qemu-error.o qemu-tool.o $(qapi-dir)/test-qapi-visit.o $(qapi-dir)/test-qapi-types.o |
| 190 | |
Michael Roth | 69ed836 | 2011-07-19 14:50:45 -0500 | [diff] [blame] | 191 | test-qmp-commands.o: $(addprefix $(qapi-dir)/, test-qapi-types.c test-qapi-types.h test-qapi-visit.c test-qapi-visit.h test-qmp-marshal.c test-qmp-commands.h) $(qapi-obj-y) |
| 192 | test-qmp-commands: test-qmp-commands.o qfloat.o qint.o qdict.o qstring.o qlist.o qbool.o $(qapi-obj-y) error.o osdep.o qemu-malloc.o $(oslib-obj-y) qjson.o json-streamer.o json-lexer.o json-parser.o qerror.o qemu-error.o qemu-tool.o $(qapi-dir)/test-qapi-visit.o $(qapi-dir)/test-qapi-types.o $(qapi-dir)/test-qmp-marshal.o module.o |
| 193 | |
Michael Roth | e3d4d25 | 2011-07-19 15:41:55 -0500 | [diff] [blame] | 194 | QGALIB=qga/guest-agent-command-state.o qga/guest-agent-commands.o |
Michael Roth | 13a286d | 2011-07-19 15:41:53 -0500 | [diff] [blame] | 195 | |
Michael Roth | e3d4d25 | 2011-07-19 15:41:55 -0500 | [diff] [blame] | 196 | qemu-ga.o: $(addprefix $(qapi-dir)/, qga-qapi-types.c qga-qapi-types.h qga-qapi-visit.c qga-qmp-marshal.c) $(qapi-obj-y) |
| 197 | qemu-ga$(EXESUF): qemu-ga.o $(QGALIB) qemu-tool.o qemu-error.o error.o $(oslib-obj-y) $(trace-obj-y) $(block-obj-y) $(qobject-obj-y) $(version-obj-y) $(qapi-obj-y) qemu-timer-common.o qemu-sockets.o module.o qapi/qmp-dispatch.o qapi/qmp-registry.o $(qapi-dir)/qga-qapi-visit.o $(qapi-dir)/qga-qapi-types.o $(qapi-dir)/qga-qmp-marshal.o |
Michael Roth | 48ff7a6 | 2011-07-20 15:19:37 -0500 | [diff] [blame] | 198 | |
Robert Relyea | 111a38b | 2010-11-28 16:36:38 +0200 | [diff] [blame] | 199 | QEMULIBS=libhw32 libhw64 libuser libdis libdis-user |
| 200 | |
bellard | 31e31b8 | 2003-02-18 22:55:36 +0000 | [diff] [blame] | 201 | clean: |
bellard | 2d80ae8 | 2003-08-11 23:01:33 +0000 | [diff] [blame] | 202 | # avoid old build problems by removing potentially incorrect old files |
Juan Quintela | 25be210f | 2009-10-07 02:41:00 +0200 | [diff] [blame] | 203 | 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] | 204 | rm -f qemu-options.def |
Michael Roth | 48ff7a6 | 2011-07-20 15:19:37 -0500 | [diff] [blame] | 205 | rm -f *.o *.d *.a *.lo $(TOOLS) qemu-ga TAGS cscope.* *.pod *~ */*~ |
Alon Levy | 44dc0ca | 2011-05-15 11:51:28 +0300 | [diff] [blame] | 206 | rm -Rf .libs |
Michael Roth | 13a286d | 2011-07-19 15:41:53 -0500 | [diff] [blame] | 207 | rm -f slirp/*.o slirp/*.d audio/*.o audio/*.d block/*.o block/*.d net/*.o net/*.d fsdev/*.o fsdev/*.d ui/*.o ui/*.d qapi/*.o qapi/*.d qga/*.o qga/*.d |
Blue Swirl | 07b44ce | 2009-06-09 18:45:16 +0000 | [diff] [blame] | 208 | rm -f qemu-img-cmds.h |
Blue Swirl | d7489b7 | 2010-10-09 08:24:17 +0000 | [diff] [blame] | 209 | rm -f trace.c trace.h trace.c-timestamp trace.h-timestamp |
Daniel P. Berrange | b3d08c0 | 2010-11-12 13:20:24 +0000 | [diff] [blame] | 210 | rm -f trace-dtrace.dtrace trace-dtrace.dtrace-timestamp |
| 211 | rm -f trace-dtrace.h trace-dtrace.h-timestamp |
Michael Roth | 640e540 | 2011-07-19 14:50:44 -0500 | [diff] [blame] | 212 | rm -rf $(qapi-dir) |
bellard | 7d3505c | 2004-05-12 19:32:15 +0000 | [diff] [blame] | 213 | $(MAKE) -C tests clean |
Robert Relyea | 111a38b | 2010-11-28 16:36:38 +0200 | [diff] [blame] | 214 | for d in $(ALL_SUBDIRS) $(QEMULIBS) libcacard; do \ |
Magnus Damm | fc8e320 | 2009-11-13 18:51:05 +0900 | [diff] [blame] | 215 | if test -d $$d; then $(MAKE) -C $$d $@ || exit 1; fi; \ |
Michael S. Tsirkin | df2943b | 2010-10-26 17:53:41 +0200 | [diff] [blame] | 216 | rm -f $$d/qemu-options.def; \ |
bellard | 626df76 | 2003-08-10 21:39:31 +0000 | [diff] [blame] | 217 | done |
bellard | 31e31b8 | 2003-02-18 22:55:36 +0000 | [diff] [blame] | 218 | |
bellard | 7d13299 | 2003-03-06 23:23:54 +0000 | [diff] [blame] | 219 | distclean: clean |
Magnus Damm | fc8e320 | 2009-11-13 18:51:05 +0900 | [diff] [blame] | 220 | rm -f config-host.mak config-host.h* config-host.ld $(DOCS) qemu-options.texi qemu-img-cmds.texi qemu-monitor.texi |
Paul Brook | a992fe3 | 2009-11-22 16:25:30 +0000 | [diff] [blame] | 221 | rm -f config-all-devices.mak |
Magnus Damm | fc8e320 | 2009-11-13 18:51:05 +0900 | [diff] [blame] | 222 | rm -f roms/seabios/config.mak roms/vgabios/config.mak |
Brad Hards | 7a734b8 | 2011-04-13 16:42:16 +1000 | [diff] [blame] | 223 | rm -f qemu-doc.info qemu-doc.aux qemu-doc.cp qemu-doc.cps qemu-doc.dvi |
| 224 | rm -f qemu-doc.fn qemu-doc.fns qemu-doc.info qemu-doc.ky qemu-doc.kys |
| 225 | rm -f qemu-doc.log qemu-doc.pdf qemu-doc.pg qemu-doc.toc qemu-doc.tp |
| 226 | rm -f qemu-doc.vr |
Hidetoshi Seto | e1a068b | 2010-07-08 14:26:18 +0900 | [diff] [blame] | 227 | 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 |
Robert Relyea | 111a38b | 2010-11-28 16:36:38 +0200 | [diff] [blame] | 228 | for d in $(TARGET_DIRS) $(QEMULIBS); do \ |
bellard | bc1b050 | 2003-10-28 00:12:52 +0000 | [diff] [blame] | 229 | rm -rf $$d || exit 1 ; \ |
bellard | 76bc683 | 2003-08-10 23:41:46 +0000 | [diff] [blame] | 230 | done |
bellard | 7d13299 | 2003-03-06 23:23:54 +0000 | [diff] [blame] | 231 | |
bellard | fed4a9a | 2004-12-12 22:18:34 +0000 | [diff] [blame] | 232 | KEYMAPS=da en-gb et fr fr-ch is lt modifiers no pt-br sv \ |
| 233 | ar de en-us fi fr-be hr it lv nl pl ru th \ |
| 234 | common de-ch es fo fr-ca hu ja mk nl-be pt sl tr |
| 235 | |
ths | 7775534 | 2008-11-27 15:45:16 +0000 | [diff] [blame] | 236 | ifdef INSTALL_BLOBS |
Gerd Hoffmann | 3b3d448 | 2010-08-23 12:10:46 +0200 | [diff] [blame] | 237 | BLOBS=bios.bin vgabios.bin vgabios-cirrus.bin \ |
Gerd Hoffmann | 7943a2f | 2010-11-30 11:54:33 +0100 | [diff] [blame] | 238 | vgabios-stdvga.bin vgabios-vmware.bin vgabios-qxl.bin \ |
Gerd Hoffmann | 3b3d448 | 2010-08-23 12:10:46 +0200 | [diff] [blame] | 239 | ppc_rom.bin openbios-sparc32 openbios-sparc64 openbios-ppc \ |
Alex Williamson | 5ee8ad7 | 2011-04-18 11:46:01 -0600 | [diff] [blame] | 240 | pxe-e1000.rom pxe-eepro100.rom pxe-ne2k_pci.rom \ |
| 241 | pxe-pcnet.rom pxe-rtl8139.rom pxe-virtio.rom \ |
Michal Simek | 00914b7 | 2011-03-14 11:29:19 +0100 | [diff] [blame] | 242 | bamboo.dtb petalogix-s3adsp1800.dtb petalogix-ml605.dtb \ |
Alexander Graf | fbd659b | 2011-05-25 23:49:41 +0200 | [diff] [blame] | 243 | mpc8544ds.dtb \ |
Alexander Graf | fe270d0 | 2010-04-20 19:37:13 +0200 | [diff] [blame] | 244 | multiboot.bin linuxboot.bin \ |
David Gibson | 39ac845 | 2011-04-01 15:15:23 +1100 | [diff] [blame] | 245 | s390-zipl.rom \ |
David Gibson | a9f8ad8 | 2011-04-01 15:15:34 +1100 | [diff] [blame] | 246 | spapr-rtas.bin slof.bin |
ths | 7775534 | 2008-11-27 15:45:16 +0000 | [diff] [blame] | 247 | else |
| 248 | BLOBS= |
| 249 | endif |
| 250 | |
pbrook | 38954dc | 2006-04-30 23:54:18 +0000 | [diff] [blame] | 251 | install-doc: $(DOCS) |
aliguori | 58f8aea | 2009-04-18 15:36:02 +0000 | [diff] [blame] | 252 | $(INSTALL_DIR) "$(DESTDIR)$(docdir)" |
| 253 | $(INSTALL_DATA) qemu-doc.html qemu-tech.html "$(DESTDIR)$(docdir)" |
Juan Quintela | 96d409e | 2009-08-03 14:47:00 +0200 | [diff] [blame] | 254 | ifdef CONFIG_POSIX |
aliguori | 58f8aea | 2009-04-18 15:36:02 +0000 | [diff] [blame] | 255 | $(INSTALL_DIR) "$(DESTDIR)$(mandir)/man1" |
| 256 | $(INSTALL_DATA) qemu.1 qemu-img.1 "$(DESTDIR)$(mandir)/man1" |
| 257 | $(INSTALL_DIR) "$(DESTDIR)$(mandir)/man8" |
| 258 | $(INSTALL_DATA) qemu-nbd.8 "$(DESTDIR)$(mandir)/man8" |
pbrook | 38954dc | 2006-04-30 23:54:18 +0000 | [diff] [blame] | 259 | endif |
| 260 | |
john cooper | b5ec5ce | 2010-02-20 11:14:59 -0600 | [diff] [blame] | 261 | install-sysconfig: |
Andre Przywara | 990caaf | 2010-03-08 15:43:41 +0100 | [diff] [blame] | 262 | $(INSTALL_DIR) "$(DESTDIR)$(sysconfdir)/qemu" |
| 263 | $(INSTALL_DATA) $(SRC_PATH)/sysconfigs/target/target-x86_64.conf "$(DESTDIR)$(sysconfdir)/qemu" |
john cooper | b5ec5ce | 2010-02-20 11:14:59 -0600 | [diff] [blame] | 264 | |
| 265 | install: all $(if $(BUILD_DOCS),install-doc) install-sysconfig |
aliguori | 58f8aea | 2009-04-18 15:36:02 +0000 | [diff] [blame] | 266 | $(INSTALL_DIR) "$(DESTDIR)$(bindir)" |
ths | 932a79d | 2007-10-20 18:29:34 +0000 | [diff] [blame] | 267 | ifneq ($(TOOLS),) |
aliguori | 58f8aea | 2009-04-18 15:36:02 +0000 | [diff] [blame] | 268 | $(INSTALL_PROG) $(STRIP_OPT) $(TOOLS) "$(DESTDIR)$(bindir)" |
ths | 932a79d | 2007-10-20 18:29:34 +0000 | [diff] [blame] | 269 | endif |
ths | 7775534 | 2008-11-27 15:45:16 +0000 | [diff] [blame] | 270 | ifneq ($(BLOBS),) |
aliguori | 58f8aea | 2009-04-18 15:36:02 +0000 | [diff] [blame] | 271 | $(INSTALL_DIR) "$(DESTDIR)$(datadir)" |
ths | 7775534 | 2008-11-27 15:45:16 +0000 | [diff] [blame] | 272 | set -e; for x in $(BLOBS); do \ |
aliguori | 58f8aea | 2009-04-18 15:36:02 +0000 | [diff] [blame] | 273 | $(INSTALL_DATA) $(SRC_PATH)/pc-bios/$$x "$(DESTDIR)$(datadir)"; \ |
pbrook | ad06484 | 2006-04-16 12:41:07 +0000 | [diff] [blame] | 274 | done |
ths | 7775534 | 2008-11-27 15:45:16 +0000 | [diff] [blame] | 275 | endif |
aliguori | 58f8aea | 2009-04-18 15:36:02 +0000 | [diff] [blame] | 276 | $(INSTALL_DIR) "$(DESTDIR)$(datadir)/keymaps" |
blueswir1 | 18be8d7 | 2008-03-05 18:16:09 +0000 | [diff] [blame] | 277 | set -e; for x in $(KEYMAPS); do \ |
Anthony Liguori | 79fd42a | 2009-05-28 03:11:42 -0500 | [diff] [blame] | 278 | $(INSTALL_DATA) $(SRC_PATH)/pc-bios/keymaps/$$x "$(DESTDIR)$(datadir)/keymaps"; \ |
pbrook | ad06484 | 2006-04-16 12:41:07 +0000 | [diff] [blame] | 279 | done |
bellard | 626df76 | 2003-08-10 21:39:31 +0000 | [diff] [blame] | 280 | for d in $(TARGET_DIRS); do \ |
bellard | 7d3505c | 2004-05-12 19:32:15 +0000 | [diff] [blame] | 281 | $(MAKE) -C $$d $@ || exit 1 ; \ |
bellard | 626df76 | 2003-08-10 21:39:31 +0000 | [diff] [blame] | 282 | done |
bellard | 612384d | 2003-03-22 17:31:19 +0000 | [diff] [blame] | 283 | |
bellard | 367e86e | 2003-03-01 17:13:26 +0000 | [diff] [blame] | 284 | # various test targets |
bellard | 9b0b820 | 2007-11-14 10:34:57 +0000 | [diff] [blame] | 285 | test speed: all |
bellard | 7d3505c | 2004-05-12 19:32:15 +0000 | [diff] [blame] | 286 | $(MAKE) -C tests $@ |
bellard | 31e31b8 | 2003-02-18 22:55:36 +0000 | [diff] [blame] | 287 | |
Alexandre Bique | 21d4e8e | 2009-08-07 15:43:11 +0100 | [diff] [blame] | 288 | .PHONY: TAGS |
ths | 5fafdf2 | 2007-09-16 21:08:06 +0000 | [diff] [blame] | 289 | TAGS: |
Alexandre Bique | 21d4e8e | 2009-08-07 15:43:11 +0100 | [diff] [blame] | 290 | find "$(SRC_PATH)" -name '*.[hc]' -print0 | xargs -0 etags |
bellard | 31e31b8 | 2003-02-18 22:55:36 +0000 | [diff] [blame] | 291 | |
bellard | 6688bc6 | 2005-08-21 09:23:39 +0000 | [diff] [blame] | 292 | cscope: |
| 293 | rm -f ./cscope.* |
aurel32 | ede4608 | 2008-10-01 21:46:58 +0000 | [diff] [blame] | 294 | find . -name "*.[ch]" -print | sed 's,^\./,,' > ./cscope.files |
bellard | 6688bc6 | 2005-08-21 09:23:39 +0000 | [diff] [blame] | 295 | cscope -b |
| 296 | |
bellard | 3ef693a | 2003-03-23 20:17:16 +0000 | [diff] [blame] | 297 | # documentation |
Stefan Weil | 01668d9 | 2010-03-04 22:21:02 +0100 | [diff] [blame] | 298 | MAKEINFO=makeinfo |
| 299 | MAKEINFOFLAGS=--no-headers --no-split --number-sections |
Stefan Weil | 20cc999 | 2010-01-29 23:16:50 +0100 | [diff] [blame] | 300 | TEXIFLAG=$(if $(V),,--quiet) |
| 301 | %.dvi: %.texi |
| 302 | $(call quiet-command,texi2dvi $(TEXIFLAG) -I . $<," GEN $@") |
| 303 | |
bellard | 1f67313 | 2004-04-04 15:21:17 +0000 | [diff] [blame] | 304 | %.html: %.texi |
Stefan Weil | 01668d9 | 2010-03-04 22:21:02 +0100 | [diff] [blame] | 305 | $(call quiet-command,$(MAKEINFO) $(MAKEINFOFLAGS) --html $< -o $@, \ |
| 306 | " GEN $@") |
bellard | 3ef693a | 2003-03-23 20:17:16 +0000 | [diff] [blame] | 307 | |
bellard | f354832 | 2006-04-30 22:51:54 +0000 | [diff] [blame] | 308 | %.info: %.texi |
Stefan Weil | 01668d9 | 2010-03-04 22:21:02 +0100 | [diff] [blame] | 309 | $(call quiet-command,$(MAKEINFO) $< -o $@," GEN $@") |
bellard | f354832 | 2006-04-30 22:51:54 +0000 | [diff] [blame] | 310 | |
Stefan Weil | 20cc999 | 2010-01-29 23:16:50 +0100 | [diff] [blame] | 311 | %.pdf: %.texi |
| 312 | $(call quiet-command,texi2pdf $(TEXIFLAG) -I . $<," GEN $@") |
blueswir1 | 5824d65 | 2009-03-28 06:44:27 +0000 | [diff] [blame] | 313 | |
| 314 | qemu-options.texi: $(SRC_PATH)/qemu-options.hx |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 315 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -t < $< > $@," GEN $@") |
bellard | f354832 | 2006-04-30 22:51:54 +0000 | [diff] [blame] | 316 | |
Luiz Capitulino | acd0a09 | 2010-09-30 16:00:22 -0300 | [diff] [blame] | 317 | qemu-monitor.texi: $(SRC_PATH)/hmp-commands.hx |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 318 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -t < $< > $@," GEN $@") |
Blue Swirl | 2313086 | 2009-06-06 08:22:04 +0000 | [diff] [blame] | 319 | |
Luiz Capitulino | 82a56f0 | 2010-09-13 12:26:00 -0300 | [diff] [blame] | 320 | QMP/qmp-commands.txt: $(SRC_PATH)/qmp-commands.hx |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 321 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -q < $< > $@," GEN $@") |
Jan Kiszka | b40292e | 2010-05-31 14:43:31 -0300 | [diff] [blame] | 322 | |
Stuart Brady | 153859b | 2009-06-07 00:42:17 +0100 | [diff] [blame] | 323 | qemu-img-cmds.texi: $(SRC_PATH)/qemu-img-cmds.hx |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 324 | $(call quiet-command,sh $(SRC_PATH)/scripts/hxtool -t < $< > $@," GEN $@") |
Stuart Brady | 153859b | 2009-06-07 00:42:17 +0100 | [diff] [blame] | 325 | |
Blue Swirl | 2313086 | 2009-06-06 08:22:04 +0000 | [diff] [blame] | 326 | qemu.1: qemu-doc.texi qemu-options.texi qemu-monitor.texi |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 327 | $(call quiet-command, \ |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 328 | perl -Ww -- $(SRC_PATH)/scripts/texi2pod.pl $< qemu.pod && \ |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 329 | pod2man --section=1 --center=" " --release=" " qemu.pod > $@, \ |
| 330 | " GEN $@") |
bellard | 5a67135 | 2003-10-01 00:13:48 +0000 | [diff] [blame] | 331 | |
Stuart Brady | 153859b | 2009-06-07 00:42:17 +0100 | [diff] [blame] | 332 | qemu-img.1: qemu-img.texi qemu-img-cmds.texi |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 333 | $(call quiet-command, \ |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 334 | perl -Ww -- $(SRC_PATH)/scripts/texi2pod.pl $< qemu-img.pod && \ |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 335 | pod2man --section=1 --center=" " --release=" " qemu-img.pod > $@, \ |
| 336 | " GEN $@") |
bellard | acd935e | 2004-11-15 22:57:26 +0000 | [diff] [blame] | 337 | |
bellard | 7a5ca86 | 2008-05-27 21:13:40 +0000 | [diff] [blame] | 338 | qemu-nbd.8: qemu-nbd.texi |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 339 | $(call quiet-command, \ |
Blue Swirl | 4c3b5a4 | 2011-01-20 20:54:21 +0000 | [diff] [blame] | 340 | perl -Ww -- $(SRC_PATH)/scripts/texi2pod.pl $< qemu-nbd.pod && \ |
aliguori | 0d00e56 | 2009-04-05 17:40:46 +0000 | [diff] [blame] | 341 | pod2man --section=8 --center=" " --release=" " qemu-nbd.pod > $@, \ |
| 342 | " GEN $@") |
bellard | 7a5ca86 | 2008-05-27 21:13:40 +0000 | [diff] [blame] | 343 | |
pbrook | 0cb3fb1 | 2006-05-14 12:07:53 +0000 | [diff] [blame] | 344 | dvi: qemu-doc.dvi qemu-tech.dvi |
pbrook | 0cb3fb1 | 2006-05-14 12:07:53 +0000 | [diff] [blame] | 345 | html: qemu-doc.html qemu-tech.html |
Stefan Weil | 20cc999 | 2010-01-29 23:16:50 +0100 | [diff] [blame] | 346 | info: qemu-doc.info qemu-tech.info |
| 347 | pdf: qemu-doc.pdf qemu-tech.pdf |
pbrook | 0cb3fb1 | 2006-05-14 12:07:53 +0000 | [diff] [blame] | 348 | |
Stefan Weil | 20cc999 | 2010-01-29 23:16:50 +0100 | [diff] [blame] | 349 | qemu-doc.dvi qemu-doc.html qemu-doc.info qemu-doc.pdf: \ |
| 350 | qemu-img.texi qemu-nbd.texi qemu-options.texi \ |
| 351 | qemu-monitor.texi qemu-img-cmds.texi |
aliguori | 818220f | 2008-09-24 01:13:40 +0000 | [diff] [blame] | 352 | |
ths | df5cf72 | 2007-01-24 22:56:36 +0000 | [diff] [blame] | 353 | VERSION ?= $(shell cat VERSION) |
| 354 | FILE = qemu-$(VERSION) |
bellard | 586314f | 2003-03-03 15:02:29 +0000 | [diff] [blame] | 355 | |
bellard | 1e43adf | 2003-09-30 20:54:24 +0000 | [diff] [blame] | 356 | # tar release (use 'make -k tar' on a checkouted tree) |
bellard | 586314f | 2003-03-03 15:02:29 +0000 | [diff] [blame] | 357 | tar: |
| 358 | rm -rf /tmp/$(FILE) |
bellard | 1e43adf | 2003-09-30 20:54:24 +0000 | [diff] [blame] | 359 | cp -r . /tmp/$(FILE) |
aurel32 | 99c6c08 | 2008-04-22 20:45:30 +0000 | [diff] [blame] | 360 | cd /tmp && tar zcvf ~/$(FILE).tar.gz $(FILE) --exclude CVS --exclude .git --exclude .svn |
bellard | 586314f | 2003-03-03 15:02:29 +0000 | [diff] [blame] | 361 | rm -rf /tmp/$(FILE) |
| 362 | |
Stuart Brady | 4c0a6db | 2010-05-12 20:42:04 +0100 | [diff] [blame] | 363 | SYSTEM_TARGETS=$(filter %-softmmu,$(TARGET_DIRS)) |
| 364 | SYSTEM_PROGS=$(patsubst qemu-system-i386,qemu, \ |
| 365 | $(patsubst %-softmmu,qemu-system-%, \ |
| 366 | $(SYSTEM_TARGETS))) |
| 367 | |
| 368 | USER_TARGETS=$(filter %-user,$(TARGET_DIRS)) |
| 369 | USER_PROGS=$(patsubst %-bsd-user,qemu-%, \ |
| 370 | $(patsubst %-darwin-user,qemu-%, \ |
| 371 | $(patsubst %-linux-user,qemu-%, \ |
| 372 | $(USER_TARGETS)))) |
| 373 | |
bellard | 76b62fd | 2003-10-28 00:47:44 +0000 | [diff] [blame] | 374 | # generate a binary distribution |
bellard | d691f66 | 2003-03-24 21:58:34 +0000 | [diff] [blame] | 375 | tarbin: |
blueswir1 | 18be8d7 | 2008-03-05 18:16:09 +0000 | [diff] [blame] | 376 | cd / && tar zcvf ~/qemu-$(VERSION)-$(ARCH).tar.gz \ |
Stuart Brady | 4c0a6db | 2010-05-12 20:42:04 +0100 | [diff] [blame] | 377 | $(patsubst %,$(bindir)/%, $(SYSTEM_PROGS)) \ |
| 378 | $(patsubst %,$(bindir)/%, $(USER_PROGS)) \ |
aurel32 | 40e8a53 | 2009-01-03 12:35:57 +0000 | [diff] [blame] | 379 | $(bindir)/qemu-img \ |
| 380 | $(bindir)/qemu-nbd \ |
bellard | 7efa438 | 2004-05-12 18:54:06 +0000 | [diff] [blame] | 381 | $(datadir)/bios.bin \ |
| 382 | $(datadir)/vgabios.bin \ |
bellard | de9258a | 2004-06-06 15:50:03 +0000 | [diff] [blame] | 383 | $(datadir)/vgabios-cirrus.bin \ |
bellard | 637f6cd | 2004-06-21 19:54:47 +0000 | [diff] [blame] | 384 | $(datadir)/ppc_rom.bin \ |
bellard | 0986ac3 | 2006-06-14 12:36:32 +0000 | [diff] [blame] | 385 | $(datadir)/openbios-sparc32 \ |
blueswir1 | 938255d | 2008-04-23 19:38:07 +0000 | [diff] [blame] | 386 | $(datadir)/openbios-sparc64 \ |
aurel32 | e5d01b0 | 2009-01-09 11:01:31 +0000 | [diff] [blame] | 387 | $(datadir)/openbios-ppc \ |
Alex Williamson | 5ee8ad7 | 2011-04-18 11:46:01 -0600 | [diff] [blame] | 388 | $(datadir)/pxe-e1000.rom \ |
| 389 | $(datadir)/pxe-eepro100.rom \ |
| 390 | $(datadir)/pxe-ne2k_pci.rom \ |
| 391 | $(datadir)/pxe-pcnet.rom \ |
| 392 | $(datadir)/pxe-rtl8139.rom \ |
| 393 | $(datadir)/pxe-virtio.rom \ |
bellard | 1f50f8d | 2004-05-08 14:44:43 +0000 | [diff] [blame] | 394 | $(docdir)/qemu-doc.html \ |
| 395 | $(docdir)/qemu-tech.html \ |
aurel32 | 40e8a53 | 2009-01-03 12:35:57 +0000 | [diff] [blame] | 396 | $(mandir)/man1/qemu.1 \ |
| 397 | $(mandir)/man1/qemu-img.1 \ |
bellard | 7a5ca86 | 2008-05-27 21:13:40 +0000 | [diff] [blame] | 398 | $(mandir)/man8/qemu-nbd.8 |
bellard | d691f66 | 2003-03-24 21:58:34 +0000 | [diff] [blame] | 399 | |
bellard | 4fb240a | 2007-11-07 19:24:02 +0000 | [diff] [blame] | 400 | # Include automatically generated dependency files |
Michael Roth | 48ff7a6 | 2011-07-20 15:19:37 -0500 | [diff] [blame] | 401 | -include $(wildcard *.d audio/*.d slirp/*.d block/*.d net/*.d ui/*.d qapi/*.d qga/*.d) |