ARPA-SIMC/arkimet

Curl deprecated functions in Fedora 38 build

edigiacomo opened this issue · 0 comments

2023-05-31 07:33:43 INFO system.fedora38 stderr: In file included from core/curl.cc:1:
2023-05-31 07:33:43 INFO system.fedora38 stderr: core/curl.h: In member function 'size_t arki::core::curl::BufState<Container>::process_body_chunk(void*, size_t, size_t, void*)':
2023-05-31 07:33:43 INFO system.fedora38 stderr: core/curl.h:123:32: error: 'uint8_t' was not declared in this scope
2023-05-31 07:33:43 INFO system.fedora38 stderr:   123 |         buf.insert(buf.end(), (uint8_t*)ptr, (uint8_t*)ptr + size * nmemb);
2023-05-31 07:33:43 INFO system.fedora38 stderr:       |                                ^~~~~~~
2023-05-31 07:33:43 INFO system.fedora38 stderr: core/curl.h:7:1: note: 'uint8_t' is defined in header '<cstdint>'; did you forget to '#include <cstdint>'?
2023-05-31 07:33:43 INFO system.fedora38 stderr:     6 | #include <sstream>
2023-05-31 07:33:43 INFO system.fedora38 stderr:   +++ |+#include <cstdint>
2023-05-31 07:33:43 INFO system.fedora38 stderr:     7 |
2023-05-31 07:33:43 INFO system.fedora38 stderr: core/curl.h:123:40: error: expected primary-expression before ')' token
2023-05-31 07:33:43 INFO system.fedora38 stderr:   123 |         buf.insert(buf.end(), (uint8_t*)ptr, (uint8_t*)ptr + size * nmemb);
2023-05-31 07:33:43 INFO system.fedora38 stderr:       |                                        ^
2023-05-31 07:33:43 INFO system.fedora38 stderr: core/curl.h:123:55: error: expected primary-expression before ')' token
2023-05-31 07:33:43 INFO system.fedora38 stderr:   123 |         buf.insert(buf.end(), (uint8_t*)ptr, (uint8_t*)ptr + size * nmemb);
2023-05-31 07:33:43 INFO system.fedora38 stderr:       |                                                       ^
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc: In destructor 'arki::core::curl::CurlForm::~CurlForm()':
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc:55:28: error: 'void curl_formfree(curl_httppost*)' is deprecated: since 7.56.0. Use curl_mime_free() [-Werror=deprecated-declarations]
2023-05-31 07:33:44 INFO system.fedora38 stderr:    55 |     if (post) curl_formfree(post);
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |               ~~~~~~~~~~~~~^~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: In file included from core/curl.h:4:
2023-05-31 07:33:44 INFO system.fedora38 stderr: /usr/include/curl/curl.h:2612:1: note: declared here
2023-05-31 07:33:44 INFO system.fedora38 stderr:  2612 | curl_formfree(struct curl_httppost *form);
2023-05-31 07:33:44 INFO system.fedora38 stderr:       | ^~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc: In member function 'void arki::core::curl::CurlForm::clear()':
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc:60:28: error: 'void curl_formfree(curl_httppost*)' is deprecated: since 7.56.0. Use curl_mime_free() [-Werror=deprecated-declarations]
2023-05-31 07:33:44 INFO system.fedora38 stderr:    60 |     if (post) curl_formfree(post);
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |               ~~~~~~~~~~~~~^~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: /usr/include/curl/curl.h:2612:1: note: declared here
2023-05-31 07:33:44 INFO system.fedora38 stderr:  2612 | curl_formfree(struct curl_httppost *form);
2023-05-31 07:33:44 INFO system.fedora38 stderr:       | ^~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc: In member function 'void arki::core::curl::CurlForm::add_string(const std::string&, const std::string&)':
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc:67:13: error: 'CURLFORM_COPYNAME' is deprecated: since 7.56.0. Use curl_mime_name() [-Werror=deprecated-declarations]
2023-05-31 07:33:44 INFO system.fedora38 stderr:    67 |             CURLFORM_COPYNAME, key.c_str(),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |             ^~~~~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: /usr/include/curl/curl.h:2501:3: note: declared here
2023-05-31 07:33:44 INFO system.fedora38 stderr:  2501 |   CURLFORM_COPYNAME        CURL_DEPRECATED(7.56.0, "Use curl_mime_name()"),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |   ^~~~~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc:68:13: error: 'CURLFORM_COPYCONTENTS' is deprecated: since 7.56.0. Use curl_mime_data() [-Werror=deprecated-declarations]
2023-05-31 07:33:44 INFO system.fedora38 stderr:    68 |             CURLFORM_COPYCONTENTS, val.c_str(),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |             ^~~~~~~~~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: /usr/include/curl/curl.h:2504:3: note: declared here
2023-05-31 07:33:44 INFO system.fedora38 stderr:  2504 |   CURLFORM_COPYCONTENTS    CURL_DEPRECATED(7.56.0, "Use curl_mime_data()"),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |   ^~~~~~~~~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc:66:17: error: 'CURLFORMcode curl_formadd(curl_httppost**, curl_httppost**, ...)' is deprecated: since 7.56.0. Use curl_mime_init() [-Werror=deprecated-declarations]
2023-05-31 07:33:44 INFO system.fedora38 stderr:    66 |     curl_formadd(&post, &last,
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |     ~~~~~~~~~~~~^~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr:    67 |             CURLFORM_COPYNAME, key.c_str(),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr:    68 |             CURLFORM_COPYCONTENTS, val.c_str(),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr:    69 |             CURLFORM_END);
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |             ~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: /usr/include/curl/curl.h:2576:1: note: declared here
2023-05-31 07:33:44 INFO system.fedora38 stderr:  2576 | curl_formadd(struct curl_httppost **httppost,
2023-05-31 07:33:44 INFO system.fedora38 stderr:       | ^~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc: In member function 'void arki::core::curl::CurlForm::add_file(const std::string&, const std::string&)':
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc:75:13: error: 'CURLFORM_COPYNAME' is deprecated: since 7.56.0. Use curl_mime_name() [-Werror=deprecated-declarations]
2023-05-31 07:33:44 INFO system.fedora38 stderr:    75 |             CURLFORM_COPYNAME, key.c_str(),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |             ^~~~~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: /usr/include/curl/curl.h:2501:3: note: declared here
2023-05-31 07:33:44 INFO system.fedora38 stderr:  2501 |   CURLFORM_COPYNAME        CURL_DEPRECATED(7.56.0, "Use curl_mime_name()"),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |   ^~~~~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc:76:13: error: 'CURLFORM_FILE' is deprecated: since 7.56.0. Use curl_mime_filedata() [-Werror=deprecated-declarations]
2023-05-31 07:33:44 INFO system.fedora38 stderr:    76 |             CURLFORM_FILE, pathname.c_str(),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |             ^~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: /usr/include/curl/curl.h:2510:3: note: declared here
2023-05-31 07:33:44 INFO system.fedora38 stderr:  2510 |   CURLFORM_FILE            CURL_DEPRECATED(7.56.0, "Use curl_mime_filedata()"),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |   ^~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc:74:17: error: 'CURLFORMcode curl_formadd(curl_httppost**, curl_httppost**, ...)' is deprecated: since 7.56.0. Use curl_mime_init() [-Werror=deprecated-declarations]
2023-05-31 07:33:44 INFO system.fedora38 stderr:    74 |     curl_formadd(&post, &last,
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |     ~~~~~~~~~~~~^~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr:    75 |             CURLFORM_COPYNAME, key.c_str(),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr:    76 |             CURLFORM_FILE, pathname.c_str(),
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr:    77 |             CURLFORM_END);
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |             ~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: /usr/include/curl/curl.h:2576:1: note: declared here
2023-05-31 07:33:44 INFO system.fedora38 stderr:  2576 | curl_formadd(struct curl_httppost **httppost,
2023-05-31 07:33:44 INFO system.fedora38 stderr:       | ^~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc: In member function 'virtual void arki::core::curl::Request::perform()':
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc:109:65: error: 'CURLOPT_HTTPPOST' is deprecated: since 7.56.0. Use CURLOPT_MIMEPOST [-Werror=deprecated-declarations]
2023-05-31 07:33:44 INFO system.fedora38 stderr:   109 |             checked("setting POST data", curl_easy_setopt(curl, CURLOPT_HTTPPOST, post_data.get()));
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |                                                                 ^~~~~~~~~~~~~~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: core/curl.cc:11:28: note: in definition of macro 'checked'
2023-05-31 07:33:44 INFO system.fedora38 stderr:    11 |         CURLcode errcode = stmt; \
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |                            ^~~~
2023-05-31 07:33:44 INFO system.fedora38 stderr: /usr/include/curl/curl.h:1196:3: note: declared here
2023-05-31 07:33:44 INFO system.fedora38 stderr:  1196 |   CURLOPTDEPRECATED(CURLOPT_HTTPPOST, CURLOPTTYPE_OBJECTPOINT, 24,
2023-05-31 07:33:44 INFO system.fedora38 stderr:       |   ^~~~~~~~~~~~~~~~~