aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPiotr Kubaj <pkubaj@FreeBSD.org>2023-10-06 10:50:19 +0000
committerPiotr Kubaj <pkubaj@FreeBSD.org>2023-10-06 16:39:08 +0000
commitc57e0dd3f76136e1acd40a1da83f592814f1d7b8 (patch)
tree3c03dfdb6fee513654fce3a2b6407a407a5be380
parent5afb96248d47fbda6878951c0eabdd3c10c4e02f (diff)
downloadports-c57e0dd3f76136e1acd40a1da83f592814f1d7b8.tar.gz
ports-c57e0dd3f76136e1acd40a1da83f592814f1d7b8.zip
emulators/qemu-devel: fix build on powerpc64*
Same patch as for emulators/qemu.
-rw-r--r--emulators/qemu-devel/files/patch-util_cpuinfo-ppc.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/emulators/qemu-devel/files/patch-util_cpuinfo-ppc.c b/emulators/qemu-devel/files/patch-util_cpuinfo-ppc.c
new file mode 100644
index 000000000000..499de6e86db0
--- /dev/null
+++ b/emulators/qemu-devel/files/patch-util_cpuinfo-ppc.c
@@ -0,0 +1,18 @@
+--- util/cpuinfo-ppc.c.orig 2023-08-29 11:28:39 UTC
++++ util/cpuinfo-ppc.c
+@@ -9,8 +9,14 @@
+ #ifdef CONFIG_GETAUXVAL
+ # include <sys/auxv.h>
+ #else
+-# include <asm/cputable.h>
++# ifdef __linux__
++# include <asm/cputable.h>
++# endif
+ # include "elf.h"
++#endif
++
++#ifndef PPC_FEATURE2_ARCH_3_1
++# define PPC_FEATURE2_ARCH_3_1 0x00040000
+ #endif
+
+ unsigned cpuinfo;