I'd appreciate any advice that could point me in the direction of
solving this problem.

 

With my project settings as they are, if I build the dll and the
installer, the installer will fail with the usual premature termination
error, because my dll failed to load.

 

I started working from a template I found online, so I may have been
following bad practices.

 

I'm compiling with /MT and have the following lines in my source

#pragma comment(lib,"msi.lib")

#pragma comment(lib,"shlwapi.lib")

#pragma comment(lib,"libcmt.lib")

#pragma comment(lib,"dutil.lib")

#pragma comment(lib,"advapi32.lib")

#pragma comment(lib,"wcautil.lib")

 

If I add this line

#pragma comment(lib,"msvcrt.lib")

Before the libcmt line, I get the warning LNK4098: defaultlib
'libcmt.lib' conflicts with use of other libs

 

That makes sense to me, because from what I understand, msvcrt is the
dynamic multi-threaded library, and libcmt is the static one.  The dll
that results from having that line added is much smaller, which makes me
believe its now dynamically linking dispite the /MT flag.

 

The part I'm having trouble understanding is that with msvcrt.lib, the
installer works (on systems where the runtime is installed), but without
it, the installer dies un able to run the dll code.  

 

I'm assuming its either an issue with the project properties and/or my
use of those #pragma directives, but I'm not sure how to proceed.

Any ideas? (Obvious ones included :-) )

 

________________________________

From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
[EMAIL PROTECTED]
Sent: Tuesday, May 15, 2007 11:34 AM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]; WiX-users@lists.sourceforge.net
Subject: Re: [WiX-users] CustomAction = .VC Runtime Dependency?

 

So now's the time to add logging or even a MessageBox call to verify
that the function is now being loaded and executed.

 

Based on everything I've learned to this point, all signs point to
something wrong in how I built the dll.

 

I have logging throughout the dll already, and the project settings are
all that changed (it was semi-working before.)

 

In the past these "executing action failed" errors have meant a missing
dependency.  My tendency here is to suspect I have mismatched libraries
or something along those lines, though I've got nothing to base that on.

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to