From cbb3bce0cc73957bf16eaaa968e6177451307e23 Mon Sep 17 00:00:00 2001 From: Hartmut Kaiser Date: Wed, 7 Jun 2017 12:26:57 -0500 Subject: [PATCH] Improve integration with vcpkg package manager - this allows to build HPX outside of vcpkg while still relying on its package repository for Boost and hwloc --- CMakeLists.txt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a1ea2241be70..e9af96723c80 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -114,9 +114,13 @@ endif() # Adjust a couple of build-system settings, if HPX is to be built using vcpkg if(MSVC) + set(_with_vcpkg_default OFF) + if(VCPKG_TOOLCHAIN) + set(_with_vcpkg_default ON) + endif() hpx_option(HPX_WITH_VCPKG BOOL "Build HPX in the context of the vcpkg build and configuration tool (default: OFF)." - OFF ADVANCED) + ${_with_vcpkg_default} ADVANCED) if(HPX_WITH_VCPKG) hpx_add_config_define(HPX_HAVE_VCPKG) endif()