Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[cppwinrt] hiddes installtion of winrt from VS #38620

Closed
Neumann-A opened this issue May 7, 2024 · 4 comments
Closed

[cppwinrt] hiddes installtion of winrt from VS #38620

Neumann-A opened this issue May 7, 2024 · 4 comments
Assignees
Labels
category:port-bug The issue is with a library, which is something the port should already support Stale

Comments

@Neumann-A
Copy link
Contributor

There are only three options here:

  • remove the port or mark it as skipped in CI
  • make everything using cppwinrt use the port (and maybe remove the component from the VS installer; also means UWP probably would need to autoload the port)
  • move stuff into a manual-include/manual-lib folder where it won't get autodetected.

Issues due to cppwinrt being available: #38600
ffmpegmediaplugind.lib(qffmpegwindowcapture_uwp.cpp.obj) : error LNK2038: mismatch detected for 'C++/WinRT version': value '2.0.240111.5' doesn't match value '2.0.220110.5' in Qt6Cored.lib(qlocale_win.cpp.obj)

@tsondergaard
Copy link
Contributor

@Neumann-A, what commit (or other change) caused this to be a problem? The last commit to cppwinrt is commit 3a7cb34 and it is more than six weeks old. And how did the error get through CI?

@Neumann-A
Copy link
Contributor Author

@tsondergaard: Simply CI is not setup to detect those issues. It basically had always be the problem but is only now visible due to qtinterfaceframework actual linking code which was build with different winrt versions due to the cppwinrt port since it links qtbase and qtmultimedia. It only happens if cppwinrt is installed between the build of qtbase and qtmultimedia.
cppwinrt version is 2.0.240111.5 while the VS installed version in CI is 2.0.220110.5. Qt has a check for winrt since Qt 6.2 looking for include <winrt/base.h>

@data-queue
Copy link
Contributor

@Neumann-A The correct fix is as you mentioned to make cppwinrt a dependency of qtbase (or whatever feature) on windows.

Long term fix is your second point (make everything using cppwinrt use the port) and optionally we can have detection logic in the port for a VS install. The point is to let the cppwinrt port choose whether it should find or generate the C++ WinRT headers.

I don't think we can remove the component from VS: the C++ WinRT is part of the Windows SDK workload.

@FrankXie05 FrankXie05 added the category:port-bug The issue is with a library, which is something the port should already support label May 9, 2024
Copy link

github-actions bot commented Nov 6, 2024

This is an automated message. Per our repo policy, stale issues get closed if there has been no activity in the past 180 days. The issue will be automatically closed in 14 days. If you wish to keep this issue open, please add a new comment.

@github-actions github-actions bot added the Stale label Nov 6, 2024
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Nov 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:port-bug The issue is with a library, which is something the port should already support Stale
Projects
None yet
Development

No branches or pull requests

4 participants