Package management is a tough thing to tackle.. since practically everything about C is against it (no module system, only absolute #include), leading to the current situation of having hundreds of build tools..
I have a few ideas on how to go about this, but I don't think it's worth going for until I legitimately have to create a C-project to experiment with the best way to do this.
I think the simplest method would be having separate types of "packages", most simple type being essentially just cloning a project's source code to /target/, symlinking to vendor, then user refers to the package from there. Dealing with other cpkg projects should also just be symlinking. Shared library dependencies should also be a thing, shouldn't be too hard, just passing an extra argument to the compiler.
Package management is a tough thing to tackle.. since practically everything about C is against it (no module system, only absolute
#include
), leading to the current situation of having hundreds of build tools..I have a few ideas on how to go about this, but I don't think it's worth going for until I legitimately have to create a C-project to experiment with the best way to do this.
I think the simplest method would be having separate types of "packages", most simple type being essentially just cloning a project's source code to
/target/
, symlinking to vendor, then user refers to the package from there. Dealing with othercpkg
projects should also just be symlinking. Shared library dependencies should also be a thing, shouldn't be too hard, just passing an extra argument to the compiler.