On 27.02.23 16:53, Jan Beulich wrote:
On 27.02.2023 16:41, Juergen Gross wrote:--- a/tools/firmware/include/stddef.h +++ b/tools/firmware/include/stddef.h @@ -1,10 +1,10 @@ #ifndef _STDDEF_H_ #define _STDDEF_H_+#include <xen-tools/common-macros.h>+ typedef __SIZE_TYPE__ size_t;#define NULL ((void*)0) -#define offsetof(t, m) __builtin_offsetof(t, m)- #endifThe C standard is pretty specific about what a header of this name may or (in particular here) may not define. You add much more to the name space than just the replacement offsetof(). If this was a header used by an individual component, this might be fine. But this header is meant to serve all components under firmware/ which care to include it. At present that's hvmloader (which we control, so we can arrange for it to be free of collisions) and rombios (which we do not really control, and which people also may not build routinely anymore).
Good point. I have verified that the build is still succeeding without the modification of tools/firmware/include/stddef.h, so I'll drop this hunk. Juergen
OpenPGP_0xB0DE9DD628BF132F.asc
Description: OpenPGP public key
OpenPGP_signature
Description: OpenPGP digital signature