2 ms·
I know that the header-only C and C++ libraries have been catching on for years now, but I don't feel like the trade-offs are meaningful enough for me personall
by andrewmcwatters 4y ago
I know that the header-only C and C++ libraries have been catching on for years now, but I don't feel like the trade-offs are meaningful enough for me personally.
I already do something that some people seem to frown upon, which is ship the exact source code of the dependencies that my projects use when writing in C or C++, thus "pinning" them, so that I know you're able to build out of the box without having to download all n number of dependencies, set up their paths, etc. And also, so I know that the dependencies don't disappear, which for some projects I've worked on, they have. And the entire site they came from.
It's also not how I understand the intention of either language. Implementation in .c and .cpp files, interfaces in headers.
- ranger_danger 4y agoUnfortunately you can't please everyone, but I think your approach is the safer one, and it's ok to put your foot down, it's your project after all. The people who would care so much about external dependencies may not be the ones you want on your side anyways. The only middle ground I can even think of would be something like using git submodule/subtree/subrepo where the user can choose to either not even clone those parts (or somehow exclude them altogether) in order to use the system libs, or be able to update the dependencies themselves if they don't want to stay on your known-working versions.
- deterministic 4y agoYour approach makes a lot of sense. I wish more people would do that.