3 ms·
OK but I don't understand why you would read Ninja files rather than generate them. I think Ninja almost always needs a generator -- it's too low level to writ
by chubot 3y ago
OK but I don't understand why you would read Ninja files rather than generate them.
I think Ninja almost always needs a generator -- it's too low level to write by hand, especially for C/C++ projects.
Meson apparently also generates Ninja, but I haven't used it.
---
I think the main difficulty with builds is solving the "Windows problem", as I wrote in that thread.
Good example of all that from yesterday:
https://lobste.rs/s/hh7wuy/why_scipy_builds_for_python_3_12_on_windows https://lobste.rs/s/hh7wuy/why_scipy_builds_for_python_3_12_...
https://news.ycombinator.com/item?id=38196412 https://news.ycombinator.com/item?id=38196412
Anyone who can solve that problem will be a hero, but I also think no one person can solve that problem.
That is, cross-language / polyglot builds and working with the existing tools from each ecosystem is THE problem. Unfortunately most people seem to think that the language they use is the only one worth solving for.
Our Ninja build handles C++ great, but we also have many shell scripts for one-off Python things, and R things, and JavaScript things, ...
- gavinhoward 3y ago> OK but I don't understand why you would read Ninja files rather than generate them. My build system is self-contained. It doesn't just do the configure; it can also do the build. Also, a feature is being able to treat external builds as part of the same build. For example, if one of your dependencies is a CMake project, it will be able to run the CMake configure as a target, import the targets from the Ninja file, and run those targets as part of the build for your project. It should be able to do the same for Cargo files, Zig build files, etc. That would solve the polyglot issue, minus details, which I'm working hard on. > https://news.ycombinator.com/item?id=38196412 https://news.ycombinator.com/item?id=38196412 I'm not sure why you linked the post we're commenting on... Edit: I'm also solving the Windows problem; my build system is Windows-native, and I have a design for something to build up command-lines based on the compiler in use, including MSVC. Edit 2: I also understand why you question whether anyone can solve the polyglot problem. You are right to question whether I can. If your response is "show me the code," that is rational, and my response would be, "I'm almost there; give me three months." :)