-
|
Hi! I'm building a Qt app with the following vcpkg.json file: {
"$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json",
"name": "myqtapp"
"dependencies": [
{
"name": "qtbase",
"default-features": false,
"features": [
"png",
"jpeg",
"sql-mysql",
"gui",
"testlib",
"widgets",
"network",
"opengl"
],
"platform": "(windows | osx)"
}
],
"overrides": [
{
"name": "qtbase",
"port-version": 2,
"version-string": "6.5.1"
}
]
}I'm building this on an M1 (arm64) Mac using the target triplets However, for the I kind of understand that we need to build qtbase with the host triplet since qtbase somehow has a host dependency on itself, but why does it need all those features? Qt's vcpkg.json file (even at 6.5.1#2) only lists this host dependency: {
"name": "qtbase",
"host": true,
"default-features": false
},Another thing that's strange to me is that in the case where the target and host triplets match, the host version of qtbase seems okay with using the same features as the target, but in the other case the host brings in a bunch of additional features (the default-features maybe?). Any input that helps me understand how this works is appreciated! Thanks in advance, |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
|
When vcpkg installs a package, it usually installs the port's default features. (Basically, that's why they are called "default features".) To change that behavior, the user must make an explicit request in the top-level install specification (command line or manifest). As you noticed, this is considered per triplet. (Basically, this mirrors the fact that features vary subject to dependencies and triplet.) In a way, it is reasonable and cumbersome at the same time... Please don't argue with me. I'm just answering. |
Beta Was this translation helpful? Give feedback.
When vcpkg installs a package, it usually installs the port's default features. (Basically, that's why they are called "default features".)
To change that behavior, the user must make an explicit request in the top-level install specification (command line or manifest). As you noticed, this is considered per triplet. (Basically, this mirrors the fact that features vary subject to dependencies and triplet.)
In a way, it is reasonable and cumbersome at the same time...
Many users expect a different behavior but often don't consider all consequences.
Some contributors want that default features are generally disabled for host dependencies, at least at user request.
Microsoft decided to just …