[Python-Dev] Python as a Metro-style App

Dino Viehland dinov at microsoft.com
Thu Jan 12 01:46:15 CET 2012


Martin wrote:
> See the start of the thread: I tried to create a "WinRT Component DLL", and
> that failed, as VS would refuse to compile any C file in such a project. Not
> sure whether this is triggered by defining WINAPI_FAMILY=2, or any other
> compiler setting.
> 
> I'd really love to use WINAPI_FAMILY=2, as compiler errors are much easier
> to fix than verifier errors.

I got the same errors as you - it seems like they're related to enabling the Immersive 
bit for the compile of the DLL.  I'm not certain if that's necessary, when I did
the run before to see if Python would pass the app store validation it didn't care that
we didn't have the App Container bit set on the DLL (it did want NXCOMPAT and dynamic
base set though).  I was also able to just define WINAPI_FAMILY=2 in the .vcxproj file 
and I got the various expected errors when accessing banned APIs (it actually seems 
like a bunch were missing vs. what the validator reported, but maybe that's just an
issue w/ the developer preview).  Once I fixed those errors up I was able to get a DLL
that successfully compiled.

I'm going to ping some people on the windows team and see if the app container
bit is or will be necessary for DLLs.







More information about the Python-Dev mailing list