[Skiboot] [PATCH 1/3] external/opal-prd: Fix compilation error
Mahesh Salgaonkar
mahesh at linux.ibm.com
Sat Sep 20 03:19:43 AEST 2025
Upstream opal-prd fails with below compilation errors:
$ make -C external/opal-prd/
make: Entering directory '/home/mahesh/skiboot/external/opal-prd'
[...]
CC thunk.o
/usr/include/bits/types.h: Assembler messages:
/usr/include/bits/types.h:30: Error: unrecognized opcode: `typedef'
/usr/include/bits/types.h:31: Error: unrecognized opcode: `typedef'
/usr/include/bits/types.h:32: Error: unrecognized opcode: `typedef'
[...]
The file thunk.S includes <endian.h> which gets picked up from skiboot's
'include/endian.h' (instead of /usr/include/endian.h) which then
includes 'ccan/endian/endian.h' -> /usr/include/bits/types.h where
assember fails with compilation.
The 'include/endian.h' was introduced by commit 18c9b278e747 ("include:
Provide endian conversion functions") when support for PLDM was added.
This header file was introduced to be used by C files under pldm/,
core/pldm and libmctp/ only. In order to restrict this header file to
pldm/libmctp, move the endian.h header under 'pldm/include' folder. This
makes sure that except files under 'pldm' and 'libmctp', rest all other
C files would pick up default header file from '/usr/include/endian.h'
as it was prior to commit 18c9b278e747 ("include: Provide endian
conversion functions")
After moving endian.h under 'pldm/include', opal-prd gets successfully
compiled.
Fixes: 18c9b278e747 ("include: Provide endian conversion functions")
Signed-off-by: Mahesh Salgaonkar <mahesh at linux.ibm.com>
---
{include => pldm/include}/endian.h | 0
1 file changed, 0 insertions(+), 0 deletions(-)
rename {include => pldm/include}/endian.h (100%)
diff --git a/include/endian.h b/pldm/include/endian.h
similarity index 100%
rename from include/endian.h
rename to pldm/include/endian.h
--
2.51.0
More information about the Skiboot
mailing list