1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-22 02:35:23 +03:00
aports/community/qemu/mips-softfloat.patch
Natanael Copa 7e9832f91b community/qemu: re-add build fix for mips64
the patch was removed in commit 0ed4cab8ff (community/qemu: upgrade to
6.0.0) but is needed for mips64
2021-05-07 10:07:14 +02:00

35 lines
1,012 B
Diff

This patch is needed due to our mips64 build uses softfloat. Qemu will not
build without this patch.
diff --git a/tests/fp/fp-bench.c b/tests/fp/fp-bench.c
index 4ba5e1d..313256c 100644
--- a/tests/fp/fp-bench.c
+++ b/tests/fp/fp-bench.c
@@ -479,6 +479,7 @@ static void QEMU_NORETURN die_host_rounding(enum rounding rounding)
exit(EXIT_FAILURE);
}
+#ifndef __mips_soft_float
static void set_host_precision(enum rounding rounding)
{
int rhost;
@@ -507,6 +508,7 @@ static void set_host_precision(enum rounding rounding)
die_host_rounding(rounding);
}
}
+#endif
static void set_soft_precision(enum rounding rounding)
{
@@ -596,9 +598,11 @@ static void parse_args(int argc, char *argv[])
/* set precision and rounding mode based on the tester */
switch (tester) {
+#ifndef __mips_soft_float
case TESTER_HOST:
set_host_precision(rounding);
break;
+#endif
case TESTER_SOFT:
set_soft_precision(rounding);
switch (precision) {