- HOW TO INSTALL CURL ON WINDOWS 8 WITH MICROSOFT C++ HOW TO
- HOW TO INSTALL CURL ON WINDOWS 8 WITH MICROSOFT C++ CODE
In the Windows visual studio, they have nuget, but again I've tried and it doesn't seem to work. Although C and C++ have cross platform CMAKE, it is still not very convenient to use. Java has Maven and Gradle, so Javascript with its NPM, Python PIP and PHP composer. So you still need to customize it if you are working in a different environment. In languages like Java, Javascript, Python or PHP, it is very easy to use package managers, I don't know why in C++ it’s like not always working, and the worst thing is it doesn't work for cross platform.
HOW TO INSTALL CURL ON WINDOWS 8 WITH MICROSOFT C++ CODE
Those are messy code but basically the code above will download a file or webpage from the internet and store it in our project directory. Now we can test by create a example code using library curl Ctrl + shift + p, find and execute, Cmake: delete cache and reconfigureĩ. "CMAKE_TOOLCHAIN_FILE": " your_vcpkg_path/scripts/buildsystems/vcpkg.cmake"Ĩ. Now open x86 Native Tools command prompt and then clone vspkg source code and install. We are going to build VCPKG from the source code, so make sure you have Visual studio build tools installed, if not you can read my previous aricle here.Ģ. This is how you are gonna use Vcpkg on visual studio code.ġ.
You can read more about VCPKG here the official repo or from Microsoft.
Now we can easily use any libraries, thanks to VCPKG: a C++ package manager for Windows, and probably it can work on Linux, and macOS too. In Linux based OS maybe it could be much more straightforward, because cURL is usually already included. If you are someone like me, a C/C++ beginner and want to use this very useful Curl library, on Windows, here’s how you can use Curl or any other library.
HOW TO INSTALL CURL ON WINDOWS 8 WITH MICROSOFT C++ HOW TO
Although sure it depends on how experienced the programmer is, for someone who has been doing C/C++ for a while, it’s not gonna be much of a problem.īut for beginner C and C++ like me, coming from higher level programming languages and tools, even small things like how to use a library for example the library that we are gonna use is cURL, are already big steps that it is already hard to handle quickly. But this simplicity is also one of the things that makes C doesn’t seem to fit for rapid development applications. The thing I like about coding in C and C++ is the low level stuff, and the simplicity.