I'm trying to learn how to use vcpkg for C++ using Microsoft Visual Studio. I'm following this tutorial, and I'm up to the building the project step, and I'm getting this error:
Build All started: Project: VCPKG Test, Configuration: default ------ This program is blocked by group policy. For more information, contact your system administrator.
Build All failed.
I have tried a bunch of tutorials for disabling group policy, if this is the error, but there is no group policy enforced on my computer, as far as I can tell. My laptop is part of my school domain, but I don't believe that should impact MSVC. This is the code:
// CmakeLists.txt
cmake_minimum_required (VERSION 3.10)
project ("VCPKG Test")
find_package(fmt CONFIG REQUIRED)
add_executable (VCPKGTEST "VCPKG Test.cpp")
target_link_libraries(VCPKGTEST PRIVATE fmt::fmt)
// Main.cpp
#include <fmt/core.h>
int main()
{
fmt::print("Hello World!\n");
return 0;
}
// CMakeUsersPresets.json
{
"version": 3,
"configurePresets": [
{
"name": "default",
"cacheVariables": {
"CMAKE_TOOLCHAIN_FILE": "C:/Users/NOR0029/vcpkg/scripts/buildsystems/vcpkg.cmake"
}
}
]
}