Hacker News new | ask | show | jobs
by beojan 3126 days ago
It really doesn't matter what build system other libraries use. If you use CMake, you just need to use `find_package` directives (https://cmake.org/cmake/help/v3.10/manual/cmake-packages.7.h...) to integrate third party libraries (which should be separately installed in the system).

It only seems difficult if you're stuck in the mentality of shipping all your dependencies with your source code and statically linking everything. C and C++ libraries actually care about maintaining API (and usually ABI) compatibility, so you don't have to ensure you have a specific version of dependencies.

1 comments

Come on, you cannot even link C++ shared libraries from different version of standard library, potentially also compiler. ABI compatibility in C++ does not exist.

In C, you still had incompatibilities between compilers. (MS fastcall convention and declspec come to mind...)

There's better ABI compatibility than in the languages where you have to rebuild after every minor version bump. The C++ standard library version (and to some extent, the compiler) should be considered part of the platform.