问:
cannot build cpr library from vcpkg
Hello i'm fairy new to C++ i've been trying to use cpr , i've installed it with vcpkg

here is my cmakelists.txt

```<code>
set (CMAKE_CXX_STANDARD 11)
set(VCPKG_TARGET_TRIPLET x64-mingw-dynamic)
include(path/vcpkg/scripts/buildsystems/vcpkg.cmake)

add_executable(Scrapy main.cpp)

find_package(cpr CONFIG REQUIRED)
target_link_libraries(${PROJECT_NAME} PRIVATE cpr::cpr )

</code>```

and here is my main.cpp

```<code>#include <cpr/cpr.h>
int main(int, char**) {

cpr::Response r = cpr::Get(cpr::Url{"https://docs.libcpr.org/"});
r.status_code;
r.header["content-type"];
r.text;
printf("it works" );
return 0;

}
</code>```

now when i try and lunch main.cpp
this what i get in the output

```
cpr::Session::Session():
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:71: undefined reference to `operator new(unsigned long long)

[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:160: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::substr(unsigned long long, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:191: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::reserve(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `cpr::Session::SetSslOptions(cpr::SslOptions const&)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:488: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::operator[](unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `cpr::Session::GetDownloadFileLength()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:647: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find(char, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:647: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::substr(unsigned long long, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `_M_create<cpr::ThreadPool::Submit<cpr::Session::GetAsync()::<lambda()> >(cpr::Session::GetAsync()::<lambda()>&&)::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `_M_create<cpr::ThreadPool::Submit<cpr::Session::DeleteAsync()::<lambda()> >(cpr::Session::DeleteAsync()::<lambda()>&&)::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `_M_create<cpr::ThreadPool::Submit<cpr::Session::DownloadAsync(const cpr::WriteCallback&)::<lambda()> >(cpr::Session::DownloadAsync(const cpr::WriteCallback&)::<lambda()>&&)::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `_M_create<cpr::ThreadPool::Submit<cpr::Session::DownloadAsync(std::ofstream&)::<lambda()> >(cpr::Session::DownloadAsync(std::ofstream&)::<lambda()>&&)::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `_M_create<cpr::ThreadPool::Submit<cpr::Session::HeadAsync()::<lambda()> >(cpr::Session::HeadAsync()::<lambda()>&&)::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj):C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: more undefined references to `operator new(unsigned long long)' follow
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__cxx11::to_string(long long)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.h:4068: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::basic_string(unsigned long long, char, std::allocator const&)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.h:4069: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::operator[](unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__future_base::_State_baseV2::_M_set_delayed_result(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>, std::weak_ptrstd::__future_base::_State_baseV2)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/future:430: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__cxx11::basic_string<char, std::char_traits, std::allocator > std::operator+<char, std::char_traits, std::allocator >(char const*, std::__cxx11::basic_string<char, std::char_traits, std::allocator >&&)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.h:3541: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::insert(unsigned long long, char const*)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__cxx11::basic_string<char, std::char_traits, std::allocator > std::operator+<char, std::char_traits, std::allocator >(char const*, std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.tcc:618: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::reserve(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.tcc:619: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::append(char const*, unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_countcpr::CurlHolder*(cpr::CurlHolder*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/shared_ptr_base.h:917: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__new_allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > >::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__new_allocatorcpr::Parameter::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__new_allocator<std::shared_ptrcpr::Interceptor>::allocate(unsigned long long, void const)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__new_allocator<curl_forms>::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj):C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: more undefined references to `operator new(unsigned long long)' follow
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(threadpool.cpp.obj): in function `time':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/time.h:256: undefined reference to `__imp__time64'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(threadpool.cpp.obj): in function `cpr::ThreadPool::CreateThread()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/threadpool.cpp:108: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(threadpool.cpp.obj): in function `thread<cpr::ThreadPool::CreateThread()::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_thread.h:142: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(threadpool.cpp.obj): in function `std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_countstd::thread*(std::thread*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/shared_ptr_base.h:917: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(threadpool.cpp.obj): in function `std::__new_allocator<std::_List_nodecpr::ThreadPool::ThreadData >::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::parseHeader(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&, std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::__cxx11::basic_string<char, std::char_traits, std::allocator >)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:71: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::substr(unsigned long long, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:74: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find_last_not_of(char const*, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:74: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::resize(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:81: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find_first_of(char const*, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:84: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find_first_of(char const*, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:87: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::erase(unsigned long long, unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:96: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find(char, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:98: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::substr(unsigned long long, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:99: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find_first_not_of(char const*, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:99: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::erase(unsigned long long, unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find_last_not_of(char const*, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::resize(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:101: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::substr(unsigned long long, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::headerUserFunction(char*, unsigned long long, unsigned long long, cpr::HeaderCallback const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:128: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::basic_string(char const*, unsigned long long, std::allocator const&)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::writeFunction(char*, unsigned long long, unsigned long long, std::__cxx11::basic_string<char, std::char_traits, std::allocator >)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:133: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::append(char const, unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::writeFileFunction(char*, unsigned long long, unsigned long long, std::basic_ofstream<char, std::char_traits >)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:139: undefined reference to `std::ostream::write(char const, long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::writeUserFunction(char*, unsigned long long, unsigned long long, cpr::WriteCallback const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:145: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::basic_string(char const*, unsigned long long, std::allocator const&)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::debugUserFunction(void*, curl_infotype, char*, unsigned long long, cpr::DebugCallback const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:157: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::basic_string(char const*, unsigned long long, std::allocator const&)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `__gnu_cxx::__stoa<unsigned long, unsigned long, char, int>(unsigned long ()(char const, char**, int), char const*, char const*, unsigned long long*, int)::_Save_errno::_Save_errno()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/ext/string_conversions.h:63: undefined reference to `__imp__errno'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/ext/string_conversions.h:63: undefined reference to `__imp__errno'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `__gnu_cxx::__stoa<unsigned long, unsigned long, char, int>(unsigned long ()(char const, char**, int), char const*, char const*, unsigned long long*, int)::_Save_errno::~_Save_errno()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/ext/string_conversions.h:64: undefined reference to `__imp__errno'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/ext/string_conversions.h:64: undefined reference to `__imp__errno'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `unsigned long __gnu_cxx::__stoa<unsigned long, unsigned long, char, int>(unsigned long ()(char const, char**, int), char const*, char const*, unsigned long long*, int)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/ext/string_conversions.h:84: undefined reference to `__imp__errno'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(response.cpp.obj): in function `cpr::Response::Response(std::shared_ptrcpr::CurlHolder, std::__cxx11::basic_string<char, std::char_traits, std::allocator >&&, std::__cxx11::basic_string<char, std::char_traits, std::allocator >&&, cpr::Cookies&&, cpr::Error&&)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/response.cpp:7: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/response.cpp:8: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(response.cpp.obj): in function `cpr::Response::GetCertInfos()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/response.cpp:28: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/response.cpp:29: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(response.cpp.obj): in function `std::__new_allocatorcpr::CertInfo::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(accept_encoding.cpp.obj): in function `std::__cxx11::basic_string<char, std::char_traits, std::allocator > std::operator+<char, std::char_traits, std::allocator >(std::__cxx11::basic_string<char, std::char_traits, std::allocator >&&, std::__cxx11::basic_string<char, std::char_traits, std::allocator >&&)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.h:3531: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::insert(unsigned long long, std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(async.cpp.obj): in function `cpr::GlobalThreadPool::GetInstance()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/async.cpp:6: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(cookies.cpp.obj): in function `gmtime_s':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/time.h:264: undefined reference to `__imp__gmtime64_s'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(cookies.cpp.obj): in function `std::__new_allocatorcpr::Cookie::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(curl_container.cpp.obj): in function `std::__new_allocatorcpr::Pair::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(curlholder.cpp.obj): in function `cpr::CurlHolder::CurlHolder()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/curlholder.cpp:18: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(curlholder.cpp.obj): in function `cpr::CurlHolder::urlEncode(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&) const':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/curlholder.cpp:28: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(curlholder.cpp.obj): in function `cpr::CurlHolder::urlDecode(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&) const':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/curlholder.cpp:39: undefined reference to `__imp__assert'
[build] collect2: error: ld returned 1 exit status
[build] make[3]: *** [CMakeFiles/Scrapy.dir/build.make:103: Scrapy.exe] Error 1
[build] make[2]: *** [CMakeFiles/Makefile2:83: CMakeFiles/Scrapy.dir/all] Error 2
[build] make[1]: *** [CMakeFiles/Makefile2:90: CMakeFiles/Scrapy.dir/rule] Error 2
[build] make: *** [Makefile:154: Scrapy] Error 2
[proc] The command: "C:\Program Files\CMake\bin\cmake.EXE" --build c:/Users/mehdi/OneDrive/Documents/1.0/C++/Scrap/build --config Debug --target Scrapy -j 10 -- exited with code: 2 and signal: null
[build] Build finished with exit code 2
```

OS : windows 8 64x
compiler : mingw
IDE : vscodium

I've tried to use it the same way on ubuntu and it works fine

Title: cannot build cpr library from vcpkg

Body:
Hello i'm fairy new to C++ i've been trying to use cpr , i've installed it with vcpkg

here is my cmakelists.txt

set (CMAKE_CXX_STANDARD 11)
set(VCPKG_TARGET_TRIPLET x64-mingw-dynamic)
include(path/vcpkg/scripts/buildsystems/vcpkg.cmake)

add_executable(Scrapy main.cpp)

find_package(cpr CONFIG REQUIRED)
target_link_libraries(${PROJECT_NAME} PRIVATE cpr::cpr )

and here is my main.cpp

#include <cpr/cpr.h>
int main(int, char**) {

cpr::Response r = cpr::Get(cpr::Url{"https://docs.libcpr.org/"});
r.status_code;
r.header["content-type"];
r.text;
printf("it works" );
return 0;

}

now when i try and lunch main.cpp
this what i get in the output

cpr::Session::Session():
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:71: undefined reference to `operator new(unsigned long long)

[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:160: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::substr(unsigned long long, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:191: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::reserve(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `cpr::Session::SetSslOptions(cpr::SslOptions const&)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:488: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::operator[](unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `cpr::Session::GetDownloadFileLength()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:647: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find(char, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/session.cpp:647: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::substr(unsigned long long, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `_M_create<cpr::ThreadPool::Submit<cpr::Session::GetAsync()::<lambda()> >(cpr::Session::GetAsync()::<lambda()>&&)::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `_M_create<cpr::ThreadPool::Submit<cpr::Session::DeleteAsync()::<lambda()> >(cpr::Session::DeleteAsync()::<lambda()>&&)::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `_M_create<cpr::ThreadPool::Submit<cpr::Session::DownloadAsync(const cpr::WriteCallback&)::<lambda()> >(cpr::Session::DownloadAsync(const cpr::WriteCallback&)::<lambda()>&&)::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `_M_create<cpr::ThreadPool::Submit<cpr::Session::DownloadAsync(std::ofstream&)::<lambda()> >(cpr::Session::DownloadAsync(std::ofstream&)::<lambda()>&&)::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `_M_create<cpr::ThreadPool::Submit<cpr::Session::HeadAsync()::<lambda()> >(cpr::Session::HeadAsync()::<lambda()>&&)::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj):C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_function.h:161: more undefined references to `operator new(unsigned long long)' follow
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__cxx11::to_string(long long)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.h:4068: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::basic_string(unsigned long long, char, std::allocator const&)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.h:4069: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::operator[](unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__future_base::_State_baseV2::_M_set_delayed_result(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>, std::weak_ptrstd::__future_base::_State_baseV2)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/future:430: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__cxx11::basic_string<char, std::char_traits, std::allocator > std::operator+<char, std::char_traits, std::allocator >(char const*, std::__cxx11::basic_string<char, std::char_traits, std::allocator >&&)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.h:3541: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::insert(unsigned long long, char const*)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__cxx11::basic_string<char, std::char_traits, std::allocator > std::operator+<char, std::char_traits, std::allocator >(char const*, std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.tcc:618: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::reserve(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.tcc:619: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::append(char const*, unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_countcpr::CurlHolder*(cpr::CurlHolder*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/shared_ptr_base.h:917: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__new_allocator<std::__cxx11::basic_string<char, std::char_traits, std::allocator > >::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__new_allocatorcpr::Parameter::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__new_allocator<std::shared_ptrcpr::Interceptor>::allocate(unsigned long long, void const)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj): in function `std::__new_allocator<curl_forms>::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(session.cpp.obj):C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: more undefined references to `operator new(unsigned long long)' follow
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(threadpool.cpp.obj): in function `time':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/time.h:256: undefined reference to `__imp__time64'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(threadpool.cpp.obj): in function `cpr::ThreadPool::CreateThread()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/threadpool.cpp:108: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(threadpool.cpp.obj): in function `thread<cpr::ThreadPool::CreateThread()::<lambda()> >':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/std_thread.h:142: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(threadpool.cpp.obj): in function `std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_countstd::thread*(std::thread*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/shared_ptr_base.h:917: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(threadpool.cpp.obj): in function `std::__new_allocator<std::_List_nodecpr::ThreadPool::ThreadData >::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::parseHeader(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&, std::__cxx11::basic_string<char, std::char_traits, std::allocator >, std::__cxx11::basic_string<char, std::char_traits, std::allocator >)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:71: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::substr(unsigned long long, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:74: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find_last_not_of(char const*, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:74: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::resize(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:81: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find_first_of(char const*, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:84: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find_first_of(char const*, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:87: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::erase(unsigned long long, unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:96: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find(char, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:98: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::substr(unsigned long long, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:99: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find_first_not_of(char const*, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:99: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::erase(unsigned long long, unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::find_last_not_of(char const*, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::resize(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:101: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::substr(unsigned long long, unsigned long long) const'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::headerUserFunction(char*, unsigned long long, unsigned long long, cpr::HeaderCallback const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:128: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::basic_string(char const*, unsigned long long, std::allocator const&)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::writeFunction(char*, unsigned long long, unsigned long long, std::__cxx11::basic_string<char, std::char_traits, std::allocator >)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:133: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::append(char const, unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::writeFileFunction(char*, unsigned long long, unsigned long long, std::basic_ofstream<char, std::char_traits >)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:139: undefined reference to `std::ostream::write(char const, long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::writeUserFunction(char*, unsigned long long, unsigned long long, cpr::WriteCallback const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:145: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::basic_string(char const*, unsigned long long, std::allocator const&)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `cpr::util::debugUserFunction(void*, curl_infotype, char*, unsigned long long, cpr::DebugCallback const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/util.cpp:157: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::basic_string(char const*, unsigned long long, std::allocator const&)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `__gnu_cxx::__stoa<unsigned long, unsigned long, char, int>(unsigned long ()(char const, char**, int), char const*, char const*, unsigned long long*, int)::_Save_errno::_Save_errno()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/ext/string_conversions.h:63: undefined reference to `__imp__errno'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/ext/string_conversions.h:63: undefined reference to `__imp__errno'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `__gnu_cxx::__stoa<unsigned long, unsigned long, char, int>(unsigned long ()(char const, char**, int), char const*, char const*, unsigned long long*, int)::_Save_errno::~_Save_errno()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/ext/string_conversions.h:64: undefined reference to `__imp__errno'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/ext/string_conversions.h:64: undefined reference to `__imp__errno'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(util.cpp.obj): in function `unsigned long __gnu_cxx::__stoa<unsigned long, unsigned long, char, int>(unsigned long ()(char const, char**, int), char const*, char const*, unsigned long long*, int)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/ext/string_conversions.h:84: undefined reference to `__imp__errno'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(response.cpp.obj): in function `cpr::Response::Response(std::shared_ptrcpr::CurlHolder, std::__cxx11::basic_string<char, std::char_traits, std::allocator >&&, std::__cxx11::basic_string<char, std::char_traits, std::allocator >&&, cpr::Cookies&&, cpr::Error&&)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/response.cpp:7: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/response.cpp:8: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(response.cpp.obj): in function `cpr::Response::GetCertInfos()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/response.cpp:28: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/response.cpp:29: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(response.cpp.obj): in function `std::__new_allocatorcpr::CertInfo::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(accept_encoding.cpp.obj): in function `std::__cxx11::basic_string<char, std::char_traits, std::allocator > std::operator+<char, std::char_traits, std::allocator >(std::__cxx11::basic_string<char, std::char_traits, std::allocator >&&, std::__cxx11::basic_string<char, std::char_traits, std::allocator >&&)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/basic_string.h:3531: undefined reference to `std::__cxx11::basic_string<char, std::char_traits, std::allocator >::insert(unsigned long long, std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(async.cpp.obj): in function `cpr::GlobalThreadPool::GetInstance()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/async.cpp:6: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(cookies.cpp.obj): in function `gmtime_s':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/time.h:264: undefined reference to `__imp__gmtime64_s'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(cookies.cpp.obj): in function `std::__new_allocatorcpr::Cookie::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(curl_container.cpp.obj): in function `std::__new_allocatorcpr::Pair::allocate(unsigned long long, void const*)':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/mingw64/include/c++/12.2.0/bits/new_allocator.h:137: undefined reference to `operator new(unsigned long long)'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(curlholder.cpp.obj): in function `cpr::CurlHolder::CurlHolder()':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/curlholder.cpp:18: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(curlholder.cpp.obj): in function `cpr::CurlHolder::urlEncode(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&) const':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/curlholder.cpp:28: undefined reference to `__imp__assert'
[build] /usr/lib/gcc/x86_64-pc-msys/11.3.0/../../../../x86_64-pc-msys/bin/ld: C:/msys64/vcpkg/installed/x64-mingw-dynamic/debug/lib/libcpr.a(curlholder.cpp.obj): in function `cpr::CurlHolder::urlDecode(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&) const':
[build] C:\msys64\vcpkg\buildtrees\cpr\x64-mingw-dynamic-dbg/C:/msys64/vcpkg/buildtrees/cpr/src/0ce00c60cd-ac486fb55d.clean/cpr/curlholder.cpp:39: undefined reference to `__imp__assert'
[build] collect2: error: ld returned 1 exit status
[build] make[3]: *** [CMakeFiles/Scrapy.dir/build.make:103: Scrapy.exe] Error 1
[build] make[2]: *** [CMakeFiles/Makefile2:83: CMakeFiles/Scrapy.dir/all] Error 2
[build] make[1]: *** [CMakeFiles/Makefile2:90: CMakeFiles/Scrapy.dir/rule] Error 2
[build] make: *** [Makefile:154: Scrapy] Error 2
[proc] The command: "C:\Program Files\CMake\bin\cmake.EXE" --build c:/Users/mehdi/OneDrive/Documents/1.0/C++/Scrap/build --config Debug --target Scrapy -j 10 -- exited with code: 2 and signal: null
[build] Build finished with exit code 2

OS : windows 8 64x
compiler : mingw
IDE : vscodium

I've tried to use it the same way on ubuntu and it works fine


来源: stackexchange

问:
Why Kafka message delivery from Producer to Consumer is so slow?
We have multiple microservices written in GoLang exchanging messages over the Kafka message bus. A microservice writes on a Kafka topic with a partition count of 3 with a replica factor of 2. We use AWS MSK for kafka brooker. We are using the Shopify Kafka client to connect with brokers.

Here is my Producer code -

```<code>package kf

import (
    "fmt"
    "github.com/Shopify/sarama"
    "github.com/segmentio/kafka-go"
    "net"
    "strconv"
)

type Producer struct {
    flowEventProducer sarama.SyncProducer
    topic             string
}

func InitProducer(brokers []string, topic string) *Producer {
    CreateKafkaTopic(brokers[0], topic)
    p := &Producer{}
    prod, err := newFlowWriter(brokers)
    if err != nil {
        panic("failed to connect to producer")
    }
    p.flowEventProducer = prod
    p.topic = topic
    return p
}

func CreateKafkaTopic(kafkaURL, topic string) {
    conn, err := kafka.Dial("tcp", kafkaURL)
    if err != nil {
        panic(err.Error())
    }
    controller, err := conn.Controller()
    if err != nil {
        panic(err.Error())
    }

    var controllerConn *kafka.Conn
    controllerConn, err = kafka.Dial("tcp", net.JoinHostPort(controller.Host, strconv.Itoa(controller.Port)))
    if err != nil {
        panic(err.Error())
    }

    defer controllerConn.Close()
    topicConfigs := []kafka.TopicConfig{
        {
            Topic:             topic,
            NumPartitions:     3,
            ReplicationFactor: 2,
        },
    }
    err = controllerConn.CreateTopics(topicConfigs...)
    if err != nil {
        panic(err.Error())
    }
    defer conn.Close()
}

func newFlowWriter(brokers []string) (sarama.SyncProducer, error) {
    config := sarama.NewConfig()
    version := "2.6.2"
    kafkaVer, err := sarama.ParseKafkaVersion(version)
    if err != nil {
        panic("failed to parse kafka version, producer will not run")
    }
    config.Producer.Partitioner = sarama.NewHashPartitioner
    config.Net.MaxOpenRequests = 10
    config.Producer.RequiredAcks = sarama.WaitForLocal
    config.Producer.Return.Successes = true
    config.Version = kafkaVer
    producer, err := sarama.NewSyncProducer(brokers, config)

    return producer, err
}

func (p *Producer) WriteMessage(uuid string, data []byte) error {
    msg := &sarama.ProducerMessage{
        Topic: p.topic,
        Key:   sarama.ByteEncoder(uuid),
        Value: sarama.ByteEncoder(data),
    }

    part, off, err := p.flowEventProducer.SendMessage(msg)
    if err != nil {
        return err
    } else {
        fmt.Printf("message wriiten on part:%d and offset: %d", part, off)
    }
    return nil
}

</code>```

Here is my consumer -

```<code>package kf

import (
    "context"
    "encoding/json"
    "fmt"
    "github.com/Shopify/sarama"
)

type Consumer struct {
    flowEventReader sarama.ConsumerGroup
    topic           string
    brokerUrls      []string
}

type data struct {
    Name     string `json:"name"`
    Employee string `json:"employee"`
}

func InitConsumer(brokers []string, topic string) *Consumer {
    c := &Consumer{}
    c.topic = topic
    c.brokerUrls = brokers
    var (
        err error
    )
    conf := createSaramaKafkaConf()
    c.flowEventReader, err = sarama.NewConsumerGroup(c.brokerUrls, "myconf", conf)
    if err != nil {
        panic("failed to create consumer group on kafka cluster")
    }

    return c
}

type KafkaConsumerGroupHandler struct {
    Cons *Consumer
}

func (c *Consumer) HandleMessages() {
    // Consume from kafka and process
    for {
        var err = c.flowEventReader.Consume(context.Background(), []string{c.topic}, &KafkaConsumerGroupHandler{Cons: c})
        if err != nil {
            fmt.Println("FAILED")
            continue
        }
    }

}
func (*KafkaConsumerGroupHandler) Setup(_ sarama.ConsumerGroupSession) error   { return nil }
func (*KafkaConsumerGroupHandler) Cleanup(_ sarama.ConsumerGroupSession) error { return nil }
func (l *KafkaConsumerGroupHandler) ConsumeClaim(sess sarama.ConsumerGroupSession, claim sarama.ConsumerGroupClaim) error {
    for msg := range claim.Messages() {
        l.Cons.logMessage(msg)
        sess.MarkMessage(msg, "")
    }
    return nil
}

func (c *Consumer) logMessage(msg *sarama.ConsumerMessage) {
    d := &data{}
    err := json.Unmarshal(msg.Value, d)
    if err != nil {
        fmt.Println(err)
    }
    fmt.Printf("messages: key: %s and val:%+v", string(msg.Key), d)
}

func createSaramaKafkaConf() *sarama.Config {
    conf := sarama.NewConfig()
    version := "2.6.2"
    kafkaVer, err := sarama.ParseKafkaVersion(version)
    if err != nil {
        panic("failed to parse kafka version, executor will not run")
    }
    conf.Version = kafkaVer
    conf.Consumer.Offsets.Initial = sarama.OffsetOldest
    conf.Consumer.Group.Rebalance.GroupStrategies = []sarama.BalanceStrategy{sarama.BalanceStrategyRoundRobin}

    return conf
}

</code>```

If we put load in microservices and producer starts producing messages of order of 500 events with each having size of ~1kb. we are encountering a delay of 30 seconds in message delivery. We want instant message delivery post-production. I think Kafka is very much capable of for my use-case. Please, help me in figuring  out the issue for this delay.

ContentLicense: CC BY-SA 4.0

Body:
We have multiple microservices written in GoLang exchanging messages over the Kafka message bus. A microservice writes on a Kafka topic with a partition count of 3 with a replica factor of 2. We use AWS MSK for kafka brooker. We are using the Shopify Kafka client to connect with brokers.

Here is my Producer code -

package kf

import (
    "fmt"
    "github.com/Shopify/sarama"
    "github.com/segmentio/kafka-go"
    "net"
    "strconv"
)

type Producer struct {
    flowEventProducer sarama.SyncProducer
    topic             string
}

func InitProducer(brokers []string, topic string) *Producer {
    CreateKafkaTopic(brokers[0], topic)
    p := &Producer{}
    prod, err := newFlowWriter(brokers)
    if err != nil {
        panic("failed to connect to producer")
    }
    p.flowEventProducer = prod
    p.topic = topic
    return p
}

func CreateKafkaTopic(kafkaURL, topic string) {
    conn, err := kafka.Dial("tcp", kafkaURL)
    if err != nil {
        panic(err.Error())
    }
    controller, err := conn.Controller()
    if err != nil {
        panic(err.Error())
    }

    var controllerConn *kafka.Conn
    controllerConn, err = kafka.Dial("tcp", net.JoinHostPort(controller.Host, strconv.Itoa(controller.Port)))
    if err != nil {
        panic(err.Error())
    }

    defer controllerConn.Close()
    topicConfigs := []kafka.TopicConfig{
        {
            Topic:             topic,
            NumPartitions:     3,
            ReplicationFactor: 2,
        },
    }
    err = controllerConn.CreateTopics(topicConfigs...)
    if err != nil {
        panic(err.Error())
    }
    defer conn.Close()
}

func newFlowWriter(brokers []string) (sarama.SyncProducer, error) {
    config := sarama.NewConfig()
    version := "2.6.2"
    kafkaVer, err := sarama.ParseKafkaVersion(version)
    if err != nil {
        panic("failed to parse kafka version, producer will not run")
    }
    config.Producer.Partitioner = sarama.NewHashPartitioner
    config.Net.MaxOpenRequests = 10
    config.Producer.RequiredAcks = sarama.WaitForLocal
    config.Producer.Return.Successes = true
    config.Version = kafkaVer
    producer, err := sarama.NewSyncProducer(brokers, config)

    return producer, err
}

func (p *Producer) WriteMessage(uuid string, data []byte) error {
    msg := &sarama.ProducerMessage{
        Topic: p.topic,
        Key:   sarama.ByteEncoder(uuid),
        Value: sarama.ByteEncoder(data),
    }

    part, off, err := p.flowEventProducer.SendMessage(msg)
    if err != nil {
        return err
    } else {
        fmt.Printf("message wriiten on part:%d and offset: %d", part, off)
    }
    return nil
}

Here is my consumer -

package kf

import (
    "context"
    "encoding/json"
    "fmt"
    "github.com/Shopify/sarama"
)

type Consumer struct {
    flowEventReader sarama.ConsumerGroup
    topic           string
    brokerUrls      []string
}

type data struct {
    Name     string `json:"name"`
    Employee string `json:"employee"`
}

func InitConsumer(brokers []string, topic string) *Consumer {
    c := &Consumer{}
    c.topic = topic
    c.brokerUrls = brokers
    var (
        err error
    )
    conf := createSaramaKafkaConf()
    c.flowEventReader, err = sarama.NewConsumerGroup(c.brokerUrls, "myconf", conf)
    if err != nil {
        panic("failed to create consumer group on kafka cluster")
    }

    return c
}

type KafkaConsumerGroupHandler struct {
    Cons *Consumer
}

func (c *Consumer) HandleMessages() {
    // Consume from kafka and process
    for {
        var err = c.flowEventReader.Consume(context.Background(), []string{c.topic}, &KafkaConsumerGroupHandler{Cons: c})
        if err != nil {
            fmt.Println("FAILED")
            continue
        }
    }

}
func (*KafkaConsumerGroupHandler) Setup(_ sarama.ConsumerGroupSession) error   { return nil }
func (*KafkaConsumerGroupHandler) Cleanup(_ sarama.ConsumerGroupSession) error { return nil }
func (l *KafkaConsumerGroupHandler) ConsumeClaim(sess sarama.ConsumerGroupSession, claim sarama.ConsumerGroupClaim) error {
    for msg := range claim.Messages() {
        l.Cons.logMessage(msg)
        sess.MarkMessage(msg, "")
    }
    return nil
}

func (c *Consumer) logMessage(msg *sarama.ConsumerMessage) {
    d := &data{}
    err := json.Unmarshal(msg.Value, d)
    if err != nil {
        fmt.Println(err)
    }
    fmt.Printf("messages: key: %s and val:%+v", string(msg.Key), d)
}

func createSaramaKafkaConf() *sarama.Config {
    conf := sarama.NewConfig()
    version := "2.6.2"
    kafkaVer, err := sarama.ParseKafkaVersion(version)
    if err != nil {
        panic("failed to parse kafka version, executor will not run")
    }
    conf.Version = kafkaVer
    conf.Consumer.Offsets.Initial = sarama.OffsetOldest
    conf.Consumer.Group.Rebalance.GroupStrategies = []sarama.BalanceStrategy{sarama.BalanceStrategyRoundRobin}

    return conf
}

If we put load in microservices and producer starts producing messages of order of 500 events with each having size of ~1kb. we are encountering a delay of 30 seconds in message delivery. We want instant message delivery post-production. I think Kafka is very much capable of for my use-case. Please, help me in figuring  out the issue for this delay.


问:
How to remove maven from a project?
I have both build automation tools (maven, gradle) in my project. Of course, I can switch between them, but I would like to completely remove maven from the project and use only gradle.

How can I remove maven from the project? Do I only need to remove maven related files?

Title: How to remove maven from a project?


问:
Measure the Size of Object in Photo
I would like to know if its possible to measure the size of an object in a photo with javascript or python, maybe by just clicking on it? If its possible,could you please send me on a code snippet to guide me. This is to function on a website.

Thank you

Title: Measure the Size of Object in Photo


问:
(Databricks) last_value function usage on huge dataset
For table which contains bilions of rows (10 mln each day) we trying to "fix/clean" source data. For missing rows with measures x,y,z we copy them from the past. To do it right we are using last_value function on specified aggregation level combined by CROSS JOIN with simple table which contains missing days.

It worked in simple POC where we have less than 1mln rows. In production dataset described above time and performance are pretty bad. We cannot just simply extend cluster, we need to try different approach.

Any thoughts what we can use insted of sql (simple last_value)?
All is caluclated in Azure Databricks environment.


问:
How to use ggez + imgui + wgpu?
In my game I need to render some in-game textures into UI (I'm using ggez 0.8.1 and imgui 0.8.0). As ggez 0.8.1 uses wgpu for rendering I need to use wgpu backend for imgui. So there's my question: how can I render imgui's DrawData inside ggez's draw function?

I've tried this code but it's not showing me UI (the other game things are working).

```<code>        let mut canvas = graphics::Canvas::from_frame(ctx, graphics::Color::BLACK);

        let ui = self.imgui.frame();

        imgui::Window::new("")
                .size([200.0, 100.0], imgui::Condition::Always)
                .position([0.0, 0.0], imgui::Condition::Always)
                .flags(imgui::WindowFlags::NO_RESIZE | imgui::WindowFlags::NO_COLLAPSE)
                .build(&ui, || {
                    ui.text(format!("tick id: {}", self.tick_id));
                });

        let draw_data = ui.render();

        unsafe {
            let encoder = ctx.gfx.commands().unwrap() as *mut CommandEncoder;

            let mut pass = (&mut *encoder).begin_render_pass(&wgpu::RenderPassDescriptor {
                label: Some("UI RenderPass"),
                color_attachments: &[Some(wgpu::RenderPassColorAttachment {
                    view: &ctx.gfx.frame().wgpu().1,
                    resolve_target: None,
                    ops: wgpu::Operations {
                        load: wgpu::LoadOp::Clear(wgpu::Color::GREEN),
                        store: true,
                    },
                })],
                depth_stencil_attachment: None,
            });

            let wgpu_ctx = ctx.gfx.wgpu();
            self.renderer
                .render(&draw_data, &wgpu_ctx.queue, &wgpu_ctx.device, &mut pass)
                .unwrap();
        };

        canvas.finish(ctx)?;
</code>```

Title: How to use ggez + imgui + wgpu?

Body:
In my game I need to render some in-game textures into UI (I'm using ggez 0.8.1 and imgui 0.8.0). As ggez 0.8.1 uses wgpu for rendering I need to use wgpu backend for imgui. So there's my question: how can I render imgui's DrawData inside ggez's draw function?

I've tried this code but it's not showing me UI (the other game things are working).

        let mut canvas = graphics::Canvas::from_frame(ctx, graphics::Color::BLACK);

        let ui = self.imgui.frame();

        imgui::Window::new("")
                .size([200.0, 100.0], imgui::Condition::Always)
                .position([0.0, 0.0], imgui::Condition::Always)
                .flags(imgui::WindowFlags::NO_RESIZE | imgui::WindowFlags::NO_COLLAPSE)
                .build(&ui, || {
                    ui.text(format!("tick id: {}", self.tick_id));
                });

        let draw_data = ui.render();

        unsafe {
            let encoder = ctx.gfx.commands().unwrap() as *mut CommandEncoder;

            let mut pass = (&mut *encoder).begin_render_pass(&wgpu::RenderPassDescriptor {
                label: Some("UI RenderPass"),
                color_attachments: &[Some(wgpu::RenderPassColorAttachment {
                    view: &ctx.gfx.frame().wgpu().1,
                    resolve_target: None,
                    ops: wgpu::Operations {
                        load: wgpu::LoadOp::Clear(wgpu::Color::GREEN),
                        store: true,
                    },
                })],
                depth_stencil_attachment: None,
            });

            let wgpu_ctx = ctx.gfx.wgpu();
            self.renderer
                .render(&draw_data, &wgpu_ctx.queue, &wgpu_ctx.device, &mut pass)
                .unwrap();
        };

        canvas.finish(ctx)?;


问:
hostname is different in vercel logs than what i have in env
I'm using mysql2 to fetch some data from a MySQL database. On localhost, it's working without any errors, but on production, I'm not getting any data, instead I'm getting 504 error and in Vercel realtime logs, I'm getting Access denied for user 'myusername'@'ec2-3-236-108-51.compute-1.amazonaws.com'. That hostname is totally different than what I have in my .env file.

In .env file I have NEXT_PUBLIC_DB_HOSTNAME=host.example.com, then i'm using like this:

```<code>const dbConnection = await mysql.createConnection({
    user: myusername,
    host: process.env.NEXT_PUBLIC_DB_HOSTNAME,
    rest of code ...
</code>```

If I'm doing something like this, just to console.log() the hostname, the output is correct on localhost & production, but on vercel logs, i'm geting that hostname totally different than what I have.

```<code>const hostname = process.env.NEXT_PUBLIC_DB_HOSTNAME;
console.log(`The hostname for the database is: ${hostname}`);

// OUTPUT is host.example.com on localhost and production
</code>```

Is this something related to security? On Vercel App Settings, don't have any environment variables added.

Body:
I'm using mysql2 to fetch some data from a MySQL database. On localhost, it's working without any errors, but on production, I'm not getting any data, instead I'm getting 504 error and in Vercel realtime logs, I'm getting Access denied for user 'myusername'@'ec2-3-236-108-51.compute-1.amazonaws.com'. That hostname is totally different than what I have in my .env file.

In .env file I have NEXT_PUBLIC_DB_HOSTNAME=host.example.com, then i'm using like this:

const dbConnection = await mysql.createConnection({
    user: myusername,
    host: process.env.NEXT_PUBLIC_DB_HOSTNAME,
    rest of code ...

If I'm doing something like this, just to console.log() the hostname, the output is correct on localhost & production, but on vercel logs, i'm geting that hostname totally different than what I have.

const hostname = process.env.NEXT_PUBLIC_DB_HOSTNAME;
console.log(`The hostname for the database is: ${hostname}`);

// OUTPUT is host.example.com on localhost and production

Is this something related to security? On Vercel App Settings, don't have any environment variables added.


问:
JsonUnsupportedObjectError (Converting object to an encodable object failed Error in flutter
I am facing problem while trying to encode Json data to a List of String

CartRepo.dart

```<code>```
```
`````` <code>
import 'dart:convert';
import 'package:ecommerceapp/models/cart_model.dart';
import 'package:ecommerceapp/utils/app_constants.dart';
import 'package:shared_preferences/shared_preferences.dart';

class CartRepo {
  final SharedPreferences sharedPreferences;
  CartRepo({required this.sharedPreferences});

  List<String> cart = [];

  void addToCartList(List<CartModel> cartList) async {
    cart = [];
    cartList.forEach((element) {
      return cart.add(jsonEncode(element.toJson()));
    });
    sharedPreferences.setStringList(AppConstants.CART_LIST, cart);
    getCartList();
  }

  List<CartModel> getCartList() {
    List<String> carts = [];

    if (sharedPreferences.containsKey(AppConstants.CART_LIST)) {
      carts = sharedPreferences.getStringList(AppConstants.CART_LIST)!;
    }

    List<CartModel> cartList = [];

    carts.forEach(
        (element) => cartList.add(CartModel.fromJson(jsonDecode(element))));

    return cartList;
  }
}
</code>```

CartModel.dart

```<code>import 'package:ecommerceapp/models/popular_products.dart';

class CartModel {
  int? id;
  String? name;
  int? price;
  String? img;
  int? quantity;
  bool? isExist;
  String? time;
  ProductModel? product;

  CartModel({
    this.id,
    this.name,
    this.price,
    this.img,
    this.quantity,
    this.isExist,
    this.time,
    this.product,
  });

  CartModel.fromJson(Map<String, dynamic> json) {
    this.id = json['id'];
    this.name = json['name'];
    this.price = json['price'];
    this.img = json['img'];
    this.quantity = json['quantity'];
    this.isExist = json['isExist '];
    this.time = json['time'];
    this.product = ProductModel.fromJson(json['product']);
  }

  Map<String, dynamic> toJson() {
    return {
      "id": this.id,
      "name": this.name,
      "price": this.price,
      "img": this.img,
      "quantity": this.quantity,
      "isExist": this.isExist,
      "time": this.time,
      "product": this.product!.toJson,
    };
  }
}
```
```
<p>PopularProducts.dart</p>
`````` <code>
class Product {
  int? _totalSize;
  int? _typeId;
  int? _offset;
  List<ProductModel> _products = [];
  List<ProductModel> get products => _products;

  Product(
      {required totalSize,
      required typeId,
      required offset,
      required products}) {
    this._totalSize = totalSize;
    this._typeId = typeId;
    this._offset = offset;
    this._products = products;
  }

  Product.fromJson(Map<String, dynamic> json) {
    _totalSize = json['total_size'];
    _typeId = json['type_id'];
    _offset = json['offset'];
    if (json['products'] != null) {
      _products = <ProductModel>[];
      json['products'].forEach((v) {
        _products.add(ProductModel.fromJson(v));
      });
    }
  }
}

class ProductModel {
  int? id;
  String? name;
  String? description;
  int? price;
  int? stars;
  String? img;
  String? location;
  String? createdAt;
  String? updatedAt;
  int? typeId;

  ProductModel(
      {this.id,
      this.name,
      this.description,
      this.price,
      this.stars,
      this.img,
      this.location,
      this.createdAt,
      this.updatedAt,
      this.typeId});

  ProductModel.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    name = json['name'];
    description = json['description'];
    price = json['price'];
    stars = json['stars'];
    img = json['img'];
    location = json['location'];
    createdAt = json['created_at'];
    updatedAt = json['updated_at'];
    typeId = json['type_id'];
  }

  Map<String, dynamic> toJson() {
    return {
      "id": id,
      "name": name,
      "price": price,
      "img": img,
      "location": location,
      "createdAt": createdAt,
      "updatedAt": updatedAt,
      "typeId": typeId,
    };
  }
}
```
```

Error :

Unhandled Exception:Converting object to an encodable object

Body:
I am facing problem while trying to encode Json data to a List of String

CartRepo.dart

import 'dart:convert';
import 'package:ecommerceapp/models/cart_model.dart';
import 'package:ecommerceapp/utils/app_constants.dart';
import 'package:shared_preferences/shared_preferences.dart';

class CartRepo {
  final SharedPreferences sharedPreferences;
  CartRepo({required this.sharedPreferences});

  List<String> cart = [];

  void addToCartList(List<CartModel> cartList) async {
    cart = [];
    cartList.forEach((element) {
      return cart.add(jsonEncode(element.toJson()));
    });
    sharedPreferences.setStringList(AppConstants.CART_LIST, cart);
    getCartList();
  }

  List<CartModel> getCartList() {
    List<String> carts = [];

    if (sharedPreferences.containsKey(AppConstants.CART_LIST)) {
      carts = sharedPreferences.getStringList(AppConstants.CART_LIST)!;
    }

    List<CartModel> cartList = [];

    carts.forEach(
        (element) => cartList.add(CartModel.fromJson(jsonDecode(element))));

    return cartList;
  }
}

CartModel.dart

import 'package:ecommerceapp/models/popular_products.dart';

class CartModel {
  int? id;
  String? name;
  int? price;
  String? img;
  int? quantity;
  bool? isExist;
  String? time;
  ProductModel? product;

  CartModel({
    this.id,
    this.name,
    this.price,
    this.img,
    this.quantity,
    this.isExist,
    this.time,
    this.product,
  });

  CartModel.fromJson(Map<String, dynamic> json) {
    this.id = json['id'];
    this.name = json['name'];
    this.price = json['price'];
    this.img = json['img'];
    this.quantity = json['quantity'];
    this.isExist = json['isExist '];
    this.time = json['time'];
    this.product = ProductModel.fromJson(json['product']);
  }

  Map<String, dynamic> toJson() {
    return {
      "id": this.id,
      "name": this.name,
      "price": this.price,
      "img": this.img,
      "quantity": this.quantity,
      "isExist": this.isExist,
      "time": this.time,
      "product": this.product!.toJson,
    };
  }
}

PopularProducts.dart

class Product {
  int? _totalSize;
  int? _typeId;
  int? _offset;
  List<ProductModel> _products = [];
  List<ProductModel> get products => _products;

  Product(
      {required totalSize,
      required typeId,
      required offset,
      required products}) {
    this._totalSize = totalSize;
    this._typeId = typeId;
    this._offset = offset;
    this._products = products;
  }

  Product.fromJson(Map<String, dynamic> json) {
    _totalSize = json['total_size'];
    _typeId = json['type_id'];
    _offset = json['offset'];
    if (json['products'] != null) {
      _products = <ProductModel>[];
      json['products'].forEach((v) {
        _products.add(ProductModel.fromJson(v));
      });
    }
  }
}

class ProductModel {
  int? id;
  String? name;
  String? description;
  int? price;
  int? stars;
  String? img;
  String? location;
  String? createdAt;
  String? updatedAt;
  int? typeId;

  ProductModel(
      {this.id,
      this.name,
      this.description,
      this.price,
      this.stars,
      this.img,
      this.location,
      this.createdAt,
      this.updatedAt,
      this.typeId});

  ProductModel.fromJson(Map<String, dynamic> json) {
    id = json['id'];
    name = json['name'];
    description = json['description'];
    price = json['price'];
    stars = json['stars'];
    img = json['img'];
    location = json['location'];
    createdAt = json['created_at'];
    updatedAt = json['updated_at'];
    typeId = json['type_id'];
  }

  Map<String, dynamic> toJson() {
    return {
      "id": id,
      "name": name,
      "price": price,
      "img": img,
      "location": location,
      "createdAt": createdAt,
      "updatedAt": updatedAt,
      "typeId": typeId,
    };
  }
}

Error :

Unhandled Exception:Converting object to an encodable object


问:
What are legal Observation Spaces for Python openai/gym?
I want to train a network with deep reinforcement learning to play the Snake Game.
I wrote the snake game and the Agent Environment.

But i keep getting this Error:

```<code>self.observation_space = spaces.Tuple(spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Disces.Discrete(2),spaces.Dcrete(2))
TypeError: __init__() takes from 2 to 3 positional arguments but 8 were given
</code>```

I am now really interested in what are legal observation states syntaxes because i want to do more stuff like this with different observation spaces :)

Notice: The reset function only resets game_relevant values and not the observation or action space.

Thanks for your answers!

enter image description here

I tried:

```<code>
self.observation_space = spaces.Tuple(spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2))

</code>```

Like you can see in the image i expected the following observation state:

7 Values either 0 or 1

Body:
I want to train a network with deep reinforcement learning to play the Snake Game.
I wrote the snake game and the Agent Environment.

But i keep getting this Error:

self.observation_space = spaces.Tuple(spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Disces.Discrete(2),spaces.Dcrete(2))
TypeError: __init__() takes from 2 to 3 positional arguments but 8 were given

I am now really interested in what are legal observation states syntaxes because i want to do more stuff like this with different observation spaces :)

Notice: The reset function only resets game_relevant values and not the observation or action space.

Thanks for your answers!

enter image description here

I tried:

self.observation_space = spaces.Tuple(spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2),spaces.Discrete(2))

Like you can see in the image i expected the following observation state:

7 Values either 0 or 1


问:
How to read a list of large csv files in optimized way in python?
I have list of csv files which are 200+mbs right now but in future it will grow and when I read them using csv module my system gets hanged so I am looking for optimizing the approach I have right now in order to read the csv files in chunks so it won't load all in the memory at once.

Here is the code:

```<code>import asyncio
import aiohttp
import csv
import ast
import logging
from glob import glob

logging.basicConfig(
    filename="post_script.log", format="%(asctime)s %(message)s", filemode="w"
)

logger = logging.getLogger()
logger.setLevel(logging.DEBUG)

csv.field_size_limit(100000000)

headers = {"Accept": "*/*", "Content-Type": "application/json"}

async def post_func(session, file, store_id):
    data = {}
    with open(file, "r") as f_in:
        reader = csv.DictReader(f_in)
        for row in reader:
            data.setdefault((row["LabebStoreId"], row["catalog_uuid"]), []).append(row)
    for payload_no, v in enumerate(data.values(), 1):
        if len(v) == 1:
            payload = {
                "row": {
                    "LabebStoreId": v[0]["LabebStoreId"],
                    "catalog_uuid": v[0]["catalog_uuid"],
                    "lang": v[0]["lang"],
                    "cat_0_name": v[0]["cat_0_name"],
                    "cat_1_name": v[0]["cat_1_name"],
                    "cat_2_name": v[0]["cat_2_name"],
                    "cat_3_name": v[0]["cat_3_name"],
                    "catalogname": v[0]["catalogname"],
                    "description": v[0]["description"],
                    "properties": v[0]["properties"],
                    "price": v[0]["price"],
                    "price_before_discount": v[0]["price_before_discount"],
                    "externallink": v[0]["externallink"],
                    "Rating": v[0]["Rating"],
                    "delivery": v[0]["delivery"],
                    "discount": v[0]["discount"],
                    "instock": v[0]["instock"],
                    "images": ast.literal_eval(v[0]["encoded_images"]),
                }
            }

            response = await session.post(
                f"http://crawlerapi.labeb.com/api/PCCrawler/Crawl?StoreId={store_id}",
                json=payload,
            )
            logger.debug(f"Posting to {response.url}")
            logger.debug(f"""row: {payload["row"]["externallink"]}""")
            logger.info(await response.text())

        else:
            payload = {
                "row": {
                    "LabebStoreId": v[0]["LabebStoreId"],
                    "catalog_uuid": v[0]["catalog_uuid"],
                    "lang": v[0]["lang"],
                    "cat_0_name": v[0]["cat_0_name"],
                    "cat_1_name": v[0]["cat_1_name"],
                    "cat_2_name": v[0]["cat_2_name"],
                    "cat_3_name": v[0]["cat_3_name"],
                    "catalogname": v[0]["catalogname"],
                    "description": v[0]["description"],
                    "properties": v[0]["properties"],
                    "price": v[0]["price"],
                    "price_before_discount": v[0]["price_before_discount"],
                    "externallink": v[0]["externallink"],
                    "Rating": v[0]["Rating"],
                    "delivery": v[0]["delivery"],
                    "discount": v[0]["discount"],
                    "instock": v[0]["instock"],
                    "images": ast.literal_eval(v[0]["encoded_images"]),
                },
                "nextRow": {
                    "LabebStoreId": v[1]["LabebStoreId"],
                    "catalog_uuid": v[1]["catalog_uuid"],
                    "lang": v[1]["lang"],
                    "cat_0_name": v[1]["cat_0_name"],
                    "cat_1_name": v[1]["cat_1_name"],
                    "cat_2_name": v[1]["cat_2_name"],
                    "cat_3_name": v[1]["cat_3_name"],
                    "catalogname": v[1]["catalogname"],
                    "description": v[1]["description"],
                    "properties": v[1]["properties"],
                    "price": v[1]["price"],
                    "price_before_discount": v[1]["price_before_discount"],
                    "externallink": v[1]["externallink"],
                    "Rating": v[1]["Rating"],
                    "delivery": v[1]["delivery"],
                    "discount": v[1]["discount"],
                    "instock": v[1]["instock"],
                    "images": ast.literal_eval(v[1]["encoded_images"]),
                },
            }

            response = await session.post(
                f"http://crawlerapi.labeb.com/api/PCCrawler/Crawl?StoreId={store_id}",
                json=payload,
            )
            logger.debug(f"Posting to {response.url}")
            logger.debug(f"""row: {payload["row"]["externallink"]}""")
            logger.debug(f"""nextRow: {payload["row"]["externallink"]}""")
            logger.info(await response.text())

        logger.info("-" * 80)

async def main():
    try:
        async with aiohttp.ClientSession(headers=headers) as session:
            logging.info(f"---starting new---")
            post_tasks = []
            files = glob("*.csv")
            for file in files:
                store_id = file.split("_")[0]
                post_tasks.append(
                    asyncio.create_task(post_func(session, file, store_id))
                )
            await asyncio.gather(*post_tasks)
            logging.info(f"---finished---")
    except Exception as e:
        logger.error(e)

if __name__ == "__main__":
    loop = asyncio.get_event_loop()
    loop.run_until_complete(main())
</code>```

Let me explain what the code is about and what it is doing. Basically it is reading the csv file getting all the rows and posting it to the api through HTTP POST request. Can anyone please guide me on how to read all the csv files efficiently? Thank you!

Body:
I have list of csv files which are 200+mbs right now but in future it will grow and when I read them using csv module my system gets hanged so I am looking for optimizing the approach I have right now in order to read the csv files in chunks so it won't load all in the memory at once.

Here is the code:

import asyncio
import aiohttp
import csv
import ast
import logging
from glob import glob

logging.basicConfig(
    filename="post_script.log", format="%(asctime)s %(message)s", filemode="w"
)

logger = logging.getLogger()
logger.setLevel(logging.DEBUG)

csv.field_size_limit(100000000)

headers = {"Accept": "*/*", "Content-Type": "application/json"}

async def post_func(session, file, store_id):
    data = {}
    with open(file, "r") as f_in:
        reader = csv.DictReader(f_in)
        for row in reader:
            data.setdefault((row["LabebStoreId"], row["catalog_uuid"]), []).append(row)
    for payload_no, v in enumerate(data.values(), 1):
        if len(v) == 1:
            payload = {
                "row": {
                    "LabebStoreId": v[0]["LabebStoreId"],
                    "catalog_uuid": v[0]["catalog_uuid"],
                    "lang": v[0]["lang"],
                    "cat_0_name": v[0]["cat_0_name"],
                    "cat_1_name": v[0]["cat_1_name"],
                    "cat_2_name": v[0]["cat_2_name"],
                    "cat_3_name": v[0]["cat_3_name"],
                    "catalogname": v[0]["catalogname"],
                    "description": v[0]["description"],
                    "properties": v[0]["properties"],
                    "price": v[0]["price"],
                    "price_before_discount": v[0]["price_before_discount"],
                    "externallink": v[0]["externallink"],
                    "Rating": v[0]["Rating"],
                    "delivery": v[0]["delivery"],
                    "discount": v[0]["discount"],
                    "instock": v[0]["instock"],
                    "images": ast.literal_eval(v[0]["encoded_images"]),
                }
            }

            response = await session.post(
                f"http://crawlerapi.labeb.com/api/PCCrawler/Crawl?StoreId={store_id}",
                json=payload,
            )
            logger.debug(f"Posting to {response.url}")
            logger.debug(f"""row: {payload["row"]["externallink"]}""")
            logger.info(await response.text())

        else:
            payload = {
                "row": {
                    "LabebStoreId": v[0]["LabebStoreId"],
                    "catalog_uuid": v[0]["catalog_uuid"],
                    "lang": v[0]["lang"],
                    "cat_0_name": v[0]["cat_0_name"],
                    "cat_1_name": v[0]["cat_1_name"],
                    "cat_2_name": v[0]["cat_2_name"],
                    "cat_3_name": v[0]["cat_3_name"],
                    "catalogname": v[0]["catalogname"],
                    "description": v[0]["description"],
                    "properties": v[0]["properties"],
                    "price": v[0]["price"],
                    "price_before_discount": v[0]["price_before_discount"],
                    "externallink": v[0]["externallink"],
                    "Rating": v[0]["Rating"],
                    "delivery": v[0]["delivery"],
                    "discount": v[0]["discount"],
                    "instock": v[0]["instock"],
                    "images": ast.literal_eval(v[0]["encoded_images"]),
                },
                "nextRow": {
                    "LabebStoreId": v[1]["LabebStoreId"],
                    "catalog_uuid": v[1]["catalog_uuid"],
                    "lang": v[1]["lang"],
                    "cat_0_name": v[1]["cat_0_name"],
                    "cat_1_name": v[1]["cat_1_name"],
                    "cat_2_name": v[1]["cat_2_name"],
                    "cat_3_name": v[1]["cat_3_name"],
                    "catalogname": v[1]["catalogname"],
                    "description": v[1]["description"],
                    "properties": v[1]["properties"],
                    "price": v[1]["price"],
                    "price_before_discount": v[1]["price_before_discount"],
                    "externallink": v[1]["externallink"],
                    "Rating": v[1]["Rating"],
                    "delivery": v[1]["delivery"],
                    "discount": v[1]["discount"],
                    "instock": v[1]["instock"],
                    "images": ast.literal_eval(v[1]["encoded_images"]),
                },
            }

            response = await session.post(
                f"http://crawlerapi.labeb.com/api/PCCrawler/Crawl?StoreId={store_id}",
                json=payload,
            )
            logger.debug(f"Posting to {response.url}")
            logger.debug(f"""row: {payload["row"]["externallink"]}""")
            logger.debug(f"""nextRow: {payload["row"]["externallink"]}""")
            logger.info(await response.text())

        logger.info("-" * 80)

async def main():
    try:
        async with aiohttp.ClientSession(headers=headers) as session:
            logging.info(f"---starting new---")
            post_tasks = []
            files = glob("*.csv")
            for file in files:
                store_id = file.split("_")[0]
                post_tasks.append(
                    asyncio.create_task(post_func(session, file, store_id))
                )
            await asyncio.gather(*post_tasks)
            logging.info(f"---finished---")
    except Exception as e:
        logger.error(e)

if __name__ == "__main__":
    loop = asyncio.get_event_loop()
    loop.run_until_complete(main())

Let me explain what the code is about and what it is doing. Basically it is reading the csv file getting all the rows and posting it to the api through HTTP POST request. Can anyone please guide me on how to read all the csv files efficiently? Thank you!