Thank you for sharing it with me.
Unfortunately, that still has not been able to solve my issue.
I have installed zip 3.0-12build2, g++ 4:11.2.0-1ubuntu1, build-essential 12.9ubuntu3 and CMake 3.29.2.
When I run vcpkg install, I still get the same error I used to.
I don’t know how useful it would be but here is the full output when I run vcpkg install --no-print-usage.
Fetching registry information from https://github.com/microsoft/vcpkg (HEAD)...
Detecting compiler hash for triplet x64-linux...
The following packages will be built and installed:
asio:x64-linux@1.30.2 -- /home/aniruddha/.cache/vcpkg/registries/git-trees/17ce1a2d17d0cb0d50eb72c89a9e51f472ef31f4
pthreads:x64-linux@3.0.0#14 -- /home/aniruddha/.cache/vcpkg/registries/git-trees/2e0a6df2800d3677b941dc6504f083965b7886d9
* vcpkg-cmake:x64-linux@2023-05-04 -- /home/aniruddha/.cache/vcpkg/registries/git-trees/88a7058fc7fa73a9c4c99cfcae9d79e2abf87a5a
* vcpkg-cmake-config:x64-linux@2022-02-06#1 -- /home/aniruddha/.cache/vcpkg/registries/git-trees/8d54cc4f487d51b655abec5f9c9c3f86ca83311f
Additional packages (*) will be modified to complete this operation.
Restored 2 package(s) from /home/aniruddha/.cache/vcpkg/archives in 9.08 ms. Use --debug to see more details.
Installing 1/4 vcpkg-cmake-config:x64-linux@2022-02-06#1...
Elapsed time to handle vcpkg-cmake-config:x64-linux: 672 us
vcpkg-cmake-config:x64-linux package ABI: 1b0adf59a9ffa6b0d3824cd6f3c6ae5ddb359479edf1da9d19bb5408d5a42ec7
Installing 2/4 vcpkg-cmake:x64-linux@2023-05-04...
Elapsed time to handle vcpkg-cmake:x64-linux: 577 us
vcpkg-cmake:x64-linux package ABI: 4bab11b9f95cba121c8d9da8de601153056eb7b1edc5fc6277aca0511d5727db
Installing 3/4 asio:x64-linux@1.30.2...
Building asio:x64-linux@1.30.2...
/home/aniruddha/.cache/vcpkg/registries/git-trees/17ce1a2d17d0cb0d50eb72c89a9e51f472ef31f4: info: installing overlay port from here
-- Using /home/aniruddha/.local/bin/vcpkg/downloads/chriskohlhoff-asio-asio-1-30-2.tar.gz
-- Cleaning sources at /home/aniruddha/.local/bin/vcpkg/buildtrees/asio/src/sio-1-30-2-504a65d4d1.clean. Use --editable to skip cleaning for the packages you specify.
-- Extracting source /home/aniruddha/.local/bin/vcpkg/downloads/chriskohlhoff-asio-asio-1-30-2.tar.gz
-- Using source at /home/aniruddha/.local/bin/vcpkg/buildtrees/asio/src/sio-1-30-2-504a65d4d1.clean
CMake Error at /home/aniruddha/Learning progress/C++/code-crafters-redis-cpp/vcpkg_installed/x64-linux/share/vcpkg-cmake/vcpkg_cmake_configure.cmake:48 (vcpkg_list):
Unknown CMake command "vcpkg_list".
Call Stack (most recent call first):
/home/aniruddha/.cache/vcpkg/registries/git-trees/17ce1a2d17d0cb0d50eb72c89a9e51f472ef31f4/portfile.cmake:16 (vcpkg_cmake_configure)
scripts/ports.cmake:140 (include)
error: building asio:x64-linux failed with: BUILD_FAILED
See https://learn.microsoft.com/vcpkg/troubleshoot/build-failures?WT.mc_id=vcpkg_inproduct_cli for more information.
Elapsed time to handle asio:x64-linux: 189 ms
Please ensure you're using the latest port files with `git pull` and `vcpkg update`.
Then check for known issues at:
https://github.com/microsoft/vcpkg/issues?q=is%3Aissue+is%3Aopen+in%3Atitle+asio
You can submit a new issue at:
https://github.com/microsoft/vcpkg/issues/new?title=[asio]+Build+error+on+x64-linux&body=Copy+issue+body+from+%2Fhome%2Faniruddha%2FLearning%20progress%2FC%2B%2B%2Fcode-crafters-redis-cpp%2Fvcpkg_installed%2Fvcpkg%2Fissue_body.md
If the issue persists, I’d recommend opening a new issue on the vcpkg repo, as suggested by the error message. Make sure to include relevant details about your environment and the error.
I was able to fix my issue. The issue was that vcpkg install was running a different vcpkg bundled by Ubuntu and was basically ignoring that I had set the path to something else.
Running whereis vcpkg and doing a git pull there solved the issue