[python-win32] pywin32 build 211 released
le dahut
le.dahut at laposte.net
Tue Jun 17 17:23:02 CEST 2008
Mark Hammond wrote :
>> #2 : the .exe must have a manifest that contains :
>> """
>> ... (I use the "python.exe.manifest" in which I add the following)
>> <trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
>> <security>
>> <requestedPrivileges>
>> <requestedExecutionLevel
>> level="requireAdministrator"
>> uiAccess="false"/>
>> </requestedPrivileges>
>> </security>
>> </trustInfo>
>> """
>>
>>
>> I've put the manifest directly in the .exe using py2exe and :
>> 'other_resources': [(24, 1, mymanifest)],
>> "24" is where the manifest should be.
>
> I'm not sure this will work (and I'm not sure if you are saying it does or
> doesn't work). To check it works, you should use the 'mt.exe' tool that
> comes with the MSVC compilers and Platform SDKs to check it can extract a
> manifest, and it is as you expect.
Actually this works fine, it was only an idea that you can use to make
pywin32 installable on XP without service pack :
* on XP it will have the classic behaviour (like with pywin32-210)
* on Vista, user will be prompted for an elevation
I suppose that you don't use py2exe but maybe you can add an embedded
manifest in your installer.
http://msdn.microsoft.com/en-us/library/bb756929.aspx
>
> Yet another alternative is to use mt.exe *after* py2exe has run to embed the
> manifest in the final executable.
>
> Note however that it is rare you need the py2exe created executable to run
> as administrator - it is the *installer* for the py2exe program that
> generally needs this.
>
>> #3 Maybe someone could complete here ...?
>
> Hope the above help.
>
> Cheers,
>
> Mark
>
>
>
More information about the python-win32
mailing list