Skip to content

Commit e41f30f

Browse files
authored
Update vcpkg.md
1 parent 085986d commit e41f30f

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

docs/vcpkg.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,25 @@ First add it as submodule to your peoject:
33

44
`git submodule add https://github.com/microsoft/vcpkg`
55

6+
7+
## Building Dependecies with Your CMakeLists
8+
Now add the following to your CMakeLists
9+
10+
```
11+
et(CMAKE_BUILD_TYPE Debug)
12+
13+
if (NOT DEFINED CMAKE_TOOLCHAIN_FILE)
14+
set(CMAKE_TOOLCHAIN_FILE "${CMAKE_SOURCE_DIR}/vcpkg/scripts/buildsystems/vcpkg.cmake" CACHE PATH "toolchain file")
15+
endif()
16+
17+
message("${CMAKE_TOOLCHAIN_FILE}")
18+
project(vcpkg-name)
19+
20+
find_package(<package-name> REQUIRED)
21+
```
22+
## Building and Installing Dependecies
23+
Alternatively you can install everything globally/ locally
24+
625
Then run the following script on windows:
726

827
`.\vcpkg\bootstrap-vcpkg.bat`

0 commit comments

Comments
 (0)