Comments (7)
After a lot of digging, I think this is caused by the vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/Opus)
function call in https://github.com/microsoft/vcpkg/blob/master/ports/opus/portfile.cmake.
The problem is that in OpusConfig.cmake, the path given as the install root directory is compute by
get_filename_component(PACKAGE_${CMAKE_FIND_PACKAGE_NAME}_COUNTER_1 "${CMAKE_CURRENT_LIST_DIR}/../../../" ABSOLUTE)
where the /../../../
is in term calculated by CMake at configure time using the following code:
if(IS_ABSOLUTE "${CCF_INSTALL_DESTINATION}")
set(absInstallDir "${CCF_INSTALL_DESTINATION}")
else()
set(absInstallDir "${installPrefix}/${CCF_INSTALL_DESTINATION}")
endif()
file(RELATIVE_PATH PACKAGE_RELATIVE_PATH "${absInstallDir}" "${installPrefix}" )
In Opus case, absInstallDir
is
${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}/cmake/${PACKAGE_NAME}/
This is resolved to ${VCPKG_ROOT}/installed/lib/cmake/opus
Whence the install relative path is ${absInstallDir}/../../../
. However, once the fixup function is called in the portfile, the path is moved to
${VCPKG_ROOT}/installed/x64-linux/share/opus
which is one level shallower than the true config install location. Thus the path defined in the CMake config file points to ${VCPKG_ROOT}/installed
instead of ${VCPKG_ROOT}/installed/x64-linux
, which causes the file not found error.
I don't exactly know what has caused this regression, since none of the repositories involved have changed in ~2 years so far as I can tell. My cmake version has recently been updated, but I can't see why that would make a difference. I hope this helps.
from vcpkg.
It is because of CMake 3.29.1. a lot of other packages also have the same issue. A temp fix is to use an older version of CMake.
from vcpkg.
Also failing on windows-x64-release
:\a\performous\performous\performous\cmake\triplets\x64-windows-release.cmake: info: loaded overlay triplet from here
-- Downloading https://github.com/libsndfile/libsndfile/archive/1.2.2.tar.gz -> libsndfile-libsndfile-1.2.2.tar.gz...
-- Extracting source D:/a/performous/performous/vcpkg/downloads/libsndfile-libsndfile-1.2.2.tar.gz
-- Applying patch 001-avoid-installing-find-modules.patch
-- Using source at D:/a/performous/performous/vcpkg/buildtrees/libsndfile/src/1.2.2-fa730f3d73.clean
-- Found external ninja('1.11.0').
-- Configuring x64-windows-release
CMake Error at scripts/cmake/vcpkg_execute_required_process.cmake:112 (message):
Command failed: "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/Common7/IDE/CommonExtensions/Microsoft/CMake/Ninja/ninja.exe" -v
Working Directory: D:/a/performous/performous/vcpkg/buildtrees/libsndfile/x64-windows-release-rel/vcpkg-parallel-configure
Error code: 1
See logs for more information:
D:\a\performous\performous\vcpkg\buildtrees\libsndfile\config-x64-windows-release-rel-CMakeCache.txt.log
D:\a\performous\performous\vcpkg\buildtrees\libsndfile\config-x64-windows-release-out.log
Call Stack (most recent call first):
installed/x64-windows/share/vcpkg-cmake/vcpkg_cmake_configure.cmake:252 (vcpkg_execute_required_process)
ports/libsndfile/portfile.cmake:27 (vcpkg_cmake_configure)
scripts/ports.cmake:175 (include)
error: building libsndfile:x64-windows-release failed with: BUILD_FAILED
Elapsed time to handle libsndfile:x64-windows-release: 1.6 s
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+libsndfile
You can submit a new issue at:
https://github.com/microsoft/vcpkg/issues/new?title=[libsndfile]+Build+error+on+x64-windows-release&body=Copy+issue+body+from+D%3A%2Fa%2Fperformous%2Fperformous%2Fvcpkg%2Finstalled%2Fvcpkg%2Fissue_body.md
You can also submit an issue by running (GitHub CLI must be installed):
gh issue create -R microsoft/vcpkg --title "[libsndfile] Build failure on x64-windows-release" --body-file D:/a/performous/performous/vcpkg/installed/vcpkg/issue_body.md
from vcpkg.
from vcpkg.
Ok, so it is a cmake issue. I shall raise an issue there.
from vcpkg.
No, just follow the links,
from vcpkg.
Duplicate of #37968.
Don't use CMake 3.29.1, please refer to this solution: #37968 (comment) or use the CMake which downloaded by VCPKG..
from vcpkg.
Related Issues (20)
- 2024.04.23 build failure HOT 2
- [boost-mpi] Build error on x64-windows HOT 1
- [cudnn] Build error on x64-windows HOT 1
- [dbus] Build error on x64-linux HOT 6
- [New Port Request] Unity: an unit test framework for pure C
- [simde] update to 0.8.2
- [vtk] Build error on x64-linux-release HOT 3
- [boost-system] Build failure on x64-linux HOT 9
- [boost] Close all issues regarding boost
- [boost-container-hash] Build error on x64-windows HOT 2
- How to use "Just my Code: in Visual Studio debugger to exclude code from vcpkg packages
- [wxwidgets] Cannot link wx::wxgl namespace. HOT 3
- [boost-log] Project link failure HOT 6
- [OpenCV] HOT 7
- [libdeflate] Build error on x64-linux HOT 2
- [mosquitto] Build error (version 1.4.15) HOT 1
- [opencv4] build failure
- [boost] boost:x64-windows build failed HOT 3
- [opencv4] build failure HOT 4
- [devil] build failure on mac os arm64 HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vcpkg.