Feat: Use Zig for Build System
Tldr: What the title says.
Use the Zig Programming Language to handle building the entirety of this program, and use it in this project for actual development purposes. Zig's build system is impressive and can compile C and C++ applications with minimal hassle. However, the future of Zig and C libraries remains somewhat uncertain, given the current direction of the Zig language, which is removing its LLVM backend for implementation. This will come up after the release of Zig 0.15.0 language.
Instead of using Conan to fetch required dependencies alongside a poorly written Makefile script, we utilize the powerful Zig build system to allow for fetching and building this project.
Many other projects written in C++ and C have already started to incorporate Zig into their build systems, with Neovim incorporating it in order to soon phase out their existing CMake pipeline.
Being able to link libraries and fetch needed libraries is important for the functionality of this project. With regards to how Wayland will progress(and currently works) this could create a strong foundation to start being able to get development going.
I've been learning Zig for the past few weeks now and have loved every moment of it. More recently, I decided to see if I could use LibUSB in a small project as a way to get a feel for how the build system works, and how to include C libraries into a project, and work with them. Without too much hassle I was able to get it working just fine and even to use LibUSB inside of the Zig file.
// literally all I had to do was add this to the build.zig file
exe.linkSystemLibrary("usb-1.0");
exe.linkLibC();
Now there is a lot to cover since this is project that is going to have multiple languages. One thing to think about is how this will scale with languages like Rust and C++ together. This may or may not require more research on my end, but I will start with making a Proof of Concept soon to see how this may function
This would fix #29 because removing our dependency on Conan alongside with its implementation of its Makefile support would make my life easier, also has been something I've been dreading to mess with for a while. Zig, while very new and in its early stages, seems promising in its ability to handle existing C/C++ codebases with minimal issues. Something that surprised me was that Neovim started to incorporate it into its build system on top of the 30-year-old C/C++ code base that they have to deal with already.