Today I wanted to rework an example that I wrote years ago. I was a client-server example using the C++ REST SDK. I haven’t worked with the library for a while, so I needed to install the latest version first.
If you go to the C++ REST SDK project page it says you need to run the following command to install it:
vcpkg install cpprestsdk cpprestsdk:x64-windows
For that, you need the vckpg package management system for C and C++ libraries on Windows. Getting and installing it is not that hard: you have to either clone the git repo or download and unzip it locally. Then you need to run two commands:
bootstrap-vcpkg.bat vcpkg integrate install
So I did all that and then installed the C++ REST SDK. It took about one hour and 11GB (!!) of disk storage for this. It had to download, build and install the following libraries:
- boost:x86-windows
- boost:x64-windows
- bzip2:x86-windows
- bzip2:x64-windows
- cpprestsdk:x86-windows
- cpprestsdk:x64-windows
- openssl:x86-windows
- openssl:x64-windows
- websocketpp:x86-windows
- websocketpp:x64-windows
- zlib:x86-windows
- zlib:x64-windows
This is utterly insane. All that I want is some headers and a few static and dynamic libraries. But instead I got 11GB of God knows what and waited about one hour before I could start to work.
Why is all this necessary? Why do I have to care about all this provisioning process? We don’t care about your time and resources, we’re cool we can do this with scripts? Seriously? What happened to the good old fashion of downloading an archive with everything you needed already built for you? Now you first need to install 400MB of Perl to be able to build and get going with a C++ library. It’s sad.
Was the example cross platform? Platform specific solutions may be better.
You have never seen something really huge until you have gazed into the depths of node_modules
I just followed the instructions from the C++ REST SDK project for installing it and run vcpkg install cpprestsdk cpprestsdk:x64-windows.
Boost & other “crap” 😉 are only needed on Windows for WebSockets support. Get the sources, disable WebSockets (there’s a define for that) and compile it with VisualStudio.
IMHO this shows that installing whole packages isn’t the silver button everyone’s looking for…
For x64 Windows the starting point now is https://github.com/Microsoft/cppwinrt/blob/master/10.0.16299.0/Samples/Syndication/Main.cpp
Not sure what you’re trying to say. That the library is obsolete?
For different targets it’s difficult to tell, but for exclusive Windows client specific development the SDK is certainly legacy at best.
Try this https://bitbucket.org/sobjectizerteam/restinio-0.3
If you miss features, talk with author and he will add.