If you plan on being able to update the DLL/so without changing the application (which is in theory possible) the inline functions cause a problem because they would be compiled straight into the application requiring an application rebuild rather than a simple DLL rebuild and redistribute. Our company coding standards suggest caution when using inline functions with classes in a DLL or shared library. You do have to make sure you export everything from the DLL correctly or you would get linker errors (unresolved symbols) but that isn't terribly surprising not the blanket of doom I initially implied. While I was sure I had heard of problems involving DLLs and static class data I can find no backing for this statement. Sorry I thought I had better come back and explain myself. lib extension usually) is a binary file which alsocontains functions and variables like DLL, but resolved at compile-time, meaning they need to be provided at link-time.ĭynamic and static libraries are often provided together with header file (but no source file, which contains the implementation) when the provider lets you use his/her functions/services but doesnt give you access to the implementation. The DLL file is automatically loaded (by system) at run-time when your executable program invokes functions and asks for resources.Ī library file (also called static library, with. In order to use a DLL you need to include the corresponding header file, which declares things in the DLL, so that your program gets compiled. and can be linked to your program at run-time.
extentions), containing functions, resources. h or hpp extension.Ī DLL (dynamically linked library) is a binary file (with. A header file contains declaration of something (constants, classes.