This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/SIMPLELINK-OPENOCD: SimpleLink-openOCD compile error in Linux

Part Number: SIMPLELINK-OPENOCD

Tool/software: Linux

Hello, I tried going to git.ti.com but couldn't find anything related to this.

When I run "make", I get the following:

libtool: compile: gcc -DHAVE_CONFIG_H -I. -I./src -I./src -I./src/helper -DPKGDATADIR=\"/usr/local/share/openocd\" -DBINDIR=\"/usr/local/bin\" -I./jimtcl -I./jimtcl -Wall -Wstrict-prototypes -Wformat-security -Wshadow -Wextra -Wno-unused-parameter -Wbad-function-cast -Wcast-align -Wredundant-decls -Werror -g -O2 -MT src/xsvf/xsvf.lo -MD -MP -MF src/xsvf/.deps/xsvf.Tpo -c src/xsvf/xsvf.c -o src/xsvf/xsvf.o
/bin/bash ./libtool --tag=CC --mode=link gcc -Wall -Wstrict-prototypes -Wformat-security -Wshadow -Wextra -Wno-unused-parameter -Wbad-function-cast -Wcast-align -Wredundant-decls -Werror -g -O2 -o src/xsvf/libxsvf.la src/xsvf/xsvf.lo -ldl
libtool: link: ar cru src/xsvf/.libs/libxsvf.a src/xsvf/xsvf.o
ar: `u' modifier ignored since `D' is the default (see `U')
libtool: link: ranlib src/xsvf/.libs/libxsvf.a
libtool: link: ( cd "src/xsvf/.libs" && rm -f "libxsvf.la" && ln -s "../libxsvf.la" "libxsvf.la" )
depbase=`echo src/svf/svf.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/bash ./libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I./src -I./src -I./src/helper -DPKGDATADIR=\"/usr/local/share/openocd\" -DBINDIR=\"/usr/local/bin\" -I./jimtcl -I./jimtcl -Wall -Wstrict-prototypes -Wformat-security -Wshadow -Wextra -Wno-unused-parameter -Wbad-function-cast -Wcast-align -Wredundant-decls -Werror -g -O2 -MT src/svf/svf.lo -MD -MP -MF $depbase.Tpo -c -o src/svf/svf.lo src/svf/svf.c &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I./src -I./src -I./src/helper -DPKGDATADIR=\"/usr/local/share/openocd\" -DBINDIR=\"/usr/local/bin\" -I./jimtcl -I./jimtcl -Wall -Wstrict-prototypes -Wformat-security -Wshadow -Wextra -Wno-unused-parameter -Wbad-function-cast -Wcast-align -Wredundant-decls -Werror -g -O2 -MT src/svf/svf.lo -MD -MP -MF src/svf/.deps/svf.Tpo -c src/svf/svf.c -o src/svf/svf.o
src/svf/svf.c: In function ‘svf_read_command_from_file’:
src/svf/svf.c:663:7: error: this statement may fall through [-Werror=implicit-fallthrough=]
i = -1;
~~^~~~
src/svf/svf.c:664:4: note: here
case '\r':
^~~~
src/svf/svf.c:667:8: error: this statement may fall through [-Werror=implicit-fallthrough=]
if (!cmd_pos)
^
src/svf/svf.c:669:4: note: here
default:
^~~~~~~
cc1: all warnings being treated as errors
Makefile:2790: recipe for target 'src/svf/svf.lo' failed
make[2]: *** [src/svf/svf.lo] Error 1
make[2]: Leaving directory '/home/devchu/Development/openocd-0.10.0'
Makefile:3665: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/devchu/Development/openocd-0.10.0'
Makefile:1578: recipe for target 'all' failed
make: *** [all] Error 2
devchu@chubox:~/Development/openocd-0.10.0$

  • My first location to obtain the required files was based off of T.I's announcement of SimpleLink-openOCD:

    software-dl.ti.com/.../index_FDS.html

    Unfortunately, ran into build issues (see first post).

    Luckily, stumbled on this link:

    github.com/.../openocd

    That worked.

    I did ./boostrap (ran into some initial problems)

    devchu@chubox:~/Development/openocd$ ./bootstrap
    ./bootstrap: Error: libtool is required
    devchu@chubox:~/Development/openocd$ sudo apt-get install libtool

    devchu@chubox:~/Development/openocd$ ./bootstrap
    + aclocal
    ./bootstrap: 27: ./bootstrap: aclocal: not found
    devchu@chubox:~/Development/openocd$ sudo apt-get install aclocal
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    E: Unable to locate package aclocal
    devchu@chubox:~/Development/openocd$ sudo apt-get install autotools-dev

    Still didnt work.. then:

    devchu@chubox:~/Development/openocd$ sudo apt-get install automake
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done

    Then started well.. :

    devchu@chubox:~/Development/openocd$ sudo apt-get install automake
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    (etc).

    Then:

    ./configure

    Then:

    make

    Then:

    sudo make install

    Then plug in the MSP432 Launchpad to USB and :

    devchu@chubox:~/Development/openocd$ openocd -f ./tcl/board/ti_msp432_launchpad.cfg
    Open On-Chip Debugger 0.10.0+dev-00556-gd0be163 (2018-10-23-16:17)
    Licensed under GNU GPL v2
    For bug reports, read
    openocd.org/.../bugs.html
    adapter speed: 2500 kHz
    srst_only separate srst_gates_jtag srst_open_drain connect_deassert_srst
    adapter_nsrst_delay: 100
    Info : Listening on port 6666 for tcl connections
    Info : Listening on port 4444 for telnet connections
    Info : XDS110: connected
    Info : XDS110: firmware version = 2.3.0.14
    Info : XDS110: hardware version = 0x0028
    Info : XDS110: connected to target via SWD
    Info : XDS110: SWCLK set to 2500 kHz
    Info : clock speed 2500 kHz
    Info : SWD DPIDR 0x2ba01477
    Info : msp432.cpu: hardware has 6 breakpoints, 4 watchpoints
    Info : Listening on port 3333 for gdb connections

**Attention** This is a public forum