blob: bfd5a6ceb1cc50226bfdfc0705684032fe9690a6 [file] [log] [blame]
Andreas Färber0e8c9212010-01-06 20:24:05 +01001#######################################################################
Paolo Bonzinia3728232012-12-20 16:10:26 +01002# Common libraries for tools and emulators
Daniel P. Berrangeb917da42015-10-31 14:39:52 +09003stub-obj-y = stubs/ crypto/
Markus Armbruster39a18152015-09-16 13:06:28 +02004util-obj-y = util/ qobject/ qapi/
5util-obj-y += qmp-introspect.o qapi-types.o qapi-visit.o qapi-event.o
Paolo Bonzini3bc2f572012-11-16 18:35:27 +01006
Marc-André Lureau32d955a2016-12-12 15:49:01 +03007chardev-obj-y = chardev/
8
Paolo Bonzini3bc2f572012-11-16 18:35:27 +01009#######################################################################
Andreas Färber0e8c9212010-01-06 20:24:05 +010010# block-obj-y is code used by both qemu system emulation and qemu-img
11
Fam Zheng798bfe02016-01-14 16:41:02 +080012block-obj-y += nbd/
13block-obj-y += block.o blockjob.o
Paolo Bonzini7456e4c2012-05-22 13:44:39 +020014block-obj-y += block/
Kevin Wolf587da2c2013-06-05 14:19:41 +020015block-obj-y += qemu-io-cmds.o
Changlong Xie190b9a82016-07-27 15:01:49 +080016block-obj-$(CONFIG_REPLICATION) += replication.o
Andreas Färber0e8c9212010-01-06 20:24:05 +010017
Fam Zhengcc475692014-02-10 14:48:59 +080018block-obj-m = block/
19
Daniel P. Berrangefb377262015-09-02 10:57:27 +010020#######################################################################
21# crypto-obj-y is code used by both qemu system emulation and qemu-img
22
23crypto-obj-y = crypto/
24crypto-aes-obj-y = crypto/
Gautham R Shenoy74db9202010-04-29 17:44:43 +053025
Daniel P. Berrange0c7012e2015-09-02 11:18:16 +010026#######################################################################
27# qom-obj-y is code used by both qemu system emulation and qemu-img
28
29qom-obj-y = qom/
30
Daniel P. Berrange666a3af2015-02-27 16:19:33 +000031#######################################################################
32# io-obj-y is code used by both qemu system emulation and qemu-img
33
34io-obj-y = io/
35
Andreas Färber0e8c9212010-01-06 20:24:05 +010036######################################################################
Chen Wei-Ren050d9942011-11-15 20:47:11 +080037# Target independent part of system emulation. The long term path is to
38# suppress *all* target specific code in case of system emulation, i.e. a
39# single QEMU executable should support all CPUs and machines.
Andreas Färber0e8c9212010-01-06 20:24:05 +010040
Paolo Bonzini00082342013-01-19 11:06:47 +010041ifeq ($(CONFIG_SOFTMMU),y)
Fam Zhengba1183d2014-02-10 14:48:52 +080042common-obj-y = blockdev.o blockdev-nbd.o block/
Thomas Huth5ddc6482017-06-26 07:22:57 +020043common-obj-y += bootdevice.o iothread.o
Paolo Bonzinifd9400b2012-10-24 11:27:28 +020044common-obj-y += net/
Paolo Bonzini1559e0d2013-02-04 17:20:47 +010045common-obj-y += qdev-monitor.o device-hotplug.o
Blue Swirlb0cb640a2010-06-12 05:49:30 +000046common-obj-$(CONFIG_WIN32) += os-win32.o
47common-obj-$(CONFIG_POSIX) += os-posix.o
Gerd Hoffmann254e5952010-05-21 11:54:32 +020048
Paolo Bonziniee204772012-05-22 13:46:08 +020049common-obj-$(CONFIG_LINUX) += fsdev/
Paolo Bonziniee204772012-05-22 13:46:08 +020050
Dr. David Alan Gilbert60fe6372014-12-12 11:13:38 +000051common-obj-y += migration/
Andreas Färber0e8c9212010-01-06 20:24:05 +010052
Paolo Bonzinib0b68fc2012-05-22 13:49:02 +020053common-obj-y += audio/
Paolo Bonzini3d5a3f92012-05-29 11:08:47 +020054common-obj-y += hw/
Paolo Bonzini6f991982012-12-17 18:17:08 +010055
Pavel Dovgalyukd73abd62015-09-17 19:23:37 +030056common-obj-y += replay/
57
Paolo Bonzini8867aef2012-05-22 13:48:15 +020058common-obj-y += ui/
Paolo Bonzini3d5a3f92012-05-29 11:08:47 +020059common-obj-y += bt-host.o bt-vhci.o
Michael Tokarev849d8282014-05-02 15:40:53 +040060bt-host.o-cflags := $(BLUEZ_CFLAGS)
Corentin Chary3e230dd2010-07-07 20:57:52 +020061
Stefan Weilc9159fe2012-10-05 19:39:33 +020062common-obj-y += dma-helpers.o
Stefan Weilc9159fe2012-10-05 19:39:33 +020063common-obj-y += vl.o
Michael Tokarev849d8282014-05-02 15:40:53 +040064vl.o-cflags := $(GPROF_CFLAGS) $(SDL_CFLAGS)
Paolo Bonzinibdee56f2013-04-02 18:28:41 +020065common-obj-y += tpm.o
Andreas Färber0e8c9212010-01-06 20:24:05 +010066
Paolo Bonzini4c696052012-05-22 13:49:43 +020067common-obj-$(CONFIG_SLIRP) += slirp/
Andreas Färber0e8c9212010-01-06 20:24:05 +010068
Anthony Liguoria9b7b2a2012-06-25 10:03:47 -050069common-obj-y += backends/
Marc-André Lureau6b10e572017-05-29 12:39:42 +040070common-obj-y += chardev/
Anthony Liguoria9b7b2a2012-06-25 10:03:47 -050071
Paolo Bonzini737f3512013-01-19 11:06:46 +010072common-obj-$(CONFIG_SECCOMP) += qemu-seccomp.o
Eduardo Otubof7945732012-08-14 18:44:05 -030073
Peter Crosthwaite7df057b2015-05-24 13:20:14 -070074common-obj-$(CONFIG_FDT) += device_tree.o
75
Michael Roth2345c772011-07-19 14:50:32 -050076######################################################################
77# qapi
78
Eduardo Habkost8e8aba52013-05-06 13:20:07 -030079common-obj-y += qmp-marshal.o
Markus Armbruster39a18152015-09-16 13:06:28 +020080common-obj-y += qmp-introspect.o
Anthony Liguori48a32be2011-09-02 12:34:48 -050081common-obj-y += qmp.o hmp.o
Paolo Bonzini00082342013-01-19 11:06:47 +010082endif
Anthony Liguorie3193602011-09-02 12:34:47 -050083
Paolo Bonzini9444e9e2012-12-20 15:24:49 +010084#######################################################################
85# Target-independent parts used in system and user emulation
Richard Hendersonc482cb12016-06-28 11:37:27 -070086common-obj-y += cpus-common.o
Paolo Bonzini00082342013-01-19 11:06:47 +010087common-obj-y += hw/
88common-obj-y += qom/
89common-obj-y += disas/
Andreas Färberce008c12012-03-04 21:32:36 +010090
Michael Roth957f1f92011-08-11 15:38:12 -050091######################################################################
Stefan Weil0b516ef2013-08-08 20:18:07 +020092# Resource file for Windows executables
93version-obj-$(CONFIG_WIN32) += $(BUILD_DIR)/version.o
Stefan Weil0b516ef2013-08-08 20:18:07 +020094
95######################################################################
Lluís Vilanova341ea692014-05-30 14:11:56 +020096# tracing
97util-obj-y += trace/
98target-obj-y += trace/
99
100######################################################################
Michael Roth957f1f92011-08-11 15:38:12 -0500101# guest agent
102
Paolo Bonzini59cacde2012-12-20 15:03:18 +0100103# FIXME: a few definitions from qapi-types.o/qapi-visit.o are needed
104# by libqemuutil.a. These should be moved to a separate .json schema.
Fam Zheng169a24a2014-08-07 10:34:41 +0800105qga-obj-y = qga/
Tomoki Sekiyamab39297a2013-08-07 11:40:18 -0400106qga-vss-dll-obj-y = qga/
David Marchanda75eb032014-09-08 11:17:48 +0200107
108######################################################################
109# contrib
110ivshmem-client-obj-y = contrib/ivshmem-client/
111ivshmem-server-obj-y = contrib/ivshmem-server/
Marc-André Lureau7b2e5c62016-10-18 12:24:04 +0300112libvhost-user-obj-y = contrib/libvhost-user/
Felipe Franciosi49cc0342017-03-02 10:25:53 -0800113vhost-user-scsi.o-cflags := $(LIBISCSI_CFLAGS)
114vhost-user-scsi.o-libs := $(LIBISCSI_LIBS)
115vhost-user-scsi-obj-y = contrib/vhost-user-scsi/
116vhost-user-scsi-obj-y += contrib/libvhost-user/libvhost-user.o
Daniel P. Berrange1412cf52016-06-16 09:39:47 +0100117
118######################################################################
Daniel P. Berrange0ab8ed12017-01-25 16:14:15 +0000119trace-events-subdirs =
120trace-events-subdirs += util
121trace-events-subdirs += crypto
122trace-events-subdirs += io
123trace-events-subdirs += migration
124trace-events-subdirs += block
Marc-André Lureau6b10e572017-05-29 12:39:42 +0400125trace-events-subdirs += chardev
Daniel P. Berrange0ab8ed12017-01-25 16:14:15 +0000126trace-events-subdirs += hw/block
127trace-events-subdirs += hw/block/dataplane
128trace-events-subdirs += hw/char
129trace-events-subdirs += hw/intc
130trace-events-subdirs += hw/net
131trace-events-subdirs += hw/virtio
132trace-events-subdirs += hw/audio
133trace-events-subdirs += hw/misc
134trace-events-subdirs += hw/usb
135trace-events-subdirs += hw/scsi
136trace-events-subdirs += hw/nvram
137trace-events-subdirs += hw/display
138trace-events-subdirs += hw/input
139trace-events-subdirs += hw/timer
140trace-events-subdirs += hw/dma
141trace-events-subdirs += hw/sparc
142trace-events-subdirs += hw/sd
143trace-events-subdirs += hw/isa
144trace-events-subdirs += hw/mem
145trace-events-subdirs += hw/i386
146trace-events-subdirs += hw/i386/xen
147trace-events-subdirs += hw/9pfs
148trace-events-subdirs += hw/ppc
149trace-events-subdirs += hw/pci
150trace-events-subdirs += hw/s390x
151trace-events-subdirs += hw/vfio
152trace-events-subdirs += hw/acpi
153trace-events-subdirs += hw/arm
154trace-events-subdirs += hw/alpha
155trace-events-subdirs += hw/xen
156trace-events-subdirs += ui
157trace-events-subdirs += audio
158trace-events-subdirs += net
159trace-events-subdirs += target/arm
160trace-events-subdirs += target/i386
Philippe Mathieu-Daudéb44a7fb2017-03-04 15:56:52 -0300161trace-events-subdirs += target/mips
Daniel P. Berrange0ab8ed12017-01-25 16:14:15 +0000162trace-events-subdirs += target/sparc
163trace-events-subdirs += target/s390x
164trace-events-subdirs += target/ppc
165trace-events-subdirs += qom
166trace-events-subdirs += linux-user
167trace-events-subdirs += qapi
Yang Zhongd9bb58e2017-06-02 14:06:44 +0800168trace-events-subdirs += accel/tcg
Yang Zhong92229a52017-06-02 14:06:46 +0800169trace-events-subdirs += accel/kvm
Vladimir Sementsov-Ogievskiy95884632017-07-07 18:29:18 +0300170trace-events-subdirs += nbd
Daniel P. Berrange0ab8ed12017-01-25 16:14:15 +0000171
172trace-events-files = $(SRC_PATH)/trace-events $(trace-events-subdirs:%=$(SRC_PATH)/%/trace-events)
173
174trace-obj-y = trace-root.o
175trace-obj-y += $(trace-events-subdirs:%=%/trace.o)
176trace-obj-$(CONFIG_TRACE_UST) += trace-ust-all.o
177trace-obj-$(CONFIG_TRACE_DTRACE) += trace-dtrace-root.o
178trace-obj-$(CONFIG_TRACE_DTRACE) += $(trace-events-subdirs:%=%/trace-dtrace.o)