▲ 23 points
back
12 comments
I recently threw together a hello-world clib package and a project which depends on it in order to familiarize myself with how to use it:
I don't know if this is it, but C (and C++) desperately needs a good package manager if it is to be used and continue to be used for more then a relative few "core" projects.
Java became very successful in OSS due to Maven (or perhaps the other way around...in any case, it is essential to the large, high quality OSS community today). Similarly with Node.js and npm.
Something seems a bit odd in this repo.
Should https://github.com/clibs/clib/blob/master/deps/fs/fs.c#L145-... not be using stat and not seek?
fseek() is portable.
The hardest part about using languages like C/C++ is people don't share. Everything seems to be a commercial offering. I'm not proposing that as right or wrong, just the way it seemed to be at the time.
I don't know, there's quite a bit of sharing, I think a large part is that bringing in a third party library tends to be a total pain, which silos code quite a bit. In my experience, excluding header-only libraries, you usually end up spending about half a day screwing with the build system to get a library entirely integrated if your build system is moderately complex (and it will be if you're cross platform). Most of it just has to do with the design of the language(s) -- linking is very complicated, there's a lack of a good module system, conventions range wildly, compiler support for modern things tends to be uneven, etc.
I think something that might make this project a bit more interesting would be an integration with CMake, which is becoming pretty ubiquitous.
I think part of this is because C naturally lends itself to a DIY philosophy. Part of the point of C is the ability to choose the specific details, it's very much opposed to the "do it for me, I don't care what data structures you use" attitude so integral to things like npm.
Linux is written in C, Boost is C++.
I'm using their hash and list in my project. Works fine.
How do you manage updates?
Why?
> From my experience C libraries are scattered all over the web and discovery is relatively poor. The footprint of these libraries is usually quite large and unfocused. The goal of clibs is to provide stand-alone "micro" C libraries for developers to quickly install without coupling to large frameworks.