arduino-nRF5 icon indicating copy to clipboard operation
arduino-nRF5 copied to clipboard

Switch to mainline openocd

Open sandeepmistry opened this issue 8 years ago • 8 comments

Now that the following patch has been integrated into the mainline OpenOCD: http://openocd.zylin.com/#/c/3510/

I think we can switch to the GNU ARM Eclipse version of OpenOCD. We just need to repackage the archives into a format the Arduino IDE expects: https://github.com/gnuarmeclipse/openocd/releases

As well as modify the tcl/target/nrf52.cfg file or use a local config version stored in the repo: http://openocd.zylin.com/#/c/3399/

sandeepmistry avatar Mar 02 '17 01:03 sandeepmistry

This also will give us 32-bit and 64-bit versions of the Linux binary.

sandeepmistry avatar Mar 02 '17 01:03 sandeepmistry

Could ARM Linux be supported out of the box as well with this?

carlosperate avatar Mar 27 '17 19:03 carlosperate

@carlosperate If something provides a build of the toolchains for ARM Linux, I'd be happy to add it to the JSON :)

sandeepmistry avatar Apr 10 '17 00:04 sandeepmistry

Well, if we could use upstream openOCD I was hoping to be able to use pre-build binaries from teams like GNU ARM Eclipse: https://github.com/gnuarmeclipse/openocd/releases But I am not sure how often do they update their binaries, and looks like they don't target ARM either :( I might give this a go in the future if necessary.

carlosperate avatar Apr 10 '17 00:04 carlosperate

I don't see and ARM openocd binary there, we also need an ARM to ARM compiler?

sandeepmistry avatar Apr 10 '17 01:04 sandeepmistry

Yeah, sorry, I edited my previous message once I realised they didn't build for ARM. We would need ARM GCC, but if I was to try this myself I would just build it in a ARMv6 raspberry pi with an old version of Raspbian (and therefore an old version of glibc), which should be fine for most debian-based ARM distributions (and hopefully other distros as well, but hard to tell).

carlosperate avatar Apr 10 '17 11:04 carlosperate

@sandeepmistry Is there still a desire to move to the mainline OpenOCD? While I am working on the repository this weekend I can spend some time repackaging OpenOCD as well.

dlabun avatar Feb 09 '18 19:02 dlabun

@dlabun yes, that would be great. We might have to patch tcl/target/nrf52.cfg from the mainline OpenOCD version. I suggest we repackage the "GNU ARM Eclipse version of OpenOCD" to a archive format that is compatible with the Arduino IDE, instead of rebuilding it from source.

sandeepmistry avatar Feb 10 '18 12:02 sandeepmistry