News for hackers. Stuff that matters.
Re:Mio – Cross-platform header-only C++11 library for memory... by orbifold on Saturday October 20, 2018 @01:39PM (#18264395)
Yes because there is no standardised build system for C++, which makes integrating non-header only libraries a pain (or at least somewhat more painful), especially if your aim is cross platform code. In that case you can not rely on a reasonable package manager being present and will have to essentially include all your dependencies in the build, this is trivial for header only libraries.
Re:Mio – Cross-platform header-only C++11 library for memory... by asveikau on Sunday October 21, 2018 @11:14AM (#18268402)
Overstated problem. It's not that hard under most circumstances to build a static lib.

I think there are two issues. In C++, a header only library makes sense due to templates, which don't produce object code before specialization. In C, I have seen the same with entirely macro-based "libraries" that are really simulating templates in order to make abstract data structures.

The second case though, my theory is that there is a new generation of programmers who don't understand the traditional compile and link phases because they are used to other languages. It doesn't fit their expectation of how it should work so they bend the tool to their expectation instead of figuring out the old way. The very fact that people on here are saying a programming language should have a "standard package manager" demonstrates the cultural divide: this sounds a little nutty to an old time C person.

Re:Mio – Cross-platform header-only C++11 library for memory... by anonknowsaguy on Monday October 22, 2018 @08:57AM (#18274220)
As newer generation C++ programmer, can confirm I'm guilty of writing things header only when they "probably shouldn't be". But it's not so much I don't understand the old way. Having everything in one file is just so much easier to work with. The price you pay for it is relatively low(for small projects like this library).
Re:Mio – Cross-platform header-only C++11 library for memory... by StreamBright on Saturday October 20, 2018 @02:32PM (#18264699)
Is there a reason not to have a standard build system?
Re:Mio – Cross-platform header-only C++11 library for memory... by twic on Saturday October 20, 2018 @03:19PM (#18264924)
There's no reason not to have one, but there isn't one. There are a few build systems for C++, but none of them are perfect, and none has won out.
Re:Mio – Cross-platform header-only C++11 library for memory... by tom_ on Saturday October 20, 2018 @02:58PM (#18264843)
No consensus on how it should work, and the standard anyway deals with the runtime environment rather than the tooling.