Closed sammi closed 4 years ago
You have to install the dependencies and somehow tell CMake where they are. By far the easiest way to do that when you're using Visual Studio 2019 is to install them with vcpkg.
You can actually install cppgraphqlgen that way too. If you use vcpkg install --head cppgraphqlgen
it should even be up to date with changes that haven't been integrated yet in the vcpkg
port.
I figured it out by the following two steps:
cd C:/Users/songy/cloud/vcpkg
vcpkg install pegtl boost-program-options boost-filesystem rapidjson gtest
{
"configurations": [
{
"name": "x86-Debug",
"generator": "Ninja",
"configurationType": "Debug",
"buildRoot": "${projectDir}\\out\\build\\${name}",
"installRoot": "${projectDir}\\out\\install\\${name}",
"cmakeCommandArgs": "",
"buildCommandArgs": "",
"ctestCommandArgs": "",
"cmakeToolchain": "C:/Users/songy/cloud/vcpkg/scripts/buildsystems/vcpkg.cmake",
"inheritEnvironments": [ "msvc_x86" ],
"variables": []
}
]
}
Visual studio 2019 Build Error: Target: x64-Debug
Error:
Severity Code Description Project File Line Suppression State Error CMake Error at C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/share/cmake-3.17/Modules/FindPackageHandleStandardArgs.cmake:164 (message): Could NOT find Boost (missing: Boost_INCLUDE_DIR program_options) C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/share/cmake-3.17/Modules/FindPackageHandleStandardArgs.cmake 164
Visual Studio 2019 latest Preview Build Error:
Target: x64-Debug
Severity Code Description Project File Line Suppression State Error CMake Error at C:/Program Files (x86)/Microsoft Visual Studio/2019/Preview/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/share/cmake-3.17/Modules/FindPackageHandleStandardArgs.cmake:164 (message): Could NOT find Boost (missing: Boost_INCLUDE_DIR program_options) C:/Program Files (x86)/Microsoft Visual Studio/2019/Preview/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/share/cmake-3.17/Modules/FindPackageHandleStandardArgs.cmake 164