开发者

VS2008 generated dll has dependency to two different versions of CRT assembly

开发者 https://www.devze.com 2023-02-16 00:56 出处:网络
My VS2008 projects generates a dll and links against two other static library. Here is the generated manifest :

My VS2008 projects generates a dll and links against two other static library. Here is the generated manifest :

<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
  <trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
    <security>
      <requestedPrivileges>
        <requestedExecutionLevel level="asInvoker" uiAccess="false"></requestedExecutionLevel>
      </requestedPrivileges>
    </security>
  </trustInfo>
  <dependency>
    <dependentAssembly>
      <assemblyIdentity type="win32" name="Microsoft.VC90.CRT" version="9.0.21022.8" processorArchitecture="x86" publicKeyToken="1fc8b3b9a1e18e3b"></assemblyIdentity>
    </dependentAssembly>
  </dependency>
  <dependency>
    <dependentAssembly>
      <assemblyIdentity type="win32" name="Microsoft.VC90.CRT" version="9.0.30729.4148" processorArchitecture="x86" publicKeyToken="1fc8b3b9a1e18e3b"></ass开发者_Python百科emblyIdentity>
    </dependentAssembly>
  </dependency>
</assembly>

So my dll depends on 2 different versions of the CRT assemblies. How can I know what causes this double dependency and correct this? I would like my dll to bind to the original version of the assembly as it is the default behaviour for vc9.0.

My code does not contain any define stating to bind to a specific assembly version as

#define _BIND_TO_CURRENT_CRT_VERSION 1
#define _BIND_TO_CURRENT_ATL_VERSION 1
#define _BIND_TO_CURRENT_MFC_VERSION 1
#define _BIND_TO_CURRENT_OPENMP_VERSION 1

or

#define _BIND_TO_CURRENT_VCLIBS_VERSION 1;

as desribied on the msdn website here

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号