Vcpkg fails due to "VcpkgTools.xml" file

Answered

I'm at a complete standstill in CLion due to vcpkg failing with this error:

The following packages will be rebuilt:
 * fmt:arm64-osx -> 11.0.2#1
 * nlohmann-json:arm64-osx -> 3.12.0
 * rapidcsv:arm64-osx -> 8.85
 * spdlog:arm64-osx -> 1.15.3
 * vcpkg-cmake:arm64-osx -> 2024-04-23
 * vcpkg-cmake-config:arm64-osx -> 2024-05-23
 Additional packages (*) will be modified to complete this operation.
read_contents("/Users/{redacted}/.vcpkg-clion/vcpkg/scripts/vcpkgTools.xml"): No such file or directory

Admittedly I'm not super well versed in what I could do to troubleshoot this. The most information I've found is CLion's support page which just directs me to the "Update Vcpkg Repository" menu option, which it does without complaint, but still fails to run.

I've seen somewhere that vcpkg has switched that XML to a JSON file, which I see in the directory it's complaining about, but I don't know what is still looking for an XML, nor do I know how to correct it.

 

Naturally this has rendered CLion completely useless because CMake cannot run if vcpkg fails.

0
2 comments

Hello!

Please close CLion, then do cd /Users/{redacted}/.vcpkg-clion/vcpkg in the terminal, git pull and ./bootstrap-vcpkg.sh. After that, open CLion. Does Vcpkg work in CLion in this case?

1

Ran into this problem today after not using CLion for a while. Thankfully, Anna's fix above worked for me.

0

Please sign in to leave a comment.