10-20-2009 05:20 AM
I have 2 dlls built whit LabWindows and I want to compare them, is it possible ?
Thanks for your help
10-20-2009 01:40 PM - edited 10-20-2009 01:49 PM
You could:
1. Simply roll the cursor over the .dll file or view the .dll file properties to see the version of the dll. If the dll was built to include version info (and you can do this with CVI) then you can compare versions.
2. If version info isn't there, compare sizes and dates or use a binary file viewer (e.g. HexEdit) to inspect the DLL 's and see if they're the same binary.
3. If you have access to each dll's header file, see if they are the same - were any functions added or changed or deleted. Even if all of the functions have the same signature, the dll's could be different, however.
4. Use a DLL viewer to see the exported functions and their addresses. If they differ, then the DLL's aren't the same ...
5. Look here for Microsoft tools for comparing DLL's http://support.microsoft.com/kb/247957/
Menchar
10-20-2009 02:03 PM
Or use the dependency walker tool, Depends.exe, which is included in Visual Studio. You can load a DLL into it and it will tell you the included functions, how they were exported, entry point addresses, function ordnial, and list any other DLL's that it depends on.
Menchar
10-21-2009 12:51 AM
it's really diffcult to compare the dll's when they have same export functions.
however, this is really a good questions. how to compare the DLL. i am expecting to have a situable answer. 🙂
B.R
Gerry
10-21-2009 04:32 AM
Hi gerry,
I think the two previous posts are quite complete.
What else do you need?
Olivier L. | Certified LabVIEW Developer
10-21-2009 06:11 AM - edited 10-21-2009 06:13 AM
Comparing the files in hex editor may be misleading.
I remember a message in this forum that complains about 2 successively (without any change in code) built binaries being different from each other (at byte level, not in functionality).
And it was not just the version and date information.
10-21-2009 11:26 AM
Sure, many compilers put a time stamp for example into the binary that will result in a different object file on recompilation of the same source.
And I do recall someone saying the CVI (i.e. LCC) compiler does that.
So if the question is, "Can I build two versions of the same DLL using CVI that are very difficult to compare for identical functionality" then the answer is yes 😉
You could do a regression test - use a client executable to call each of the functions in each of the DLL's and see if they act the same way per the specification of the functions.
Maybe the best answer going forward is to use the versioning capability for DLL's that CVI provides.
MEnchar