c++ - Visual Studio Solution: static or shared projects? -


When a complete project (solution) contains multiple sub projects (.vcproj), a better way to tie them What happens: As a stable library or shared library?

Considering that all those projects have not been used elsewhere, the shared library approach should not reduce memory usage or load time.

The interface building on Dynamic Dynamically Loaded Libraries is very difficult in C ++ on Windows. Client = "text-post" itemprop = "text">

Opinion: Static in almost all cases. For example, unlike Unix shared objects, you can not have a standard singleton for all modules, because in DLL it will be a set of static variables.

Object-oriented interfaces are often difficult to export from DLL.

For load time, issues like ribing should be included with shared libraries.

On the other hand, the libraries you do not share today can be shared in the future. However, in most cases it is better to pay the price of duplication in RAM or disc image compared to the price of dependence on this additional module.


Comments