Using same library for linking to two separate dlls which have same source but different dependencies.

  • Thread starter Thread starter DevNeo
  • Start date Start date
D

DevNeo

Guest
I have a complex problem. I have dll A which links with dll B using B.lib. Now I need to build two version of B using different dependencies. One version of B will depend on dll C and the other on dll D. Now can I use a lib from one of the versions of dll B to build A.

A -> depends on B (so I have to link using B.lib)

There are two versions of B

1. B.dll and B.lib built using C.lib

2. B.dll and B.lib built using D.lib

These B dlls are in two separate directories.

Is it possible for me to link A with one of the libs of B and in runtime load the appropriate B dll at runtime by setting the right folder to $PATH variable? Will this be stable and acceptable?

Continue reading...
 
Back
Top