【问题标题】:Using curlpp to make GET and POST calls to HTTP server使用 curlpp 对 HTTP 服务器进行 GET 和 POST 调用
【发布时间】:2013-10-08 05:46:35
【问题描述】:

嘿,我有相当多的编程经验,但已经有一段时间了。这是我在学校作业以外的第一个程序,所以我需要一些帮助,使用 curlpp 对服务器进行 HTTP 调用。我从谷歌代码页下载了 c++ curlpp 提取了 .tar.gz 然后将它与 Visual Studio 中的引用库链接,但是当我编译时出现此错误

1>------ Build started: Project: Crypto, Configuration: Debug Win32 ------
1>Build started 10/1/2013 12:19:24 PM.
1>InitializeBuildStatus:
1>  Touching "Debug\Crypto.unsuccessfulbuild".
1>GenerateTargetFrameworkMonikerAttribute:
1>Skipping target "GenerateTargetFrameworkMonikerAttribute" because all output files are up-to-date with respect to the input files.
1>ClCompile:
1>  main.cpp
1>c:\users\jay bell\documents\visual studio 2010\projects\crypto\crypto\curlpp\include\curlpp\cURLpp.hpp(34): fatal error C1083: Cannot open include file: 'curl/curl.h': No such file or directory
1>
1>Build FAILED.
1>
1>Time Elapsed 00:00:00.39
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

所以我知道 Visual Studio 正在寻找正确的位置,因为它位于 curl 头文件中,但在我看来,当它添加标题 (cURLpp.hpp) 时,它试图引用 curl/curl。 h 这在 curlpp 文件夹中不存在(我已经通过查找它确认了这一点)只是想知道是否有人可以帮助我解决这个问题我的代码中唯一的东西就是这个

#include "curlpp\include\curlpp\cURLpp.hpp"

using namespace System;

int main(array<System::String ^> ^args)
{

}

提前谢谢大家。

【问题讨论】:

  • 你有没有弄清楚问题出在哪里?
  • 天哪,我知道我做到了,但我不确定修复是什么,因为这是很久以前的事了,我把项目交给了一个程序员,他把它转换成 java!对不起!。

标签: c++ visual-studio-2010 visual-studio curl


【解决方案1】:

无法打开包含文件:'curl/curl.h':没有这样的文件或目录

要使用 curlpp,需要安装 libcurl。

【讨论】:

    猜你喜欢
    • 2018-05-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-05-03
    • 1970-01-01
    相关资源
    最近更新 更多