We use cmake to build the workflow project. It denpends one OpenSSL. It's essential to install CMake and OpenSSL.
Visit CMake Homepage, and download the msi installer to install cmake.
- Download the source code to compile
- Download the bianary installer of OpenSSL
- Install by Chocolatey
- Install by VCPKG
Visit OpenSSL Homepage or Github repository to download the source code. Compile OpenSSL by its document.
Google OpenSSL binary installer and download the installer to install. Do not use light version, because it doesn't contains include and lib dictionary.
Here is a binary installer download website.
Chocolatey is a powerful package manager on windows. It's like apt-get or yum on some Linux distribution.
Use the command to install OpenSSL by Chocolatey.
choco install openssl
VCPKG is a powerful CPP package manager across platforms. It simplify the installation of some libraries.
Use the command to install OpenSSL by vcpkg.
vcpkg install openssl
Specify the OPENSSL_ROOT_DIR to generate Visual Studio Project, Such as
cmake -B [build directory] -S . -DOPENSSL_ROOT_DIR=[openssl directory]
Use Command to generate Visual Studio Project
cmake -B [build directory] -S .
Specify CMAKE_TOOLCHAIN_FILE is essential to generate Visual Studio Project, Suche as
cmake -B [build directory] -S . -DCMAKE_TOOLCHAIN_FILE=[vcpkg.cmake directory]
# If the above command fails, try to specify VCPKG_TARGET_TRIPLET, use x86-windows or x64-windows
cmake -B [build directory] -S . -DVCPKG_TARGET_TRIPLET=x86-windows -DCMAKE_TOOLCHAIN_FILE=[vcpkg.cmake directory]
[openssl directory]: openssl directory of source code
[vcpkg.cmake directory] : [vcpkg-root]\scripts\buildsystems\vcpkg.cmake
The VS Project(workflo.sln) will be generated now.
Use VS to open workflow.sln or use cmake command to compile workflow, Such as
# Compile Debug Config
cmake --build [build directory] --config Debug
# Compile Release Config
cmake --build [build directory] --config Release
# Generate VS Project of tutorial
cmake -B build_tutorial tutorial
# Compile Debug Config
cmake --build build_tutorial --config Debug
# Compile Release Config
cmake --build build_tutorial --config Release
# compile result will be generated in tutorial\Debug or tutorial\Release directory
Workflow is already supported by VCPKG. If you don't care the source code of workflow, It's more easier to use vcpkg to install it.
Install current version of workflow:vcpkg install workflow
Install HEAD version of workflow:vcpkg install workflow --head
Some examples:
md D:\tmp
cd D:\tmp
git clone https://github.com/microsoft/vcpkg.git
cd vcpkg
.\bootstrap-vcpkg.bat
# x86-windows is default, it means .\vcpkg.exe install workflow:x86-windows
.\vcpkg.exe install workflow
# Specify x64-windows to install X64 version
.\vcpkg.exe install workflow:x64-windows
cd D:\tmp
git clone https://github.com/dengjunplusplus/workflow-vcpkg-tutorial
cd D:\tmp\workflow-vcpkg-tutorial\workflow
cmake -DCMAKE_TOOLCHAIN_FILE=D:/tmp/vcpkg/scripts/buildsystems/vcpkg.cmake -B build
# If the above command fails, try to specify VCPKG_TARGET_TRIPLET, use x86-windows or x64-windows
cmake -DCMAKE_TOOLCHAIN_FILE=D:/tmp/vcpkg/scripts/buildsystems/vcpkg.cmake -DVCPKG_TARGET_TRIPLET=x86-windows -B build
cmake --build build --config Debug
cmake --build build --config Release
cd /tmp
rm -rf vcpkg
rm -rf workflow-vcpkg-tutorial
git clone https://github.com/microsoft/vcpkg.git
cd vcpkg
./bootstrap-vcpkg.sh
./vcpkg install workflow
cd ..
git clone https://github.com/dengjunplusplus/workflow-vcpkg-tutorial.git
cd workflow-vcpkg-tutorial/workflow
cmake -DCMAKE_TOOLCHAIN_FILE=/tmp/vcpkg/scripts/buildsystems/vcpkg.cmake -B build
# If the above command fails, try to specify VCPKG_TARGET_TRIPLET, x64-linux or x86-linux or x64-osx
cmake -DCMAKE_TOOLCHAIN_FILE=/tmp/vcpkg/scripts/buildsystems/vcpkg.cmake -DVCPKG_TARGET_TRIPLET=x64-linux -B build
cmake --build build --config Debug
cmake --build build --config Release
If you have some problems about use Workflow or compile it. Welcome to commit Issue or Email us.
- Xie Han - [email protected]
- Li Yingxin - [email protected]
- Deng Jun - [email protected]