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.

CC2652R7: Error while building and configuring the Thread border router: ot-br-posix : [-Werror=stringop-truncation]

Part Number: CC2652R7


Hello,

I am trying to setup the Thread border router on BeagleBone Black and LP-2652R7. I am following the steps mentioned at Resource explorer: https://dev.ti.com/tirex/explore/node?node=AP0oXq54dgMJ4g-gwa3-rw__BSEc4rl__LATEST 

The NCP-FTD code compiled and flashed successfully on LP-2652R7 and attached to the BeagleBone Black. The LED on LP is blinking.

The Thread network was not getting 'Formed' while checking out the 'main' branch of repo: ot-br-posix.

Hence after reading THIS query I have checked out the tag 'thread-br-certified-20180819' as mentioned.

./script/bootstrap is completed successfully.

facing issue while performing ./script/setup.

Getting the error as below after about half hour:

libtool: link: ranlib .libs/libcoap-1.a
libtool: link: ( cd ".libs" && rm -f "libcoap-1.la" && ln -s "../libcoap-1.la" "libcoap-1.la" )
Making all in doc
make[6]: Nothing to be done for 'all'.
Making all in tests
make[6]: Nothing to be done for 'all'.
Making all in examples
make[6]: Nothing to be done for 'all'.
make[4]: Nothing to be done for 'all-am'.
Making all in Simple-web-server
make[3]: Nothing to be done for 'all'.
Making all in mdl
make[3]: Nothing to be done for 'all'.
Making all in angular
make[3]: Nothing to be done for 'all'.
Making all in angular-material
make[3]: Nothing to be done for 'all'.
make[3]: Nothing to be done for 'all-am'.
Making all in include
make  all-am
Making all in src
Making all in common
  CXX      logging.lo
  CXXLD    libotbr-logging.la
ar: `u' modifier ignored since `D' is the default (see `U')
  CXX      event_emitter.lo
  CXXLD    libotbr-event-emitter.la
ar: `u' modifier ignored since `D' is the default (see `U')
Making all in utils
  CXX      crc16.lo
  CXX      hex.lo
  CXX      steeringdata.lo
  CXXLD    libutils.la
ar: `u' modifier ignored since `D' is the default (see `U')
Making all in agent
  CXX      otbr_agent-main.o
  CXX      libotbr_agent_la-agent_instance.lo
  CXX      libotbr_agent_la-border_agent.lo
  CXX      libotbr_agent_la-coap_libcoap.lo
  CXX      libotbr_agent_la-dtls_mbedtls.lo
  CXX      libotbr_agent_la-ncp_wpantund.lo
ncp_wpantund.cpp: In constructor ‘ot::BorderRouter::Ncp::ControllerWpantund::ControllerWpantund(const char*)’:
ncp_wpantund.cpp:238:12: error: ‘char* strncpy(char*, const char*, size_t)’ specified bound 16 equals destination size [-Werror=stringop-truncation]
     strncpy(mInterfaceName, aInterfaceName, sizeof(mInterfaceName));
     ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1plus: all warnings being treated as errors
make[3]: *** [Makefile:716: libotbr_agent_la-ncp_wpantund.lo] Error 1
make[2]: *** [Makefile:444: all-recursive] Error 1
make[1]: *** [Makefile:570: all-recursive] Error 1
make: *** [Makefile:496: all] Error 2
root@beaglebone:/home/debian/ot-br-posix#

ncp_wpantund.cpp: In constructor ‘ot::BorderRouter::Ncp::ControllerWpantund::ControllerWpantund(const char*)’:
ncp_wpantund.cpp:238:12: error: ‘char* strncpy(char*, const char*, size_t)’ specified bound 16 equals destination size [-Werror=stringop-truncation]
strncpy(mInterfaceName, aInterfaceName, sizeof(mInterfaceName));

Let me know if you need any more logs to debug this issue.