“错误:在'''之前预期的非限定ID。”“用OpenSSL库编译C ++应用程序

时间:2014-06-24 17:34:29

标签: c++ netbeans openssl mingw

尝试编译使用OpenSSL库的代码时,收到以下错误:

In file included from util.h:28:0,
             from addrman.h:9,
             from addrman.cpp:5:
c:/local/openssl-0.9.8za/include/openssl/sha.h:1:1: error: expected unqualified-id before '.' token
../../crypto/sha/sha.h

列出的文件中包含以下代码行(这是唯一的代码行):

../../crypto/sha/sha.h

任何人都可以提供有关此问题的任何反馈吗?我在Netbeans项目中引用了OpenSSL库。

1 个答案:

答案 0 :(得分:3)

你可能有一个cygwin构建的OpenSSL安装,你试图在cygwin之外使用。

Windows没有符号链接,cygwin使用常规文本文件模拟它们。 Windows程序不会将这些文件视为符号链接。

如果您想继续使用OpenSSL安装,请将其“符号链接”替换为相应常规文件的副本。