Say I have one executable: app.exe
I use 2 different 3rd party DLLs in this executable: foo.dll bar.dll and the Application must l
Here's an idea: How about marking them as "Delay Loaded dlls" in the linker options of app.exe?
Delay-loading will allow you to link "statically" (i.e. without LoadLibrary() et.al) but will not load the DLL and do the linking until it's actually needed.
If that is an option, then (assuming you can wait so long, i.e. do not access foo/bar dll functions before main()), you could, in main(), access a function (just fetch a function ptr or something) in foo.dll first, which would load it and bind all "statically" linked functions?
(Maybe LoadLibrary() triggers the same link-when-needed procedure. Not sure. It would look cleaner in your code though.)