Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Additional Manifest Dependencies?

3 views
Skip to first unread message

S. Heck

unread,
Dec 4, 2008, 9:37:01 AM12/4/08
to
I am getting the following application error after moving to VC++ 2008 SP1
from VC++ 2008.

The application failed to initialize properly (xc0150002).

I need to be able to run my application without installing the VC++ 2008 SP1
Redist package or using an installer. I placed the redist libraries and
manifests in the same folder as my application files. This worked fine with
VC++ 2008.

With VC++ 2008 SP1 it appears that the policy files that are installed by
VC++ 2008 SP1 Redist package are required (see example below). It appears
that bindingRedirect is needed for VC++ 2008 SP1. Is there a way to input
this via Additional Manifest Dependencies or some other method? As I
mentioned I can't use a installer or the VC++ 2008 SP1 Redist package.

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!-- Copyright (c) Microsoft Corporation. All rights reserved. -->
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<assemblyIdentity type="win32-policy"
name="policy.9.0.Microsoft.VC90.MFCLOC" version="9.0.30729.1"
processorArchitecture="x86" publicKeyToken="1fc8b3b9a1e18e3b"/>
<dependency>
<dependentAssembly>
<assemblyIdentity type="win32" name="Microsoft.VC90.MFCLOC"
processorArchitecture="x86" publicKeyToken="1fc8b3b9a1e18e3b"/>
<bindingRedirect oldVersion="9.0.20718.0-9.0.21022.8"
newVersion="9.0.30729.1"/>
<bindingRedirect oldVersion="9.0.30201.0-9.0.30729.1"
newVersion="9.0.30729.1"/>
</dependentAssembly>
</dependency>
</assembly>

Thanks!

David Connet

unread,
Dec 4, 2008, 11:17:22 AM12/4/08
to
=?Utf-8?B?Uy4gSGVjaw==?= <SH...@discussions.microsoft.com> wrote in
news:D18FC407-8AD7-4F1A...@microsoft.com:


The magic incantation you need is to define
_BIND_TO_CURRENT_VCLIBS_VERSION. You need to define this in all modules
are are compiled. (You'll know if you were successful when the "21022"
reference goes away)

Dave Connet
(Been there, lost some hair)

S. Heck

unread,
Dec 4, 2008, 2:31:00 PM12/4/08
to
Hello David,

Thank you for the reply and information.

Should I add

_BIND_TO_CURRENT_VCLIBS_VERSION=1

in Preprocessor Definitions?

Thanks!

S. Heck

unread,
Dec 4, 2008, 2:33:01 PM12/4/08
to

Hello David,

Thank you for the reply and information.

Should I add

_BIND_TO_CURRENT_VCLIBS_VERSION=1

in Preprocessor Definitions?

Thanks!

David Connet

unread,
Dec 5, 2008, 9:51:35 AM12/5/08
to
=?Utf-8?B?Uy4gSGVjaw==?= <SH...@discussions.microsoft.com> wrote in
news:2FC1B103-FB85-4C36...@microsoft.com:

> Hello David,
>
> Thank you for the reply and information.
>
> Should I add
>
> _BIND_TO_CURRENT_VCLIBS_VERSION=1
>
> in Preprocessor Definitions?
>
> Thanks!

That's usually how I do it. I have also set it in my stdafx.h file. The
drawback to that is when you include code that does not include that header
(and set the properties of that file to not use precompiled), things break
again. (Some of my projects include some old .c files)

Since I use properties in my VC9 builds, I actually set it in the
preprocessor settings of my lowest property (I name that one
'Common.vsprops') Using properties helps maintain settings across multiple
projects - makes life much easier when you have many projects in a single
solution! (I then have release/debug properties - those include 'Common'.)

Dave

S. Heck

unread,
Dec 6, 2008, 1:04:03 PM12/6/08
to
Thank you for the follow-up information.

I hope what I am trying to do is possible with VS 2008 SP1. As I mention
prior to SP1 I could run with run time libraries and manifests in the same
folder. I didn't need to install anything else. Because of the nature of
the product it needs to run without installing the run times on the end user
machine.

I am using third party dlls so this has complicated the situation. All I
can say is this change has caused me a lot of time and grief.

-Steve

0 new messages