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.

[参考译文] CC3551E:TI-POSIX 和 AMP;C++支持

Guru**** 2508755 points


请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/wireless-connectivity/wi-fi-group/wifi/f/wi-fi-forum/1550362/cc3551e-ti-posix-c-support

器件型号:CC3551E


工具/软件:

尊敬的社区:

我在尝试编译 C++单元时遇到了问题。

当 使用位于以下 SDK 路径中的“空“示例: ./ti/simplelink_wifi_sdk_9_13_01_04_ea/examples/rtos/CC35X1_LAUNCHXL/drivers/empty/freertos/ticlang 时、我添加了一个简单的 TEST.HPP/test.cpp 文件、并使用一些 STL 功能 (std::vector) 添加了一些虚拟 C++代码。 这导致了一些 源自“errno.c"文件“文件的问题。

在  ti/simplelink_wifi_sdk_9_13_01_04_ea/source/ti/POSIX/ticlang/errno.h 文件中 、我注意到 errno 标头的 include 最终会出现问题:

// The following line does not work for C++
// Note the path which explicitly is within a "c" folder


/* include toolchain's header file */
#include <../../include/c/errno.h> 


// If the above line is mopdified like this, the C++ build succeeds
#include_next <errno.h>

我注意到一个类似的问题 Thich 被报道了几年前。 这是否相关?
是否有替代方法可以启用 C++编译而不是修改 SDK?

此致、非常感谢、

 Thomas