git: 53a850a0d75f - main - tools/build: also stage machine/cpu_flags.h on powerpc
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 23 Nov 2026 08:39:59 UTC
The branch main has been updated by pkubaj:
URL: https://cgit.FreeBSD.org/src/commit/?id=53a850a0d75fa6621be525a79ad821fa4b47e069
commit 53a850a0d75fa6621be525a79ad821fa4b47e069
Author: Piotr Kubaj <pkubaj@FreeBSD.org>
AuthorDate: 2026-11-22 11:03:13 +0000
Commit: Piotr Kubaj <pkubaj@FreeBSD.org>
CommitDate: 2026-11-23 08:39:49 +0000
tools/build: also stage machine/cpu_flags.h on powerpc
powerpc's machine/elf.h now includes machine/cpu_flags.h, but only elf.h
gets copied into the legacy include directory. Building world natively
on a powerpc host that doesn't have cpu_flags.h installed yet then fails
in libllvmminimal.
Reviewed by: jhibbits
Fixes: 90bc40e26c61 ("powerpc: Split CPU flags into separate file...")
MFC with: 90bc40e26c61
Differential Revision: https://reviews.freebsd.org/D61920
---
tools/build/Makefile | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/tools/build/Makefile b/tools/build/Makefile
index 90fb93a5196a..467bd576c758 100644
--- a/tools/build/Makefile
+++ b/tools/build/Makefile
@@ -174,6 +174,10 @@ _host_arch=powerpc
_host_arch=amd64
.endif
MACHINESYSINCS+= ${SRCTOP}/sys/${_host_arch}/include/elf.h
+.if ${_host_arch} == "powerpc"
+# The powerpc elf.h includes cpu_flags.h
+MACHINESYSINCS+= ${SRCTOP}/sys/powerpc/include/cpu_flags.h
+.endif
.if ${_host_arch} == "amd64" || ${_host_arch} == "i386"
INCSGROUPS+= X86INCS
X86INCSDIR= ${INCLUDEDIR}/x86