microsoft/Windows-classic-samples

CloudMirror project does not build. MIDL2011

florianhaar opened this issue · 4 comments

Hi,
I get the following error after building the CloudMirrorPackage:

`
Erstellen gestartet...
1>------ Erstellen gestartet: Projekt: CloudMirror, Konfiguration: Debug Win32 ------
1>MIDLRT Processing C:\Projects\Windows-classic-samples\Samples\CloudMirror\CloudMirror\StatusUI.idl
1>StatusUI.idl
1>MIDLRT Processing C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\winrt\winrtbase.idl
1>winrtbase.idl
1>MIDLRT Processing C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\winrt\midlbase.idl
1>midlbase.idl
1>Processing WinMD c:\program files (x86)\windows kits\10\references\10.0.17763.0\windows.storage.provider.cloudfilescontract\3.0.0.0\windows.storage.provider.cloudfilescontract.winmd
...
1>C:\Projects\Windows-classic-samples\Samples\CloudMirror\CloudMirror\StatusUI.idl(11): error MIDL2011: [msg]unresolved type declaration [context]: Windows.Storage.Provider.IStorageProviderStatusUISourceFactory [ RuntimeClass 'CloudMirror.MyStatusUISourceFactory' ]
1>Die Erstellung des Projekts "CloudMirror.vcxproj" ist abgeschlossen -- FEHLER.
2>------ Erstellen gestartet: Projekt: CloudMirrorPackage, Konfiguration: Debug x86 ------
2>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Microsoft\VisualStudio\v17.0\AppxPackage\Microsoft.AppXPackage.Targets(841,5): warning : Die Zertifikatdatei ist nicht vorhanden: CloudMirrorPackage_TemporaryKey.pfx
2>C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Microsoft\DesktopBridge\Microsoft.DesktopBridge.targets(744,5): error : Die angegebene EntryPointExe "CloudMirror.exe" wurde nicht in den Projektausgaben gefunden.
2>Die Erstellung des Projekts "CloudMirrorPackage.wapproj" ist abgeschlossen -- FEHLER.
========== Erstellen: 0 erfolgreich, 2 Fehler, 0 aktuell, 0 übersprungen ==========
========== Bereitstellen: 0 erfolgreich, 0 fehlgeschlagen, 0 übersprungen ==========

`
Can somebody help to fix this? I have Windows 11 and Visual Studio 2022. I also installed the SDK 10.17763.0

Thank you

CloudMirror sample was updated recently. It requires Windows SDK 10.0.22598.0 or higher now:

#error This sample requires the Windows SDK version 10.0.22598.0 or higher.

The Windows Insider Preview SDK can be downloaded here: https://docs.microsoft.com/en-us/windows-insider/flight-hub/

Ok, thank you. I will give it a try :)

Unfortunately, I can't find a way to get MIDL to generate a better error message. If you can find something, please create a PR.

@oldnewthing can you update the samples to 10.0.22621? 10.0.22598 is not a supported version.