On 23.06.2025 09:51, Jan Beulich wrote:
> On 21.06.2025 11:58, Nicola Vetrini wrote:
>> Dashes were wrongly not translated into underscores, thus generating
>> an unexpected guard identifier.
>>
>> Fixes: ee79f378311b ("xen: add header guards to generated asm generic
>> headers")
>> Signed-off-by: Nicola Vetrini <[email protected]>
>> ---
>> xen/scripts/Makefile.asm-generic | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/xen/scripts/Makefile.asm-generic
>> b/xen/scripts/Makefile.asm-generic
>> index b0828018080d..f6850758c54b 100644
>> --- a/xen/scripts/Makefile.asm-generic
>> +++ b/xen/scripts/Makefile.asm-generic
>> @@ -34,7 +34,7 @@ unwanted := $(filter-out $(generic-y)
>> $(generated-y),$(old-headers))
>> quiet_cmd_wrap = WRAP $@
>> cmd_wrap = \
>> arch=$$(echo $@ | sed -n 's:.*arch/\([^/]*\)/.*:\1:p' | tr a-z A-Z); \
>> - upper=$$(echo $*.h | tr a-z A-Z | tr '/.' '__'); \
>> + upper=$$(echo $*.h | tr a-z A-Z | tr '/.-' '__'); \
>
> Aiui the other argument also needs to change, to '___'. While some tr
> implementations
> may cope, the spec is quite clear:
>
> "When the -d option is not specified:
>
> Each input character found in the array specified by string1 shall be
> replaced by the character in the same relative position in the array
> specified by string2. When the array specified by string2 is shorter that the
> one specified by string1, the results are unspecified."
>
> Easy enough to adjust while committing, I suppose.
Except that I notice that this was committed already. Will require another
fixup then, I expect.
Jan