I want to setup a task for a recipe (or a standalone recipe if required) that allows me to run openocd to connect to my development board.
I have an openocd-native recipe.
I create a task added to my recipe like this:
do_openocd[depends] += "openocd-native:do_populate_sysroot"
addtask openocd after do_image
do_openocd () {
echo "The thing is ${datadir_native}/openocd"
echo $(ls -la ${datadir_native}/openocd/scripts/interface)
echo $(openocd -v)
echo $(which openocd)
openocd -f ${datadir_native}/openocd/scripts/interface/altera-usb-blaster2.cfg
}
This runs the openocd in the build system sysroot as I expect it to. However, I am unable to get my task to use the usr/share within my build system sysroot. It simply looks at /usr/share/blablabla
as if a build system sysroot does not exist.
altera-usb-blaster2.cfg
does not exist in usr/share/openocd/scripts/interface/
, but it does exist in ./tmp/sysroots/x86_64-linux/usr/share/openocd/scripts/interface/
. (relative to my build folder)
How do I setup my task to run openocd?