4 ms·
This is one of the reasons that header-only libraries have become quite popular. They're easy to deal with: just add to your include path and you're ready to go
by dkersten 6y ago
This is one of the reasons that header-only libraries have become quite popular. They're easy to deal with: just add to your include path and you're ready to go.
I put off starting a C++ project I've wanted to start for months because I couldn't bring myself to dealing with the dumpster fire known as CMake, and I now try to limit myself to projects I can do that only require header only libraries, if possible (and use tup [1] to build, since its simple). Since I only really do C++ for fun these days, that's worked out ok.
[1] http://gittup.org/tup/ http://gittup.org/tup/
- skywal_l 6y agoDidn't know tup. Seems to be Makefile done right. (at least at first glance...)
- int_19h 6y agoTake a look at DJB Redo, as well. There are many implementations, so here's a well-documented one: https://redo.readthedocs.io/en/latest/ https://redo.readthedocs.io/en/latest/
- dkersten 6y agoI haven't used it for anything particularly complex and I haven't used it with anything that has a ton of non-header-only third party libraries, so I don't know how it holds up in those cases, but for my smaller projects, its been really pleasant. The tupfiles are easy to write and the tool is super fast. It took me from dreading starting a new project with cmake to enjoying using C++ again. I used to just use QtCreator and let it setup the build system. I could just go back to that, but for now I'm very happy with tup.
- pjmlp 6y agoThe reason is called laziness and unwilling to learn how things work. If I as a 80's high school student was able to manage how to deal with dependencies in MS-DOS world, with several commercial compilers, in age where information came only on books and magazines, so can anyone on the Internet age learn how to do it. I will avoid them as much as possible.
- dkersten 6y agoI disagree. CMake is a freaking mess, but its won, so most non-header-only libraries are setup for CMake. I've tried to learn CMake a number of times and have written non-trivial CMake configs. I spent a lot of time on it that I could have spent on my actual project instead and in the end it was still not quite right (breaking after moving to a different system and trying to compile there). I made multiple attempts to try and learn how to do it and failed. So I gave up, I have better (more fun, more productive) things to spend my time on. Life is too short to waste on such things.