I have a bunch of code I am using in multiple projects. Right now, I am doing it by copy-and-paste, which is less than ideal. As I understand it, to have multiple projects refer to the same source code, I have at least two options:
1) Create a static library and include it in multiple projects
2) Create a project with the shared source code, and import that into all of the other projects.
What are the advantages and disadvantages of these approaches? When might I prefer one over the other?