CustomAction log name error 0x8007007a in WiX

0

I am currently working on a custom action in a DLL that I export to be used by a WiX installer and I recently discovered the following error in the log when I ran the installer:

<exported_name_cut_off>: Error 0x8007007a: Failed to copy CustomAction log name: <exported_name_NOT_cut_off>

As I am relatively new to Windows programming and Wix, when I noticed the DLL function name was cut off in the error message I immediately thought there must be some limit of 31 characters on exported function names in DLLs, but that apparently is not the case; it turns out that this is a limitation of WiX of which I was unaware.

So, I have two questions here:

  1. Is there a limit on the length of an exported or imported function name in DLLs? I could not find any mention of this in the MSDN help. If it is relevant, I am coding in C++ and using Visual Studio 2010 on Windows 7 x64.

  2. I found this, but unfortunately, there was no good answer given for why there is such a limit in WiX. Does anyone out there know why it is limited in this way? Is it still the case in WiX versions greater than 3.5.2519 (the version I am using)?

windows
dll
installation
wix
naming-conventions
asked on Stack Overflow Oct 11, 2012 by Joe Bane

1 Answer

3

You control the name you pass to WcaInitialize; it doesn't have to be an actual function or custom action name so you can shorten it however you want. The WcaLog* functions use it to prefix your logging so it's not vital; you can even pass NULL if you want.

The limit still exists in WiX v3.6 and v3.7 beta builds.

answered on Stack Overflow Oct 11, 2012 by Bob Arnson

User contributions licensed under CC BY-SA 3.0