Several conflicting types when building :-(
Olivier34 opened this issue · 3 comments
jni/../../curl/lib/easy.c:370:19: error: conflicting types for 'curl_easy_init'
struct Curl_easy curl_easy_init(void)
^
jni/../../curl/include/curl/easy.h:28:19: note: previous declaration is here
CURL_EXTERN CURL *curl_easy_init(void);
^
jni/../../curl/lib/easy.c:401:10: error: conflicting types for 'curl_easy_setopt'
CURLcode curl_easy_setopt(struct Curl_easy *data, CURLoption tag, ...)
^
jni/../../curl/include/curl/easy.h:29:22: note: previous declaration is here
CURL_EXTERN CURLcode curl_easy_setopt(CURL *curl, CURLoption option, ...);
^
jni/../../curl/lib/easy.c:831[arm64-v8a] Compile : curl <= getenv.c
:10: error: conflicting types for 'curl_easy_perform'
CURLcode curl_easy_perform(struct Curl_easy *data)
^
jni/../../curl/include/curl/easy.h:30:22: note: previous declaration is here
CURL_EXTERN CURLcode curl_easy_perform(CURL *curl);
^
jni/../../curl/lib/easy.c:852:6: error: conflicting types for 'curl_easy_cleanup'
void curl_easy_cleanup(struct Curl_easy *data)
^
jni/../../curl/include/curl/easy.h:31:18: note: previous declaration is here
CURL_EXTERN void curl_easy_cleanup(CURL *curl);
^
jni/../../curl/lib/easy.c:869:10: error: conflicting types for 'curl_easy_getinfo'
CURLcode curl_easy_getinfo(struct Curl_easy *data, CURLINFO info, ...)
^
jni/../../curl/include/curl/easy.h:46:22: note: previous declaration is here
CURL_EXTERN CURLcode curl_easy_getinfo(CURL *curl, CURLINFO info, ...);
^
jni/../../curl/lib/easy.c:889:19: error: conflicting types for 'curl_easy_duphandle'
struct Curl_easy *curl_easy_duphandle(struct Curl_easy *data)
^
jni/../../curl/include/curl/easy.h:61:19: note: previous declaration is here
CURL_EXTERN CURL curl_easy_duphandle(CURL curl);
^
jni/../../curl/lib/easy.c:982:6: error: conflicting types for 'curl_easy_reset'
void curl_easy_reset(struct Curl_easy *data)
^
jni/../../curl/include/curl/easy.h:74:18: note: previous declaration is here
CURL_EXTERN void curl_easy_reset(CURL *curl);
^
jni/../../curl/lib/easy.c:1012:10: error: conflicting types for 'curl_easy_pause'
CURLcode curl_easy_pause(struct Curl_easy *data, int action)
^
jni/../../curl/include/curl/curl.h:2413:22: note: previous declaration is here
CURL_EXTERN CURLcode curl_easy_pause(CURL *handle, int bitmask);
^
[arm64-v8a] Compile : curl <= getinfo.c
jni/../../curl/lib/easy.c:1081:10: error: conflicting types for 'curl_easy_recv'
CURLcode curl_easy_recv(struct Curl_easy *data, void *buffer, size_t buflen,
^
jni/../../curl/include/curl/easy.h:84:22: note: previous declaration is here
CURL_EXTERN CURLcode curl_easy_recv(CURL *curl, void *buffer, size_t buflen,
^
jni/../../curl/lib/easy.c:1108:10: error: conflicting types for 'curl_easy_send'
CURLcode curl_easy_send(struct Curl_easy *data, const void *buffer,
^
jni/../../curl/include/curl/easy.h:95:22: note: previous declaration is here
CURL_EXTERN CURLcode curl_easy_send(CURL *curl, const void *buffer,
^
10 errors generated.
/home/olivier/Android/Sdk/ndk-bundle/build/core/build-binary.mk:497 : la recette pour la cible « obj/local/arm64-v8a/objs/curl///curl/lib/easy.o » a échouée
make: ** [obj/local/arm64-v8a/objs/curl///curl/lib/easy.o] Erreur 1
make: *** Attente des tâches non terminées....
jni/../../curl/lib/escape.c:78:7: error: conflicting types for 'curl_easy_escape'
char *curl_easy_escape(struct Curl_easy *data, const char *string,
^
jni/../../curl/include/curl/curl.h:1996:19: note: previous declaration is here
CURL_EXTERN char *curl_easy_escape(CURL *handle,
^
jni/../../curl/lib/escape.c:216:7: error: conflicting types for 'curl_easy_unescape'
char *curl_easy_unescape(struct Curl_easy *data, const char *string,
^
jni/../../curl/include/curl/curl.h:2016:19: note: previous declaration is here
CURL_EXTERN char *curl_easy_unescape(CURL *handle,
^
2 errors generated.
@Olivier34 you can checkout https://github.com/eaglewangy/curl-android-ios
It works on 7_50_3
I'm encountering this error as well and stumbled onto this page. Can anyone give some clue as to what's going on here and how to fix it without just downloading a precompiled version?
Add -DBUILDING_LIBCURL to your CFLAGS and it should work!.