building zephyr with mainline toolchain for Arduino 101

Lukasz Janyst <xyz@...>

Hi there,

I have recently started playing with Zephyr and decided to see whether I
can build it for Arduino 101 with the mainline toolchain. I compiled the
following for both i586-none-elfiamcu and arc-none-elf targets:

* binutils master branch, 2.26.51 has messed up commandline parsing for
arc (fixed in master)
* gcc 6.1
* newlib 2.4.0
* gdb 7.11 (mainline for Intel, foss-for-synopsys-dwc-arc-processors for

Things work well for Intel except for one minor glitch in newlib's
'strtold()'. However, for arc, I have encountered some issues with
zephyr itself:

1) In various assembler files you use the 'j_s.nd [blink]' instruction.
I could not find anywhere what it is supposed to do and mainline gas
does not know what to do about it. When you look at the actual opcodes
emitted by poky gas, it seems that what you meant is 'j_s [blink]':

Things work if I change that. I can send out a patch if there is an

2) gcc 6.1 for arc seems to emit code containing traps calling

Zephyr does not provide the symbol, so the compilation fails. It seems
that Linux provides 'abort()' for certain architectures:

I don't know enough about arc to provide a sensible implementation so
suggestions would be appreciated. A dummy symbol makes the compilation


Join to automatically receive all group messages.