Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Visual Studio.NET / General / July 2007

Tip: Looking for answers? Try searching our database.

Manifest Hell

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
David - 18 Jul 2007 17:36 GMT
Visual Studio 2005 appears to be generating bad manifests for a couple of my
applications. In both cases, it's spitting out the same manifest, which I've
pasted below.

The first problem is that it is calling for two different versions of ATL.
The second is that it's calling for the wrong version of CRT. When I run the
apps on a vanilla XP/SP2 box, they fail to load.

My code includes <atlstr.h> and uses ATL::CString, and I'm also linking with
some 3rd party libraries, but I have "Not using ATL" selected in the project
settings, and the dependency walker doesn't show a dependency on ATL.

Dependency walker does show a dependency on MSVCR80.DLL, but it's via
RAPI.DLL which is delay loaded. In addition, on my machine, it resolves that
dependency to a DLL with version 8.0.50727.762, not 8.0.50608.0.

From what I've been able to learn, VS2005 builds the manifest by looking at
the link. So it appears that something on my machine is pooched.

I've searched my computer for MSVCR80.DLL amd ATL80.DLL, and all accessible
copies are version 8.0.50727.762. None are 8.0.50608.0. I don't know where
VS2005 is coming up with this version. It doesn't show up in my winsxs folder
either.

For the time being, I've simply turned off manifest generation, but I'm not
sure that's the ideal solution (or is it?).

Any advice on what's going on, and how to proceed, would be greatly
appreciated!

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
 <dependency>
   <dependentAssembly>
     <assemblyIdentity type="win32" name="Microsoft.VC80.CRT"
version="8.0.50608.0" processorArchitecture="x86"
publicKeyToken="1fc8b3b9a1e18e3b"></assemblyIdentity>
   </dependentAssembly>
 </dependency>
 <dependency>
   <dependentAssembly>
     <assemblyIdentity type="win32" name="Microsoft.VC80.ATL"
version="8.0.50608.0" processorArchitecture="x86"
publicKeyToken="1fc8b3b9a1e18e3b"></assemblyIdentity>
   </dependentAssembly>
 </dependency>
 <dependency>
   <dependentAssembly>
     <assemblyIdentity type="win32" name="Microsoft.VC80.ATL"
version="8.0.50727.762" processorArchitecture="x86"
publicKeyToken="1fc8b3b9a1e18e3b"></assemblyIdentity>
   </dependentAssembly>
 </dependency>
</assembly>

--
David
Phil Wilson - 18 Jul 2007 18:31 GMT
I've seen this before, and I think the 50608 version is related to the Debug
version of the CRT.

In any event, it shouldn't matter because a correct deployment of the CRT
installs a policy intoWinsxs with the redirect below so everything should
just work, including your 50608, because the policy redirects to the latest
installed CRT. ATL etc have similar behaviour. I don't know if
dependencywalker takes account of policies. So the issue might be related to
how you've deployed the CRT.

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!-- Copyright © 1981-2001 Microsoft Corporation -->
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">

   <assemblyIdentity type="win32-policy"
name="policy.8.0.Microsoft.VC80.CRT" version="8.0.50727.762"
processorArchitecture="x86" publicKeyToken="1fc8b3b9a1e18e3b"/>
   <dependency>
       <dependentAssembly>
           <assemblyIdentity type="win32" name="Microsoft.VC80.CRT"
processorArchitecture="x86" publicKeyToken="1fc8b3b9a1e18e3b"/>
           <bindingRedirect oldVersion="8.0.41204.256-8.0.50608.0"
newVersion="8.0.50727.762"/>
            <bindingRedirect oldVersion="8.0.50727.42-8.0.50727.762"
newVersion="8.0.50727.762"/>
       </dependentAssembly>
   </dependency>

</assembly>

Signature

Phil Wilson
[Microsoft MVP Windows Installer]

> Visual Studio 2005 appears to be generating bad manifests for a couple of
> my
[quoted text clipped - 63 lines]
> --
> David
David - 18 Jul 2007 20:20 GMT
The problem occurs on machines that don't have the latest CRT installed.

And I wasn't planning to deploy the CRT at all, since my code is not
actually dependent on it (at least according to Dependency Walker).

I tried including the "redist" dlls and manifests in my app's folder, but
that didn't work (since they don't include the redirects). Doing a full CRT
update on the end-user's system is not feasable.

> I've seen this before, and I think the 50608 version is related to the Debug
> version of the CRT.

I've looked through a load map, but can find no trace of any references to
the debug CRT. But one of the libraries I use does bring in LIBC.LIB, while
my app uses LIBCMT.LIB. I use /NODEFAULTLIB to get rid of LIBC.LIB. I wonder
if this trips up the manifest generator?

I think my solution is going to be to simply not ship a manifest, or
possibly to embed my own (if that's possible).

Regards,
David
Phil Wilson - 24 Jul 2007 01:18 GMT
I've seen 50608 in the manifest in the debug folder and a different version
in the release folder. I'm referring to the text in the manifest, not any
load map stuff.

> I tried including the "redist" dlls and manifests in my app's folder, but
> that didn't work (since they don't include the redirects). Doing a full
> CRT
> update on the end-user's system is not feasable.

There's nothing about putting files in a redist folder that just makes all
this work.

The manifest seems ok to me, or at least understandable. There are a range
of versions that the project has used, maybe because when you started the
project you were in Debug mode and it generated 50608, later it added 50727
762 (the VS 2005 SP1 version). It's possible that there's nothing wrong with
a manifest that has a range of versions.

Delayload doesn't mean it won't ever require it, as you probably know.

If your app works without a manifest, is there actually an issue other than
the manifest content?

Signature

Phil Wilson
[Microsoft MVP Windows Installer]

> The problem occurs on machines that don't have the latest CRT installed.
>
[quoted text clipped - 22 lines]
> Regards,
> David
Gary G. Little - 19 Jul 2007 03:09 GMT
Have you applied the 2005 SP1?

Gary G. Little

> Visual Studio 2005 appears to be generating bad manifests for a couple of
> my
[quoted text clipped - 63 lines]
> --
> David

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.