c++ - C++ - 如何在 CodeBlocks 中链接 OpenSSL 库?
问题描述
我正在尝试在 CodeBlocks 中链接 OpenSSL。我已将文件移至“include”目录,并且已将“configuration.h.in”的名称更改为“configuration.h”,但现在我收到此错误:
||=== Build: Debug in lokk (compiler: Cywin) ===|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\configuration.h|27|error: expected identifier or '(' before '{' token|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\configuration.h|27|error: stray '@' in program|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\configuration.h|28|error: stray '@' in program|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\configuration.h|34|error: stray '@' in program|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\configuration.h|38|error: stray '@' in program|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\configuration.h|39|error: stray '@' in program|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\configuration.h|49|error: expected identifier or '(' before '{' token|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\configuration.h|55|error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\configuration.h|57|error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\configuration.h|58|error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\configuration.h|59|error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\macros.h|104|error: token "{" is not valid in preprocessor expressions|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\macros.h|112|error: token "{" is not valid in preprocessor expressions|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\macros.h|116|error: token "{" is not valid in preprocessor expressions|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\macros.h|120|error: token "{" is not valid in preprocessor expressions|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\macros.h|139|error: token "{" is not valid in preprocessor expressions|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\macros.h|149|error: token "{" is not valid in preprocessor expressions|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\macros.h|159|error: token "{" is not valid in preprocessor expressions|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\macros.h|169|error: token "{" is not valid in preprocessor expressions|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\macros.h|179|error: token "{" is not valid in preprocessor expressions|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\macros.h|189|error: token "{" is not valid in preprocessor expressions|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\macros.h|199|error: token "{" is not valid in preprocessor expressions|
C:\Program Files (x86)\DevCpp\MinGW64\x86_64-w64-mingw32\include\stddef.h|24|error: expected ',' or ';' before 'extern'|
C:\Program Files (x86)\DevCpp\MinGW64\include\openssl\types.h|20|fatal error: openssl/safestack.h: No such file or directory|
||=== Build failed: 24 error(s), 0 warning(s) (0 minute(s), 0 second(s)) ===|
如果有人可以帮助我,非常感谢。
解决方案
推荐阅读
- android - 在 Android 上执行周期性任务的最可靠方法
- java - TemplateInputException:模板解析期间发生错误(模板:“类路径资源[templates/index.html]”)
- task - DAG 中的任务在已运行时尝试运行
- css - 如何在图像上使用边框半径制作插入边框
- debugging - 谷歌表格应用程序脚本
- python - 到特定目标的 k-最近点
- bash - 如何允许用户使用退格键退出回到 main_menu.sh,具体取决于用户是否直接调用它
- go - apm SetCustom 函数导致随机恐慌
- javascript - 从 Jinja2 宏返回数据到 Python
- nagios - Nagios 不发送服务警报