简体   繁体   English

C ++ lib curl编译混乱吗?

[英]c++ lib curl compilation confusion?

I am trying to use libcurl in one of c++ application where I need to download a file from a server using this. 我试图在C ++应用程序之一中使用libcurl,我需要使用它从服务器下载文件。 I am using libcurl for this. 我为此使用libcurl。 But I am facing deficulties while compiling and linking it.I compiled libcurl and got only libcurl.lib and no dll file. 但是我在编译和链接它时遇到了困难。我编译了libcurl,只有libcurl.lib而没有dll文件。

This is error. 这是错误。

1>------ Build started: Project: 34343, Configuration: Release Win32 ------
1>  34343.cpp
1>c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(96): error C2872: 'IServiceProvider' : ambiguous symbol
1>          could be 'c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(53) : System::IServiceProvider IServiceProvider'
1>          or       'c:\program files (x86)\reference assemblies\microsoft\framework\.netframework\v4.0\mscorlib.dll : System::IServiceProvider'
1>c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(96): error C3699: '*' : cannot use this indirection on type 'IServiceProvider'
1>          compiler replacing '*' with '^' to continue parsing
1>c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(103): error C2371: 'IServiceProvider' : redefinition; different basic types
1>          c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(53) : see declaration of 'IServiceProvider'
1>c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(120): error C2872: 'IServiceProvider' : ambiguous symbol
1>          could be 'c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(103) : IServiceProvider'
1>          or       'c:\program files (x86)\reference assemblies\microsoft\framework\.netframework\v4.0\mscorlib.dll : System::IServiceProvider'
1>c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(241): error C2872: 'IServiceProvider' : ambiguous symbol
1>          could be 'c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(103) : IServiceProvider'
1>          or       'c:\program files (x86)\reference assemblies\microsoft\framework\.netframework\v4.0\mscorlib.dll : System::IServiceProvider'
1>c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(251): error C2872: 'IServiceProvider' : ambiguous symbol
1>          could be 'c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(103) : IServiceProvider'
1>          or       'c:\program files (x86)\reference assemblies\microsoft\framework\.netframework\v4.0\mscorlib.dll : System::IServiceProvider'
1>C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\include\urlmon.h(6459): error C2872: 'IServiceProvider' : ambiguous symbol
1>          could be 'c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(103) : IServiceProvider'
1>          or       'c:\program files (x86)\reference assemblies\microsoft\framework\.netframework\v4.0\mscorlib.dll : System::IServiceProvider'
1>C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\include\urlmon.h(6461): error C2872: 'IServiceProvider' : ambiguous symbol
1>          could be 'c:\program files (x86)\microsoft sdks\windows\v7.0a\include\servprov.h(103) : IServiceProvider'
1>          or       'c:\program files (x86)\reference assemblies\microsoft\framework\.netframework\v4.0\mscorlib.dll : System::IServiceProvider'
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

There is a visual studio project in libcurl\\src\\ . libcurl\\src\\有一个Visual Studio项目。 Are you using it? 你在用吗? It works great for me. 这对我很有效。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM