1、使用跟程序相同的选项编译libcurl静态库;
2、程序中在引入curl头文件前定义
#define CURL_STATICLIB //HTTP_ONLY
3、引入库:
#if defined(_DEBUG)
#pragma comment(lib, "libcurld.lib")
#else
#pragma comment(lib, "libcurl.lib")
#endif
#pragma comment ( lib, "ws2_32.lib" )
#pragma comment ( lib, "wldap32.lib" )
2、程序中在引入curl头文件前定义
#define CURL_STATICLIB //HTTP_ONLY
3、引入库:
#if defined(_DEBUG)
#pragma comment(lib, "libcurld.lib")
#else
#pragma comment(lib, "libcurl.lib")
#endif
#pragma comment ( lib, "ws2_32.lib" )
#pragma comment ( lib, "wldap32.lib" )