qemu/tests/migration/s390x/Makefile
Thomas Huth 5571dc824b tests/migration: Enable the migration test on s390x, too
We can re-use the s390-ccw bios code to implement a small firmware
for a s390x guest which prints out the "A" and "B" characters and
modifies the memory, as required for the migration test.

[quintela: Converted the compile script to Makefile rules]
Signed-off-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
Message-Id: <1539078677-25396-1-git-send-email-thuth@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Tested-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
  Fixed up Makefile since the aarch patch sneaked in first
2018-10-11 19:58:21 +01:00

25 lines
703 B
Makefile

# To specify cross compiler prefix, use CROSS_PREFIX=
# $ make CROSS_PREFIX=s390x-linux-gnu-
.PHONY: all clean
all: a-b-bios.h
fwdir=../../../pc-bios/s390-ccw
CFLAGS+=-ffreestanding -fno-delete-null-pointer-checks -fPIE -Os \
-msoft-float -march=z900 -fno-asynchronous-unwind-tables -Wl,-pie \
-Wl,--build-id=none -nostdlib
a-b-bios.h: s390x.elf
echo "$$__note" > header.tmp
xxd -i $< | sed -e 's/.*int.*//' >> header.tmp
mv header.tmp $@
# We use common-page-size=16 to avoid big padding in the ELF file
s390x.elf: a-b-bios.c
$(CROSS_PREFIX)gcc $(CFLAGS) -I$(fwdir) $(fwdir)/start.S \
$(fwdir)/sclp.c -Wl,-zcommon-page-size=16 -o $@ $<
$(CROSS_PREFIX)strip $@
clean:
@rm -rf *.elf *.o