7

我在 Windows 10 上使用 CLion 和 cmake 系统构建。我想为 http 请求添加这个 curlpp https://github.com/jpbarrette/curlpp 。我从 GitHub 下载 lib 并放入项目文件夹。接下来,我将其添加到我的 CMake 列表中:

add_subdirectory(curlpp-master)

不幸的是,Cmake抛出错误:

Error:Could NOT find CURL (missing: CURL_LIBRARY CURL_INCLUDE_DIR)

之后我决定添加原始的 C curl https://github.com/curl/curl,使用与 curlpp 相同的方式。所以现在看起来像这样:

add_subdirectory(curl-7.47.1)
add_subdirectory(curlpp-master)

但是我看到了同样的错误,没有找到 curl 库。如何正确添加 curlpp?

4

0 回答 0