Skip to content

Commit 2037fa7

Browse files
authored
Document vcpkg toolchain configuration (#913)
1 parent 40d2eb5 commit 2037fa7

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

docs/building-with-vcpkg.md

+12
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,18 @@ dependencies:
102102
C++14 or C++17 compiler.
103103
- `nlohmann-json` - required when building with zPages module.
104104
- `prometheus-cpp` - required for Prometheus exporter.
105+
- `gRPC` and `Protobuf` - required for OTLP exporter
105106

106107
It is possible to adjust the build system to use either vcpkg-installed
107108
dependencies or OS-provided dependencies, e.g. `brew` or `deb` packages.
109+
To install the dependencies through vcpkg,
110+
111+
- Set the VCPKG_ROOT env variable to the vcpkg install directory, or
112+
- Set the CMake variable CMAKE_TOOLCHAIN_FILE to vcpkg toolchain file `vcpkg.cmake`.
113+
114+
With either of these settings, the appropriate vcpkg folders get added to the cmake
115+
search path, and makes the required libraries to be found through `find_package()`.
116+
117+
The opentelemetry-cpp repo also brings the vcpkg package under `tools` directory.
118+
This would be used during Windows builds to install the missing dependencies ONLY
119+
if the external vcpkg toolchain is not configured.

0 commit comments

Comments
 (0)