diff --git a/tests/tcg/s390x/libc/stdio.h b/tests/tcg/s390x/libc/stdio.h new file mode 100644 index 0000000000..c3e45995f6 --- /dev/null +++ b/tests/tcg/s390x/libc/stdio.h @@ -0,0 +1,11 @@ +/* + * SPDX-License-Identifier: GPL-2.0-or-later + */ +#ifndef QEMU_TESTS_S390X_STDIO_H +#define QEMU_TESTS_S390X_STDIO_H + +#include + +#define printf ml_printf + +#endif diff --git a/tests/tcg/s390x/libc/string.h b/tests/tcg/s390x/libc/string.h new file mode 100644 index 0000000000..1cabeb90ad --- /dev/null +++ b/tests/tcg/s390x/libc/string.h @@ -0,0 +1,12 @@ +/* + * SPDX-License-Identifier: GPL-2.0-or-later + */ +#ifndef QEMU_TESTS_S390X_STRING_H +#define QEMU_TESTS_S390X_STRING_H + +#include + +void *memcpy(void *dest, const void *src, size_t n); +void *memset(void *dest, int c, size_t size); + +#endif diff --git a/tests/tcg/s390x/system/meson.build b/tests/tcg/s390x/system/meson.build index ca07f50305..1e360e7082 100644 --- a/tests/tcg/s390x/system/meson.build +++ b/tests/tcg/s390x/system/meson.build @@ -6,11 +6,13 @@ link_script = files('../softmmu.ld')[0] head64 = files('../head64.S')[0] console = files('../console.c')[0] ipl_inc = meson.project_source_root()/'include'/'hw'/'s390x'/'ipl' +libc_inc = meson.current_source_dir()/'..'/'libc' cflags = ['-nostdlib', '-ffreestanding', '-Wa,--noexecstack', '-I', minilib_dir, minilib_printf, '-I', ipl_inc, + '-I', libc_inc, '-march=z13', head64, console] asmflags = ['-nostdlib',