2 include $(SRC_PATH)/rules.mak
4 TARGET_BASE_ARCH:=$(TARGET_ARCH)
5 ifeq ($(TARGET_ARCH), x86_64)
8 ifeq ($(TARGET_ARCH), mipsn32)
11 ifeq ($(TARGET_ARCH), mips64)
12 TARGET_BASE_ARCH:=mips
14 ifeq ($(TARGET_ARCH), ppc64)
17 ifeq ($(TARGET_ARCH), ppc64h)
20 ifeq ($(TARGET_ARCH), ppcemb)
23 ifeq ($(TARGET_ARCH), sparc64)
24 TARGET_BASE_ARCH:=sparc
26 TARGET_PATH=$(SRC_PATH)/target-$(TARGET_BASE_ARCH)
27 VPATH=$(SRC_PATH):$(TARGET_PATH):$(SRC_PATH)/hw
28 CPPFLAGS=-I. -I.. -I$(TARGET_PATH) -I$(SRC_PATH) -MMD -MT $@ -MP -DNEED_CPU_H
33 TARGET_ARCH2=$(TARGET_ARCH)
35 ifeq ($(TARGET_ARCH),arm)
36 ifeq ($(TARGET_WORDS_BIGENDIAN),yes)
40 ifeq ($(TARGET_ARCH),sh4)
41 ifeq ($(TARGET_WORDS_BIGENDIAN),yes)
45 ifeq ($(TARGET_ARCH),mips)
46 ifneq ($(TARGET_WORDS_BIGENDIAN),yes)
50 ifeq ($(TARGET_ARCH),mipsn32)
51 ifneq ($(TARGET_WORDS_BIGENDIAN),yes)
52 TARGET_ARCH2=mipsn32el
55 ifeq ($(TARGET_ARCH),mips64)
56 ifneq ($(TARGET_WORDS_BIGENDIAN),yes)
61 ifdef CONFIG_USER_ONLY
63 QEMU_PROG=qemu-$(TARGET_ARCH2)
65 # system emulator name
66 ifeq ($(TARGET_ARCH), i386)
67 QEMU_PROG=qemu$(EXESUF)
69 QEMU_PROG=qemu-system-$(TARGET_ARCH2)$(EXESUF)
76 # Usage: CFLAGS+=$(call cc-option, $(CFLAGS), -falign-functions=0, -malign-functions=0)
78 cc-option = $(shell if $(CC) $(1) $(2) -S -o /dev/null -xc /dev/null \
79 > /dev/null 2>&1; then echo "$(2)"; else echo "$(3)"; fi ;)
84 HELPER_CFLAGS+=-fomit-frame-pointer
87 ifeq ($(subst ppc64,ppc,$(ARCH))$(TARGET_BASE_ARCH),ppcppc)
88 translate.o: CFLAGS := $(CFLAGS) $(call cc-option, $(CFLAGS), -fno-unit-at-a-time,)
92 ifneq ($(CONFIG_SOLARIS),y)
93 HELPER_CFLAGS+=-ffixed-i0
98 # Ensure there's only a single GP
103 BASE_LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
110 CFLAGS+=$(OS_CFLAGS) $(ARCH_CFLAGS)
111 LDFLAGS+=$(OS_LDFLAGS) $(ARCH_LDFLAGS)
113 CPPFLAGS+=-D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE
114 CPPFLAGS+=-U_FORTIFY_SOURCE
117 LIBS+=-lwinmm -lws2_32 -liphlpapi
120 LIBS+=-lsocket -lnsl -lresolv
121 ifdef NEEDS_LIBSUNMATH
123 LDFLAGS+=-L/opt/SUNWspro/prod/lib -R/opt/SUNWspro/prod/lib
124 CFLAGS+=-I/opt/SUNWspro/prod/include/cc
128 kvm.o: CFLAGS+=$(KVM_CFLAGS)
129 kvm-all.o: CFLAGS+=$(KVM_CFLAGS)
132 # Dummy command so that make thinks it has done something
135 #########################################################
136 # cpu emulator library
137 libobj-y = exec.o translate-all.o cpu-exec.o translate.o host-utils.o
138 libobj-$(CONFIG_KQEMU) += kqemu.o
140 libobj-y += tcg/tcg.o tcg/tcg-runtime.o
141 CPPFLAGS+=-I$(SRC_PATH)/tcg -I$(SRC_PATH)/tcg/$(ARCH)
142 ifeq ($(ARCH),sparc64)
143 CPPFLAGS+=-I$(SRC_PATH)/tcg/sparc
145 ifdef CONFIG_SOFTFLOAT
146 libobj-y += fpu/softfloat.o
148 libobj-y += fpu/softfloat-native.o
150 CPPFLAGS+=-I$(SRC_PATH)/fpu
151 libobj-y += op_helper.o helper.o
153 ifeq ($(TARGET_BASE_ARCH), arm)
154 libobj-y += neon_helper.o iwmmxt_helper.o
157 ifeq ($(TARGET_BASE_ARCH), alpha)
158 libobj-y += alpha_palcode.o
161 ifeq ($(TARGET_BASE_ARCH), cris)
162 libobj-y += cris-dis.o
164 ifndef CONFIG_USER_ONLY
169 # NOTE: the disassembler code is only needed for debugging
171 ifeq ($(findstring i386, $(TARGET_ARCH) $(ARCH)),i386)
174 ifeq ($(findstring x86_64, $(TARGET_ARCH) $(ARCH)),x86_64)
177 libobj-$(USE_I386_DIS) += i386-dis.o
178 ifeq ($(findstring alpha, $(TARGET_ARCH) $(ARCH)),alpha)
179 libobj-y += alpha-dis.o
181 ifeq ($(findstring ppc, $(TARGET_BASE_ARCH) $(ARCH)),ppc)
182 libobj-y += ppc-dis.o
184 ifeq ($(findstring microblaze, $(TARGET_BASE_ARCH) $(ARCH)),microblaze)
185 libobj-y += microblaze-dis.o
186 ifndef CONFIG_USER_ONLY
190 ifeq ($(findstring mips, $(TARGET_BASE_ARCH) $(ARCH)),mips)
191 libobj-y += mips-dis.o
193 ifeq ($(findstring sparc, $(TARGET_BASE_ARCH) $(ARCH)),sparc)
194 libobj-y += sparc-dis.o
196 ifeq ($(findstring arm, $(TARGET_ARCH) $(ARCH)),arm)
197 libobj-y += arm-dis.o
199 ifeq ($(findstring m68k, $(TARGET_ARCH) $(ARCH)),m68k)
200 libobj-y += m68k-dis.o
202 ifeq ($(findstring sh4, $(TARGET_ARCH) $(ARCH)),sh4)
203 libobj-y += sh4-dis.o
205 ifeq ($(findstring hppa, $(TARGET_BASE_ARCH) $(ARCH)),hppa)
206 libobj-y += hppa-dis.o
208 ifeq ($(findstring s390, $(TARGET_ARCH) $(ARCH)),s390)
209 libobj-y += s390-dis.o
214 libqemu.a: $(libobj-y)
216 translate.o: translate.c cpu.h
218 translate-all.o: translate-all.c cpu.h
222 # HELPER_CFLAGS is used for all the code compiled with static register
224 op_helper.o: CFLAGS += $(HELPER_CFLAGS)
226 cpu-exec.o: CFLAGS += $(HELPER_CFLAGS)
228 #########################################################
229 # Linux user emulator target
231 ifdef CONFIG_LINUX_USER
233 ifndef TARGET_ABI_DIR
234 TARGET_ABI_DIR=$(TARGET_ARCH)
236 VPATH+=:$(SRC_PATH)/linux-user:$(SRC_PATH)/linux-user/$(TARGET_ABI_DIR)
237 CPPFLAGS+=-I$(SRC_PATH)/linux-user -I$(SRC_PATH)/linux-user/$(TARGET_ABI_DIR)
251 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
253 # WARNING: this LDFLAGS is _very_ tricky : qemu is an ELF shared object
254 # that the kernel ELF loader considers as an executable. I think this
255 # is the simplest way to make it self virtualizable!
260 ifeq ($(ARCH),x86_64)
261 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
265 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
269 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
273 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
277 # -static is used to avoid g1/g3 usage by the dynamic linker
278 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld -static
281 ifeq ($(ARCH),sparc64)
282 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
286 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
290 LDFLAGS+=-Wl,-G0 -Wl,-T,$(SRC_PATH)/$(ARCH).ld
294 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
298 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
302 ifeq ($(WORDS_BIGENDIAN),yes)
303 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
305 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH)el.ld
309 ifeq ($(ARCH),mips64)
310 ifeq ($(WORDS_BIGENDIAN),yes)
311 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
313 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH)el.ld
323 obj-y = main.o syscall.o strace.o mmap.o signal.o path.o thunk.o \
324 elfload.o linuxload.o uaccess.o envlist.o gdbstub.o gdbstub-xml.o \
326 LIBS+= $(PTHREADLIBS)
328 obj-$(TARGET_HAS_BFLT) += flatload.o
330 ifdef TARGET_HAS_ELFLOAD32
331 elfload32.o: elfload.c
333 obj-$(TARGET_HAS_ELFLOAD32) += elfload32.o
335 ifeq ($(TARGET_ARCH), i386)
338 ifeq ($(TARGET_ARCH), arm)
339 nwfpe-obj-y := fpa11.o fpa11_cpdo.o fpa11_cpdt.o fpa11_cprt.o fpopcode.o
340 nwfpe-obj-y += single_cpdo.o double_cpdo.o extended_cpdo.o
341 obj-y += $(addprefix nwfpe/, $(nwfpe-obj-y))
344 ifeq ($(TARGET_ARCH), m68k)
345 obj-y += m68k-sim.o m68k-semi.o
348 # Note: this is a workaround. The real fix is to avoid compiling
349 # cpu_signal_handler() in cpu-exec.c.
350 signal.o: CFLAGS += $(HELPER_CFLAGS)
352 $(QEMU_PROG): ARLIBS=../libqemu_user.a libqemu.a
353 $(QEMU_PROG): $(obj-y) ../libqemu_user.a libqemu.a
354 $(call LINK,$(obj-y))
356 # Mark as 32 bit binary, i. e. it will be mapped into the low 31 bit of
357 # the address space (31 bit so sign extending doesn't matter)
358 echo -ne '\001\000\000\000' | dd of=qemu bs=1 seek=48 count=4 conv=notrunc
361 endif #CONFIG_LINUX_USER
363 #########################################################
364 # Darwin user emulator target
366 ifdef CONFIG_DARWIN_USER
368 VPATH+=:$(SRC_PATH)/darwin-user
369 CPPFLAGS+=-I$(SRC_PATH)/darwin-user -I$(SRC_PATH)/darwin-user/$(TARGET_ARCH)
371 # Leave some space for the regular program loading zone
372 LDFLAGS+=-Wl,-segaddr,__STD_PROG_ZONE,0x1000 -image_base 0x0e000000
376 obj-y = main.o commpage.o machload.o mmap.o signal.o syscall.o thunk.o \
377 gdbstub.o gdbstub-xml.o ioport-user.o
379 # Note: this is a workaround. The real fix is to avoid compiling
380 # cpu_signal_handler() in cpu-exec.c.
381 signal.o: CFLAGS += $(HELPER_CFLAGS)
383 $(QEMU_PROG): ARLIBS=libqemu.a
384 $(QEMU_PROG): $(obj-y) libqemu.a
385 $(call LINK,$(obj-y))
387 endif #CONFIG_DARWIN_USER
389 #########################################################
390 # BSD user emulator target
392 ifdef CONFIG_BSD_USER
394 VPATH+=:$(SRC_PATH)/bsd-user
395 CPPFLAGS+=-I$(SRC_PATH)/bsd-user -I$(SRC_PATH)/bsd-user/$(TARGET_ARCH)
409 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
411 # WARNING: this LDFLAGS is _very_ tricky : qemu is an ELF shared object
412 # that the kernel ELF loader considers as an executable. I think this
413 # is the simplest way to make it self virtualizable!
418 ifeq ($(ARCH),x86_64)
419 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
423 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
427 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
431 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
435 # -static is used to avoid g1/g3 usage by the dynamic linker
436 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld -static
439 ifeq ($(ARCH),sparc64)
440 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
444 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
448 LDFLAGS+=-Wl,-G0 -Wl,-T,$(SRC_PATH)/$(ARCH).ld
452 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
456 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
460 ifeq ($(WORDS_BIGENDIAN),yes)
461 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
463 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH)el.ld
467 ifeq ($(ARCH),mips64)
468 ifeq ($(WORDS_BIGENDIAN),yes)
469 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH).ld
471 LDFLAGS+=-Wl,-T,$(SRC_PATH)/$(ARCH)el.ld
475 obj-y = main.o bsdload.o elfload.o mmap.o path.o signal.o strace.o syscall.o \
476 gdbstub.o gdbstub-xml.o ioport-user.o
479 # Note: this is a workaround. The real fix is to avoid compiling
480 # cpu_signal_handler() in cpu-exec.c.
481 signal.o: CFLAGS += $(HELPER_CFLAGS)
483 $(QEMU_PROG): ARLIBS=libqemu.a ../libqemu_user.a
484 $(QEMU_PROG): $(obj-y) libqemu.a ../libqemu_user.a
485 $(call LINK,$(obj-y))
487 endif #CONFIG_BSD_USER
489 #########################################################
490 # System emulator target
491 ifndef CONFIG_USER_ONLY
493 obj-y = vl.o osdep.o monitor.o pci.o loader.o isa_mmio.o machine.o \
494 gdbstub.o gdbstub-xml.o msix.o ioport.o
495 # virtio has to be here due to weird dependency between PCI and virtio-net.
496 # need to fix this properly
497 obj-y += virtio-blk.o virtio-balloon.o virtio-net.o virtio-console.o
498 obj-$(CONFIG_KVM) += kvm.o kvm-all.o
508 LIBS += -lpulse-simple
511 LIBS += -lole32 -ldxguid
514 LIBS += $(CONFIG_FMOD_LIB)
517 LIBS += $(CONFIG_OSS_LIB)
521 sound-obj-$(CONFIG_SB16) += sb16.o
522 sound-obj-$(CONFIG_ES1370) += es1370.o
523 sound-obj-$(CONFIG_AC97) += ac97.o
524 sound-obj-$(CONFIG_ADLIB) += fmopl.o adlib.o
525 sound-obj-$(CONFIG_GUS) += gus.o gusemu_hal.o gusemu_mixer.o
526 sound-obj-$(CONFIG_CS4231A) += cs4231a.o
529 adlib.o fmopl.o: CFLAGS := ${CFLAGS} -DBUILD_Y8950=0
533 CPPFLAGS += $(CONFIG_VNC_TLS_CFLAGS)
534 LIBS += $(CONFIG_VNC_TLS_LIBS)
537 ifdef CONFIG_VNC_SASL
538 CPPFLAGS += $(CONFIG_VNC_SASL_CFLAGS)
539 LIBS += $(CONFIG_VNC_SASL_LIBS)
543 LIBS += $(CONFIG_BLUEZ_LIBS)
546 # xen backend driver support
547 obj-$(CONFIG_XEN) += xen_machine_pv.o xen_domainbuild.o
548 ifeq ($(CONFIG_XEN), y)
562 # Generic watchdog support and some watchdog devices
563 obj-y += wdt_ib700.o wdt_i6300esb.o
565 ifeq ($(TARGET_BASE_ARCH), i386)
567 obj-y += ide.o pckbd.o vga.o $(sound-obj-y) dma.o
568 obj-y += fdc.o mc146818rtc.o serial.o i8259.o i8254.o pcspk.o pc.o
569 obj-y += cirrus_vga.o apic.o ioapic.o parallel.o acpi.o piix_pci.o
570 obj-y += usb-uhci.o vmmouse.o vmport.o vmware_vga.o hpet.o
571 obj-y += device-hotplug.o pci-hotplug.o smbios.o
572 CPPFLAGS += -DHAS_AUDIO -DHAS_AUDIO_CHOICE
574 ifeq ($(TARGET_BASE_ARCH), ppc)
575 CPPFLAGS += -DHAS_AUDIO -DHAS_AUDIO_CHOICE
577 obj-y += ppc.o ide.o vga.o $(sound-obj-y) dma.o openpic.o
579 obj-y += pckbd.o serial.o i8259.o i8254.o fdc.o mc146818rtc.o
580 obj-y += prep_pci.o ppc_prep.o
582 obj-y += macio.o cuda.o adb.o mac_nvram.o mac_dbdma.o
584 obj-y += heathrow_pic.o grackle_pci.o ppc_oldworld.o
586 obj-y += unin_pci.o ppc_newworld.o
588 obj-y += pflash_cfi02.o ppc4xx_devs.o ppc4xx_pci.o ppc405_uc.o ppc405_boards.o
589 obj-y += ppc440.o ppc440_bamboo.o
590 # PowerPC E500 boards
591 obj-y += ppce500_pci.o ppce500_mpc8544ds.o
593 obj-y += device_tree.o
596 obj-$(CONFIG_KVM) += kvm_ppc.o
598 ifeq ($(TARGET_BASE_ARCH), mips)
599 obj-y += mips_r4k.o mips_jazz.o mips_malta.o mips_mipssim.o
600 obj-y += mips_timer.o mips_int.o dma.o vga.o serial.o i8254.o i8259.o rc4030.o
601 obj-y += g364fb.o jazz_led.o dp8393x.o
602 obj-y += ide.o gt64xxx.o pckbd.o fdc.o mc146818rtc.o usb-uhci.o acpi.o ds1225y.o
603 obj-y += piix_pci.o parallel.o cirrus_vga.o pcspk.o $(sound-obj-y)
605 obj-y += pflash_cfi01.o
606 obj-y += vmware_vga.o
607 CPPFLAGS += -DHAS_AUDIO -DHAS_AUDIO_CHOICE
609 ifeq ($(TARGET_BASE_ARCH), microblaze)
610 obj-y += petalogix_s3adsp1800_mmu.o
612 obj-y += microblaze_pic_cpu.o
613 obj-y += xilinx_intc.o
614 obj-y += xilinx_timer.o
615 obj-y += xilinx_uartlite.o
616 obj-y += xilinx_ethlite.o
618 obj-y += pflash_cfi02.o
620 obj-y += device_tree.o
624 ifeq ($(TARGET_BASE_ARCH), cris)
626 obj-y += cris_pic_cpu.o etraxfs.o axis_dev88.o
629 obj-y += etraxfs_dma.o
630 obj-y += etraxfs_pic.o
631 obj-y += etraxfs_eth.o
632 obj-y += etraxfs_timer.o
633 obj-y += etraxfs_ser.o
635 obj-y += pflash_cfi02.o
637 ifeq ($(TARGET_BASE_ARCH), sparc)
638 ifeq ($(TARGET_ARCH), sparc64)
639 obj-y += sun4u.o ide.o pckbd.o vga.o apb_pci.o
640 obj-y += fdc.o mc146818rtc.o serial.o
641 obj-y += cirrus_vga.o parallel.o
643 obj-y += sun4m.o tcx.o iommu.o slavio_intctl.o
644 obj-y += slavio_timer.o slavio_misc.o fdc.o sparc32_dma.o
645 obj-y += cs4231.o eccmemctl.o sbi.o sun4c_intctl.o
648 ifeq ($(TARGET_BASE_ARCH), arm)
649 obj-y += integratorcp.o versatilepb.o smc91c111.o arm_pic.o arm_timer.o
650 obj-y += arm_boot.o pl011.o pl031.o pl050.o pl080.o pl110.o pl181.o pl190.o
651 obj-y += versatile_pci.o
652 obj-y += realview_gic.o realview.o arm_sysctl.o mpcore.o
653 obj-y += armv7m.o armv7m_nvic.o stellaris.o pl022.o stellaris_enet.o
656 obj-y += pxa2xx.o pxa2xx_pic.o pxa2xx_gpio.o pxa2xx_timer.o pxa2xx_dma.o
657 obj-y += pxa2xx_lcd.o pxa2xx_mmci.o pxa2xx_pcmcia.o pxa2xx_keypad.o
658 obj-y += pflash_cfi01.o gumstix.o
659 obj-y += zaurus.o ide.o serial.o spitz.o tosa.o tc6393xb.o
660 obj-y += omap1.o omap_lcdc.o omap_dma.o omap_clk.o omap_mmc.o omap_i2c.o
661 obj-y += omap2.o omap_dss.o soc_dma.o
662 obj-y += omap_sx1.o palm.o tsc210x.o
663 obj-y += nseries.o blizzard.o onenand.o vga.o cbus.o tusb6010.o usb-musb.o
664 obj-y += mst_fpga.o mainstone.o
665 obj-y += musicpal.o pflash_cfi02.o
666 obj-y += framebuffer.o
667 obj-y += syborg.o syborg_fb.o syborg_interrupt.o syborg_keyboard.o
668 obj-y += syborg_serial.o syborg_timer.o syborg_pointer.o syborg_rtc.o
669 obj-y += syborg_virtio.o
670 CPPFLAGS += -DHAS_AUDIO
672 ifeq ($(TARGET_BASE_ARCH), sh4)
673 obj-y += shix.o r2d.o sh7750.o sh7750_regnames.o tc58128.o
674 obj-y += sh_timer.o sh_serial.o sh_intc.o sh_pci.o sm501.o serial.o
677 ifeq ($(TARGET_BASE_ARCH), m68k)
678 obj-y += an5206.o mcf5206.o mcf_uart.o mcf_intc.o mcf5208.o mcf_fec.o
679 obj-y += m68k-semi.o dummy_m68k.o
682 COCOA_LIBS=-F/System/Library/Frameworks -framework Cocoa -framework IOKit
683 ifdef CONFIG_COREAUDIO
684 COCOA_LIBS+=-framework CoreAudio
688 CPPFLAGS+=-I$(SRC_PATH)/slirp
691 # specific flags are needed for non soft mmu emulator
697 ifndef CONFIG_SOLARIS
710 LDFLAGS+=-Wl,-G0 -Wl,-T,$(SRC_PATH)/ia64.ld
714 SDL_LIBS := $(filter-out -mwindows, $(SDL_LIBS)) -mconsole
723 vl.o: CFLAGS+=$(SDL_CFLAGS)
727 monitor.o: qemu-monitor.h
729 $(QEMU_PROG): LIBS += $(SDL_LIBS) $(COCOA_LIBS) $(CURSES_LIBS) $(BRLAPI_LIBS) $(VDE_LIBS) $(CURL_LIBS)
730 $(QEMU_PROG): ARLIBS=../libqemu_common.a libqemu.a $(HWLIB)
731 $(QEMU_PROG): $(obj-y) ../libqemu_common.a libqemu.a $(HWLIB)
732 $(call LINK,$(obj-y))
734 endif # !CONFIG_USER_ONLY
736 gdbstub-xml.c: $(TARGET_XML_FILES) feature_to_c.sh
737 ifeq ($(TARGET_XML_FILES),)
738 $(call quiet-command,rm -f $@ && echo > $@," GEN $(TARGET_DIR)$@")
740 $(call quiet-command,rm -f $@ && $(SHELL) $(SRC_PATH)/feature_to_c.sh $@ $(TARGET_XML_FILES)," GEN $(TARGET_DIR)$@")
743 qemu-options.h: $(SRC_PATH)/qemu-options.hx
744 $(call quiet-command,sh $(SRC_PATH)/hxtool -h < $< > $@," GEN $(TARGET_DIR)$@")
746 qemu-monitor.h: $(SRC_PATH)/qemu-monitor.hx
747 $(call quiet-command,sh $(SRC_PATH)/hxtool -h < $< > $@," GEN $(TARGET_DIR)$@")
750 rm -f *.o *.a *~ $(PROGS) nwfpe/*.o fpu/*.o
751 rm -f *.d */*.d tcg/*.o
752 rm -f qemu-options.h qemu-monitor.h gdbstub-xml.c
756 $(INSTALL) -m 755 $(STRIP_OPT) $(PROGS) "$(DESTDIR)$(bindir)"
759 # Include automatically generated dependency files
760 -include $(wildcard *.d */*.d)