C++ 为cygwin编译Poco源时出错

C++ 为cygwin编译Poco源时出错,c++,cygwin,poco,C++,Cygwin,Poco,我下载了适用于windows的poco-1.6-all,我正在尝试为cygwin构建它,我在执行make安装后遇到此错误我需要一些帮助,因为我不知道如何解决此NTDDI_版本错误: $ make install make -C /cygdrive/c/poco-1.6.0-all/Foundation make[1]: Entering directory '/cygdrive/c/poco-1.6.0-all/Foundation' mkdir -p /cygdrive/c/poco-1.6.

我下载了适用于windows的poco-1.6-all,我正在尝试为cygwin构建它,我在执行make安装后遇到此错误我需要一些帮助,因为我不知道如何解决此NTDDI_版本错误:

$ make install
make -C /cygdrive/c/poco-1.6.0-all/Foundation
make[1]: Entering directory '/cygdrive/c/poco-1.6.0-all/Foundation'
mkdir -p /cygdrive/c/poco-1.6.0-all/Foundation/obj/CYGWIN/x86_64/release_static
mkdir -p /cygdrive/c/poco-1.6.0-all/Foundation/obj/CYGWIN/x86_64/debug_static
mkdir -p /cygdrive/c/poco-1.6.0-all/Foundation/obj/CYGWIN/x86_64/release_shared
mkdir -p /cygdrive/c/poco-1.6.0-all/Foundation/obj/CYGWIN/x86_64/debug_shared
** Compiling src/ArchiveStrategy.cpp (debug, shared)
g++  -Iinclude -I/cygdrive/c/poco-1.6.0-all/CppUnit/include -I/cygdrive/c/poco-1.6.0-all/CppUnit/WinTestRunner/include -I/cygdrive/c/poco-1.6.0-all/Foundation/include -I/cygdrive/c/poco-1.6.0-all/XML/include -I/cygdrive/c/poco-1.6.0-all/JSON/include -I/cygdrive/c/poco-1.6.0-all/Util/include -I/cygdrive/c/poco-1.6.0-all/Net/include -I/cygdrive/c/poco-1.6.0-all/Crypto/include -I/cygdrive/c/poco-1.6.0-all/NetSSL_OpenSSL/include -I/cygdrive/c/poco-1.6.0-all/Data/include -I/cygdrive/c/poco-1.6.0-all/Data/SQLite/include -I/cygdrive/c/poco-1.6.0-all/Data/ODBC/include -I/cygdrive/c/poco-1.6.0-all/Data/MySQL/include -I/cygdrive/c/poco-1.6.0-all/MongoDB/include -I/cygdrive/c/poco-1.6.0-all/Zip/include -I/cygdrive/c/poco-1.6.0-all/PageCompiler/include -I/cygdrive/c/poco-1.6.0-all/PageCompiler/File2Page/include -DPOCO_NO_FPENVIRONMENT -DPOCO_NO_WSTRING -DPOCO_NO_SHAREDMEMORY -DPOCO_BUILD_HOST=PB00YCT7  -D_XOPEN_SOURCE=500  -g -D_DEBUG  -c src/ArchiveStrategy.cpp -o /cygdrive/c/poco-1.6.0-all/Foundation/obj/CYGWIN/x86_64/debug_shared/ArchiveStrategy.o
In file included from c:\mingw\include\_mingw.h:35:0,
                 from c:\mingw\include\windows.h:28,
                 from include/Poco/UnWindows.h:90,
                 from include/Poco/Platform_WIN32.h:24,
                 from include/Poco/Foundation.h:102,
                 from include/Poco/ArchiveStrategy.h:23,
                 from src/ArchiveStrategy.cpp:17:
c:\mingw\include\sdkddkver.h:137:8: error: #error The _WIN32_WINNT value does not match NTDDI_VERSION
 #      error The _WIN32_WINNT value does not match NTDDI_VERSION
        ^
In file included from include/Poco/ArchiveStrategy.h:23:0,
                 from src/ArchiveStrategy.cpp:17:
include/Poco/Foundation.h:122:4: error: #error POCO_WIN32_UTF8 and POCO_NO_WSTRING are mutually exclusive.
   #error POCO_WIN32_UTF8 and POCO_NO_WSTRING are mutually exclusive.
    ^
/cygdrive/c/poco-1.6.0-all/build/rules/compile:53: recipe for target '/cygdrive/c/poco-1.6.0-all/Foundation/obj/CYGWIN/x86_64/debug_shared/ArchiveStrategy.o' failed
make[1]: *** [/cygdrive/c/poco-1.6.0-all/Foundation/obj/CYGWIN/x86_64/debug_shared/ArchiveStrategy.o] Error 1
make[1]: Leaving directory '/cygdrive/c/poco-1.6.0-all/Foundation'
Makefile:69: recipe for target 'Foundation-libexec' failed
make: *** [Foundation-libexec] Error 2
下面是我用来编译de代码的行:

$ ./configure --config=CYGWIN --omit=NetSSL_OpenSSL,Crypto,Data/ODBC,Data/MySQ --prefix=./_INSTALL
$ make clean
$ make -j4 -nodemos
$ make install

感谢您对此错误的任何帮助。

这是因为与您的Windows操作系统版本相比,MinGW的
c:\MinGW\include\sdkddkver.h
已过时。请查看此页面:

并检查是否有一些
#define
未包含在提到的文件中。我刚刚使用Windows8.1,收到了相同的错误


一个解决方案可能是使用MinGW-like或任何

的更新版本,这帮助我解决了NTDDI错误,我还设法解决了POCO_WIN32_UTF8错误,但现在我陷入了这样的困境:target'/cygdrive/c/POCO-1.6.0-all/Foundation/obj/CYGWIN/x86_64/debug_shared/ArchiveStrategy.o'