2018-04-05 17:35:11 +03:00
|
|
|
# i386 cross compile notes
|
|
|
|
|
|
|
|
I386_SRC=$(SRC_PATH)/tests/tcg/i386
|
|
|
|
|
|
|
|
# Set search path for all sources
|
|
|
|
VPATH += $(I386_SRC)
|
|
|
|
|
|
|
|
I386_SRCS=$(notdir $(wildcard $(I386_SRC)/*.c))
|
2019-08-07 17:35:22 +03:00
|
|
|
ALL_X86_TESTS=$(I386_SRCS:.c=)
|
|
|
|
I386_TESTS:=$(filter-out test-i386-ssse3, $(ALL_X86_TESTS))
|
|
|
|
X86_64_TESTS:=$(filter test-i386-ssse3, $(ALL_X86_TESTS))
|
2018-04-05 17:35:11 +03:00
|
|
|
# Update TESTS
|
2019-08-07 17:35:22 +03:00
|
|
|
TESTS=$(MULTIARCH_TESTS) $(I386_TESTS)
|
2018-04-05 17:35:11 +03:00
|
|
|
|
|
|
|
#
|
|
|
|
# hello-i386 is a barebones app
|
|
|
|
#
|
|
|
|
hello-i386: CFLAGS+=-ffreestanding
|
|
|
|
hello-i386: LDFLAGS+=-nostdlib
|
|
|
|
|
|
|
|
#
|
|
|
|
# test-386 includes a couple of additional objects that need to be linked together
|
|
|
|
#
|
|
|
|
|
|
|
|
test-i386: test-i386.c test-i386-code16.S test-i386-vm86.S test-i386.h test-i386-shift.h test-i386-muldiv.h
|
2019-08-07 17:35:22 +03:00
|
|
|
$(CC) $(CFLAGS) $(LDFLAGS) $(EXTRA_CFLAGS) -o $@ \
|
2018-04-05 17:35:11 +03:00
|
|
|
$(<D)/test-i386.c $(<D)/test-i386-code16.S $(<D)/test-i386-vm86.S -lm
|
2018-04-17 16:56:39 +03:00
|
|
|
|
2018-04-10 17:23:29 +03:00
|
|
|
ifeq ($(SPEED), slow)
|
|
|
|
|
|
|
|
test-i386-fprem.ref: test-i386-fprem
|
|
|
|
$(call quiet-command, ./$< > $@,"GENREF","generating $@")
|
|
|
|
|
|
|
|
run-test-i386-fprem: TIMEOUT=60
|
2019-07-05 13:48:02 +03:00
|
|
|
run-test-i386-fprem: test-i386-fprem test-i386-fprem.ref
|
2018-05-21 12:38:37 +03:00
|
|
|
$(call run-test,test-i386-fprem, $(QEMU) $<,"$< on $(TARGET_NAME)")
|
2019-07-05 13:48:02 +03:00
|
|
|
$(call diff-out,test-i386-fprem, test-i386-fprem.ref)
|
2018-04-10 17:23:29 +03:00
|
|
|
else
|
|
|
|
run-test-i386-fprem: test-i386-fprem
|
2018-05-21 12:38:37 +03:00
|
|
|
$(call skip-test, $<, "SLOW")
|
2018-04-10 17:23:29 +03:00
|
|
|
endif
|
|
|
|
|
2018-04-17 16:56:39 +03:00
|
|
|
# On i386 and x86_64 Linux only supports 4k pages (large pages are a different hack)
|
|
|
|
EXTRA_RUNS+=run-test-mmap-4096
|