4 |
LDFLAGS=-g |
LDFLAGS=-g |
5 |
LIBS= |
LIBS= |
6 |
DEFINES=-DHAVE_BYTESWAP_H |
DEFINES=-DHAVE_BYTESWAP_H |
7 |
|
HELPER_CFLAGS=$(CFLAGS) |
8 |
|
|
9 |
ifeq ($(ARCH),i386) |
ifeq ($(ARCH),i386) |
10 |
CFLAGS+=-fomit-frame-pointer |
CFLAGS+=-fomit-frame-pointer |
38 |
CFLAGS+=-m32 -ffixed-g1 -ffixed-g2 -ffixed-g3 -ffixed-g6 |
CFLAGS+=-m32 -ffixed-g1 -ffixed-g2 -ffixed-g3 -ffixed-g6 |
39 |
LDFLAGS+=-m32 |
LDFLAGS+=-m32 |
40 |
OP_CFLAGS=$(CFLAGS) -fno-delayed-branch -ffixed-i0 |
OP_CFLAGS=$(CFLAGS) -fno-delayed-branch -ffixed-i0 |
41 |
|
HELPER_CFLAGS=$(CFLAGS) -ffixed-i0 -mflat |
42 |
|
LDFLAGS+=-Wl,-T,sparc.ld |
43 |
endif |
endif |
44 |
|
|
45 |
ifeq ($(ARCH),sparc64) |
ifeq ($(ARCH),sparc64) |
61 |
OP_CFLAGS=$(CFLAGS) |
OP_CFLAGS=$(CFLAGS) |
62 |
endif |
endif |
63 |
|
|
64 |
|
ifeq ($(ARCH),arm) |
65 |
|
OP_CFLAGS=$(CFLAGS) -mno-sched-prolog |
66 |
|
LDFLAGS+=-Wl,-T,arm.ld |
67 |
|
endif |
68 |
|
|
69 |
ifeq ($(GCC_MAJOR),3) |
ifeq ($(GCC_MAJOR),3) |
70 |
# very important to generate a return at the end of every operation |
# very important to generate a return at the end of every operation |
71 |
OP_CFLAGS+=-fno-reorder-blocks -fno-optimize-sibling-calls |
OP_CFLAGS+=-fno-reorder-blocks -fno-optimize-sibling-calls |
89 |
LIBOBJS+=thunk.o translate-i386.o op-i386.o helper-i386.o exec-i386.o exec.o |
LIBOBJS+=thunk.o translate-i386.o op-i386.o helper-i386.o exec-i386.o exec.o |
90 |
|
|
91 |
# NOTE: the disassembler code is only needed for debugging |
# NOTE: the disassembler code is only needed for debugging |
92 |
LIBOBJS+=disas.o i386-dis.o dis-buf.o |
LIBOBJS+=disas.o i386-dis.o |
93 |
ifeq ($(ARCH),alpha) |
ifeq ($(ARCH),alpha) |
94 |
LIBOBJS+=alpha-dis.o |
LIBOBJS+=alpha-dis.o |
95 |
endif |
endif |
96 |
ifeq ($(ARCH),ppc) |
ifeq ($(ARCH),ppc) |
97 |
LIBOBJS+=ppc-dis.o |
LIBOBJS+=ppc-dis.o |
98 |
endif |
endif |
99 |
|
ifeq ($(ARCH),sparc) |
100 |
|
LIBOBJS+=sparc-dis.o |
101 |
|
endif |
102 |
|
ifeq ($(ARCH),arm) |
103 |
|
LIBOBJS+=arm-dis.o |
104 |
|
endif |
105 |
|
|
106 |
ifeq ($(ARCH),ia64) |
ifeq ($(ARCH),ia64) |
107 |
OBJS += ia64-syscall.o |
OBJS += ia64-syscall.o |
140 |
op-i386.o: op-i386.c opreg_template.h ops_template.h |
op-i386.o: op-i386.c opreg_template.h ops_template.h |
141 |
$(CC) $(OP_CFLAGS) $(DEFINES) -c -o $@ $< |
$(CC) $(OP_CFLAGS) $(DEFINES) -c -o $@ $< |
142 |
|
|
143 |
|
helper-i386.o: helper-i386.c |
144 |
|
$(CC) $(HELPER_CFLAGS) $(DEFINES) -c -o $@ $< |
145 |
|
|
146 |
%.o: %.c |
%.o: %.c |
147 |
$(CC) $(CFLAGS) $(DEFINES) -c -o $@ $< |
$(CC) $(CFLAGS) $(DEFINES) -c -o $@ $< |
148 |
|
|
169 |
|
|
170 |
FILES= \ |
FILES= \ |
171 |
README README.distrib COPYING COPYING.LIB TODO Changelog VERSION \ |
README README.distrib COPYING COPYING.LIB TODO Changelog VERSION \ |
172 |
dyngen.c ioctls.h ops_template.h op_string.h syscall_types.h\ |
dyngen.c dyngen.h ioctls.h ops_template.h op_string.h syscall_types.h\ |
173 |
Makefile elf.h thunk.c\ |
Makefile elf.h thunk.c\ |
174 |
elfload.c main.c signal.c thunk.h exec.h\ |
elfload.c main.c signal.c thunk.h exec.h\ |
175 |
cpu-i386.h qemu.h op-i386.c helper-i386.c syscall-i386.h translate-i386.c\ |
cpu-i386.h qemu.h op-i386.c helper-i386.c syscall-i386.h translate-i386.c\ |
176 |
syscall.c opreg_template.h syscall_defs.h vm86.c\ |
syscall.c opreg_template.h syscall_defs.h vm86.c\ |
177 |
dis-asm.h dis-buf.c disas.c disas.h alpha-dis.c ppc-dis.c i386-dis.c\ |
dis-asm.h disas.c disas.h alpha-dis.c ppc-dis.c i386-dis.c sparc-dis.c arm-dis.c\ |
178 |
ppc.ld alpha.ld s390.ld exec-i386.h exec-i386.c path.c exec.c mmap.c configure \ |
ppc.ld alpha.ld s390.ld sparc.ld arm.ld exec-i386.h exec-i386.c path.c exec.c mmap.c configure \ |
179 |
tests/Makefile\ |
tests/Makefile\ |
180 |
tests/test-i386.c tests/test-i386-shift.h tests/test-i386.h\ |
tests/test-i386.c tests/test-i386-shift.h tests/test-i386.h\ |
181 |
tests/test-i386-muldiv.h tests/test-i386-code16.S\ |
tests/test-i386-muldiv.h tests/test-i386-code16.S\ |