From 83722e6ceae9568426e74b31cfcabb89fe1cee6e Mon Sep 17 00:00:00 2001 From: Chunting Gu Date: Wed, 19 Aug 2020 10:19:40 +0800 Subject: [PATCH 1/2] Delete Integrate-Into-Your-Project.md --- doc/Integrate-Into-Your-Project.md | 29 ----------------------------- 1 file changed, 29 deletions(-) delete mode 100644 doc/Integrate-Into-Your-Project.md diff --git a/doc/Integrate-Into-Your-Project.md b/doc/Integrate-Into-Your-Project.md deleted file mode 100644 index e20a3d6..0000000 --- a/doc/Integrate-Into-Your-Project.md +++ /dev/null @@ -1,29 +0,0 @@ -# Integrate Into Your Project - -## Integrate with CMake - -If your project also uses CMake as the build tool, it's highly recommended to integrate *Webcc* with source code. Just copy the `webcc` sub-folder to the side of your project, add the configure options to your top `CMakeLists.txt`, then include it by the following statement: - -```cmake -add_subdirectory(webcc) -``` - -One of the difficulties is the dependency of third-party libraries, like `zlib` and `openssl`. It's not a big deal for Linux since they can be installed easily using the system package manager (`apt-get` for Ubuntu). - -For Windows, you should copy `third_pary\src\zlib`, which is the source code of zlib with the official `CMakeLists.txt`, to some place of your project. Download OpenSSL and install it. See [Build Instructions](Build-Instructions.md) for more details. - -## Integrate with Visual Studio - -If you don't want to use CMake, you can copy the `webcc` sub-folder directly into your project to integrate. -But the following changes will be necessary: -- Create a file `config.h` by copying `config.h.example`, change the macros. -- Now create a static library project named _webcc_ in _Visual Studio_ with all the C++ files. -- Add the include path of _Boost_ in _Visual Studio_ for this project. -- Add webcc project's parent directory to the _Additional Including Directories_ of your solution. This is for including webcc headers with a prefix, e.g., `#include "webcc/http_client_session.h"`. -- Add the following definitions to the project properties page: **C/C++ -> Preprocessor -> Preprocessor Definitions**. - -``` -_WIN32_WINNT=0x0601 -BOOST_ASIO_NO_DEPRECATED -``` -The first one is needed by Asio. `0x0601` means Win7, should be OK even you develop with Win10. From 1c433767cd64d5a3cb19a03bb218afd31bf1abda Mon Sep 17 00:00:00 2001 From: Chunting Gu Date: Wed, 19 Aug 2020 10:21:29 +0800 Subject: [PATCH 2/2] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 11974ec..b95aacb 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ Lightweight C++ HTTP __client and server__ library based on [Asio](https://github.com/chriskohlhoff/asio) for __embedding__ purpose. -Please turn to [doc](doc/) for more tutorials and guides. E.g., [Build Instructions](doc/Build-Instructions.md) and [Integrate Into Your Project](doc/Integrate-Into-Your-Project.md). +=> [Build Instructions](doc/Build-Instructions.md) Git repo: https://github.com/sprinfall/webcc. Please check this one instead of the forked for the latest features.