You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been trying to compile the most basic "hello world" program for cpr but it keep getting the same errors regardless of the method that I use to include the cpr library.
I'm using C++20 and the 1.10.x cpr branch
Errors that I'm getting:
error C2143: syntax error: missing ';' before '*' error C4430: missing type specifier - int assumed. Note: C++ does not support default-int error C2334: unexpected token(s) preceding '{'; skipping apparent function body error C2065: 'CURL_PROGRESSFUNC_CONTINUE': undeclared identifier error C3861: 'CURL_PROGRESSFUNC_CONTINUE': identifier not found
Things that I've tried:
Compiling cpr using cmake:
I've tried to build the library by myself using the following commands (I couldn't do cmake install because there seems to be another bug with that): cmake .. -DCPR_USE_SYSTEM_CURL=OFF -DBUILD_SHARED_LIBS=OFF cmake --build . --parallel
Cloning the library directly using cmake include(FetchContent) FetchContent_Declare(cpr GIT_REPOSITORY https://github.com/libcpr/cpr.git GIT_TAG 3b15fa82ea74739b574d705fea44959b58142eb8) FetchContent_MakeAvailable(cpr)
Description
I've been trying to compile the most basic "hello world" program for cpr but it keep getting the same errors regardless of the method that I use to include the cpr library.
I'm using C++20 and the 1.10.x cpr branch
Errors that I'm getting:
error C2143: syntax error: missing ';' before '*'
error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
error C2334: unexpected token(s) preceding '{'; skipping apparent function body
error C2065: 'CURL_PROGRESSFUNC_CONTINUE': undeclared identifier
error C3861: 'CURL_PROGRESSFUNC_CONTINUE': identifier not found
Things that I've tried:
I've tried to build the library by myself using the following commands (I couldn't do cmake install because there seems to be another bug with that):
cmake .. -DCPR_USE_SYSTEM_CURL=OFF -DBUILD_SHARED_LIBS=OFF
cmake --build . --parallel
include(FetchContent)
FetchContent_Declare(cpr GIT_REPOSITORY https://github.com/libcpr/cpr.git GIT_TAG 3b15fa82ea74739b574d705fea44959b58142eb8)
FetchContent_MakeAvailable(cpr)
Source code
Example/How to Reproduce
Possible Fix
No response
Where did you get it from?
GitHub (branch e.g. master)
Additional Context/Your Environment
The text was updated successfully, but these errors were encountered: