I want to incorporate some open source libraries into my C project. This is the first time I do that, so I don't know what is the right or most common way of doing it.
I see two possible paths I can take:
- Download the code of each library I'll use, add them to my project folder and modify them as I need.
- Just list each library as a dependency. So the user would download them to its machine and include them to the project with (maybe) some makefile configuration.
I think option #1 is better for two reasons:
- I release the user from the task of downloading and configuring the dependency.
- In my project two libraries have overlapping code. Part of one library is a subset of the other. They have the same functionalities and the same identifiers names (variables, functions, #defines). So I would have some conflicts that I don't know how to fix.
But I just think option #1 is better. I really don't know what's the best. Maybe someone knows how to fix the conflicts between the libraries and then my opinion may change. I'm asking this question because I don't know what is the path programmers usually take. I also don't know what are the pros and cons of each alternative. And I also don't know if there are other alternatives.
Update: The expected users are programmers.