Question: what is the difference between using static or shared in add_library?
Answer: Shared libraries are added during linking process when executable file and libraries are added to the memory. Static libraries are much bigger in size, because external programs are built in the executable file. ... It is faster because shared library code is already in the memory.