← Back to team overview

bzr-windows team mailing list archive

Re: python 2.6 + msvc2008express + manifest files for pyd

 

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 5/13/2011 11:10 AM, Alexander Belchenko wrote:
> Alexander Belchenko пишет:
>> While building C extensions I've noticed that msvc has created
>> manifest file for every pyd file, see attached one of them.
> 
> Now actually attached.
> 

This is the one I'm using:

C:\Program Files\Microsoft Visual Studio 9.0\VC>cl /?
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 15.00.30729.01
for 80x86
Copyright (C) Microsoft Corporation.  All rights reserved.


I'm not really sure whether that is 2008 or something older. I do see
that I have a beta version of VS 10.


Manifests should generally be bundled with the dlls they are associated
with. *However* there is a way to tell the linker/compiler/whatever to
embed the manifest into the dll itself.

I don't remember how to do it, but I do remember running into it.
http://msdn.microsoft.com/en-us/library/ms235591%28VS.80%29.aspx

And when I run "py setup.py build_ext -i" this is what I see:

...
> C:\Program Files\Microsoft Visual Studio 9.0\VC\BIN\link.exe /DLL /nologo /INCREMENTAL:NO /LIBPATH:C
> :/local/lib /LIBPATH:C:\Python26\libs /LIBPATH:C:\Python26\PCbuild /EXPORT:init_groupcompress_pyx bu
> ild\temp.win32-2.6\Release\bzrlib\_groupcompress_pyx.obj build\temp.win32-2.6\Release\bzrlib/diff-de
> lta.obj /OUT:C:\Users\jameinel\dev\bzr\bzr.dev\bzrlib\_groupcompress_pyx.pyd /IMPLIB:build\temp.win3
> 2-2.6\Release\bzrlib\_groupcompress_pyx.lib /MANIFESTFILE:build\temp.win32-2.6\Release\bzrlib\_group
> compress_pyx.pyd.manifest
>    Creating library build\temp.win32-2.6\Release\bzrlib\_groupcompress_pyx.lib and object build\temp
> .win32-2.6\Release\bzrlib\_groupcompress_pyx.exp
> C:\Program Files\Microsoft SDKs\Windows\v6.0A\bin\mt.exe -nologo -manifest build\temp.win32-2.6\Rele
> ase\bzrlib\_groupcompress_pyx.pyd.manifest -outputresource:C:\Users\jameinel\dev\bzr\bzr.dev\bzrlib\
> _groupcompress_pyx.pyd;2


So we are already calling "mt.exe -manifest".

My guess is that, no, we don't need to include the .xml file because we
are already bundling the manifest into the .pyd file.

John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk3M94gACgkQJdeBCYSNAAOUVwCcD/lWxNjH3Iims12Ra05/jCLh
hfoAn25ALKRFIweQ4oE6qQKECorwZJQF
=Cv9o
-----END PGP SIGNATURE-----


Follow ups

References