When using .a files, do I have to distribute the .cpp files with it or just the .h files?
For example, I wrote a large amount of classes and compiled all the code into .o files. I then archived the .o files into .a files.
When I attempt to use the .a files with the .h files in other projects, it requires me to have the .cpp file sometimes.
For some of the headers, it doesn't ask me for the .cpp files but for stuff like sockets it gives undefined references to impl_shutdown unless I include the .cpp file.
This happens even though I link all necessary libs.
Why? What are .o/.a files really and why do I need to distribute the .cpp files with it? Libraries like Zlib and LibPng don't seem to have to distribute anything but the .h and the .a files.