Building newlib for Cortex-M with LLVM

Marcus Shawcroft marcus.shawcroft@gmail.com
Thu Nov 12 11:17:00 GMT 2015


On 11 November 2015 at 23:16, Olivier MARTIN <olivier@labapart.com> wrote:

> * The first one can be solved. The space in the call of CONCAT2(a, b) by
> CONCAT() is propagated into the subsequent calls. It means when the strings
> 'a' and 'b' are concatenated, the space is inserted between both strings -
> which is not the expected behaviour.
>
> The fix would be:
>
> --- a/newlib/libc/machine/arm/setjmp.S
> +++ b/newlib/libc/machine/arm/setjmp.S
> @@ -3,7 +3,7 @@
>     Nick Clifton, Cygnus Solutions, 13 June 1997.  */
>
>  /* ANSI concatenation macros.  */
> -#define CONCAT(a, b)  CONCAT2(a, b)
> +#define CONCAT(a, b)  CONCAT2(a,b)

Have you looked at the C standard on this issue? I wonder which
compiler, gcc or clang is not compliant with the standard.

Cheers
/Marcus



More information about the Newlib mailing list