Avoid wrong use of popular but ambiguous variables (`WIN32` etc.) in
scripts and portfiles by detection in CI.
Sometimes the variables are used wrongly, and sometimes this isn't
caught in PR review. This PR tries to catch those variables (when in the
active code path in script mode). [This can happen to every
contributor](https://github.com/microsoft/vcpkg/pull/34356#discussion_r1360074122),
even if he/she knows the rules ... vcpkg is raising the bar higher than
usual, having to deal with targets and hosts even in script mode.
(`b2-options.cmake` (boost fragment) shows where we get if we don't pay
attention: the same code being used in script mode (`WIN32` meaning
host) and in project mode (`WIN32` meaning target).)
The new check doesn't break any user builds because it relies on command
line options. However it changes the ABI hashes.
introduce `vcpkg_generate_meson_cmd_args` to generate the command line
args vcpkg calls meson with. This needed to be factored out since it
allows calling the meson-py backend of setuptools with the same
arguments as calling meson manually within vcpkg.
additionally:
- fixed `CMAKE_BUILD_TYPE` (var `buildconfig` does not exist)
- add `ADDITIONAL_PROPERTIES` option
- removed a lot of stuff being added to PATH unnecessarily
- added option `--pkgconfig.relocatable` (probably not necessary but we
want this any way.)
- added option `--pkg-config-path` with correct paths (allows removing
the env variables for it)
The `use-prov-client` feature in the `vcpkg.json` manifest file was
removed in PR #29046, ~probably by mistake when removing the
`public-preview` feature,~ and therefore it is not possible to enable
the device provisioning client.
The latest 3.5.x releases have an `INTEGRATE_VCPKG` option that is
enabled to be compatible with vcpkg packages lookup so that the original
patch is not needed anymore. Besides, in this case, `asio` is depended
rather than `boost-asio`.
Fixes#38764, update `7zip` to 24.06.
No feature needs to be tested, the usage test passed on
`x64-windows`(header files found):
```
7zip provides CMake targets:
# this is heuristically generated, and may not be correct
find_package(7zip CONFIG REQUIRED)
target_link_libraries(main PRIVATE 7zip::7zip)
```
In an internal version of Visual Studio, `arrow`, `concurrencpp` and
`qtwebengine` install failed with following error:
```
arrow: \cpp\src\arrow/json/object_writer.h(39): error C2039: 'string': is not a member of 'std'
concurrencpp: \include\concurrencpp/threads/thread.h(23): error C2039: 'string': is not a member of 'std'
qtwebengine: \src\3rdparty\gn\src\gn\escape.h(77): error C2039: 'string': is not a member of 'std'
```
This issue caused by the STL PR:
https://github.com/microsoft/STL/pull/4633, and according to Stephan's
suggestion, the affected files need to include the `Standard <string>
header`.
I have submitted an issue on the qt upstream:
https://bugreports.qt.io/browse/QTBUG-126156
Mitigation for #39198.
Mesa CI is currently disabled for linux and osx, and also doesn't run
for android.
So we see CI effects only for Windows. Improving CI situation for mesa
is the subject of #36081. So keeping egl out of CI like before
https://github.com/microsoft/vcpkg/pull/37599 is the best option at the
moment.