-
Notifications
You must be signed in to change notification settings - Fork 28
Building samples
Samples inside EasyHttp are built as a separate CMake project so that to mirror the actual library usage.
Before you can build the samples, first make sure you have EasyHttp installed.
Please note that if you haven't installed library inside the default folders searched by CMake, you might have to provide the installation dir path using CMAKE_PREFIX_PATH.
Assuming you have already have a local copy of easyhttpcpp project cloned.
cd easyhttpcpp/samples
mkdir _build
cd _build
cmake ../
make
This will build all the samples present inside the samples folder.
Once built, lets run a given sample, say SimpleHttpClient.
From the _build folder created above,
cd bin
./easyhttpcpp-samples-SimpleHttpClient https://github.com/sony/easyhttpcpp
This will download and print the contents of https://github.com/sony/easyhttpcpp as an html document.
Usage: ./easyhttpcpp-samples-SimpleHttpClient <any-url>
Feel free to open new issue if you want to ask any questions.