Jas*_*ram 4 c++ cygwin cross-platform tchar windows-7
我在Windows 7(32位)上运行最新的cygwin,并尝试构建一个开源项目RtAudio(它目前不在此平台上构建).
我遇到的一个问题是线路上的错误
#include <tchar.h>.
我的构建线是:
g++ -O2 -Wall -Iinclude -DHAVE_GETTIMEOFDAY -D__WINDOWS_DS__ -c RtAudio.cpp -o RtAudio.o
Run Code Online (Sandbox Code Playgroud)
错误是:
tchar.h: No such file or directory
Run Code Online (Sandbox Code Playgroud)
如果我将/ usr/include/mingw(包含tchar.h)添加到包含路径列表中,我会收到更多错误.
我已经不使用LPCTSTR,只是重载需要它的一个功能,解决该问题的工作const char*,并const wchar_t*让我能够避免,包括TCHAR.H,但有一个更好的方式来做到这一点?