How to Herd 1,000 Libraries - Robert Schumacher - CppCon 2019
Вставка
- Опубліковано 26 сер 2024
- CppCon.org
Discussion & Comments: / cpp
Presentation Slides, PDFs, Source Code and other presenter materials are available at: github.com/Cpp...
-
How to Herd 1,000 Libraries
In the current C++ world, it is a struggle to convince even a single external library to build and behave. Adding a third and fourth dependency causes quadratic grief as each library interacts with each other and One Definition Rule violations lurk around every corner.
How, then, is it possible to manage over 1,000?
In this talk, we'll talk about the techniques, shims, and hacks used in the Vcpkg package manager to persuade, connive, and coerce all these independent moving parts into a single robust ecosystem. We'll sample the myriad approaches used by real-world libraries to declare dependence and walk through how they can be guided to do the right thing at the end of the day.
Private package management systems still thrive in corporations and these approaches can provide method to the madness of consuming open source.
-
Robert Schumacher
-
Videos Filmed & Edited by Bash Films: www.BashFilms.com
*-----*
Register Now For CppCon 2022: cppcon.org/reg...
*-----* - Наука та технологія
Very informative talk, thank you.
Also, am I the only one who thinks Robert looks like Jason Turner?
What? Not at all, no ^^ but both are highly knowledgable :)
First of all cudos for the talk and the blood sweat and tears that you put into your work. About the broken diamond problem ...
I have thought about this too and I have come to the conclusion that the build-system for a scalable many-dependency code-base must be able to support multiple co-existing versions for each library. If you do not allow this you have to update the whole world in one step which is more or less like having all libraries in one single repository at one single version. This is not practical. By allowing multi-version dependencies you can update one after the other in small steps.
With this solution large dependency trees will probably get messy because they contain each library in multiple versions, but maybe this problem could be mitigated by having libraries specify multiple versions on which they can depend and an additional tool that will then search in that "multi dimensional dependency tree" for the one that has the lowest library-duplication.
The problem is, that as far as I know, CMake does not support having one library in multiple versions in your project. Maybe the behavior could be improvised by embedding the version into the target name but this leads to a lot of other problems, so I feel that it should really be the build-system's job to support this.
Do you know if anybody else has come to this conclusion and if so if there is any work beeing done to solve this?