You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Is lazy loading system functions on UWP still necessary? #143530
However, I'm told that Microsoft stopped enforcing the requirement that store applications (even strictly UWP ones) only use certain APIs in 2020. There is now nothing that block applications from using such APIs unless they're completely restricted functions, (e.g. win32 UI APIs) which would block lazy loading too. There is still a tool that may report certain APIs but that isn't, I'm told, actually relevant nowadays.
I think the end goal is just to allow UWP apps containing Rust code to build, link, run without issues, and eventually get certified and published to the store. iirc the default UWP app template in Visual Studio does not by default link against some "non-UWP" import libs that would fail linkage if the code references to those "non-UWP" APIs, but things may have changed. If the claims as @ChrisDenton being told are reliable, I am perfectly okay with removing lazy loading. In case some users encounter link errors for UWP apps, I would suggest we document the fix somewhere, that is to manually add the import libs in Visual Studio project settings.
The Windows App Certification Kit (WACK)--the tool @ChrisDenton alluded to--is no longer a suitable tool to measure what may/may not pass Microsoft Store certification. (For example, there are low-IL apps that target .NET 9 and fail the WACK today.)
The Partner Center folks don't have much in the way of documentation on this topic. I've reached out to them to get more information, but I'd lean towards "yes, it's safe to link against now". Will update you as soon as I hear back.
Activity
bdbai commentedon Jul 6, 2025
I think the end goal is just to allow UWP apps containing Rust code to build, link, run without issues, and eventually get certified and published to the store. iirc the default UWP app template in Visual Studio does not by default link against some "non-UWP" import libs that would fail linkage if the code references to those "non-UWP" APIs, but things may have changed. If the claims as @ChrisDenton being told are reliable, I am perfectly okay with removing lazy loading. In case some users encounter link errors for UWP apps, I would suggest we document the fix somewhere, that is to manually add the import libs in Visual Studio project settings.
ChrisDenton commentedon Jul 6, 2025
Another option is to
raw-dylibin the standard library for UWP targets so that import libraries aren't needed at all.riverar commentedon Jul 6, 2025
The Windows App Certification Kit (WACK)--the tool @ChrisDenton alluded to--is no longer a suitable tool to measure what may/may not pass Microsoft Store certification. (For example, there are low-IL apps that target .NET 9 and fail the WACK today.)
The Partner Center folks don't have much in the way of documentation on this topic. I've reached out to them to get more information, but I'd lean towards "yes, it's safe to link against now". Will update you as soon as I hear back.
riverar commentedon Jul 6, 2025
Got confirmation from @Sergio0694 that Win32 APIs aren't validated anymore.
ChrisDenton commentedon Jul 7, 2025
Thanks for getting the confirmation.
@bdbai I opened #143592 to remove the lazy loading while still not requiring users to have all the import libs.
bdbai commentedon Jul 7, 2025
@ChrisDenton I totally forgot the raw-dylib feature😅 But thanks for the enhancement!
Rollup merge of rust-lang#143592 - ChrisDenton:uwp-link, r=Mark-Simul…
Rollup merge of rust-lang#143592 - ChrisDenton:uwp-link, r=Mark-Simul…
Rollup merge of rust-lang#143592 - ChrisDenton:uwp-link, r=Mark-Simul…
Unrolled build for #143592
Rollup merge of rust-lang#143592 - ChrisDenton:uwp-link, r=Mark-Simul…
Rollup merge of rust-lang#143592 - ChrisDenton:uwp-link, r=Mark-Simul…
Rollup merge of #143592 - ChrisDenton:uwp-link, r=Mark-Simulacrum