Open LuisJohnsonALR opened 1 month ago
Thanks for the question! I think you got the correct impression - at one point I got it working behind the "sdl3" comptime flag but it's not being kept up to date and there's no build integration.
I think that adding build integration for prebuilt sdl3 should be easy - a build.zig -Dsdl3 flag that changes what installed sdl library we look for. Probably we should not try to compile sdl3 ourselves (we just got sdl2 working in that way).
Does that sound like something you could try making a PR for?
Hey,
Thanks so much for the explanation! That’s more or less what I expected, and it doesn’t sound too difficult to implement. I'm pretty new to this area of programming and not too familiar with SDL3 just yet - I actually just made my GitHub account yesterday so I could ask this question!
I’m still learning about things like Pull Requests, but I’ll see if I can wrap my head around how to approach this. Thanks again for your reply and for all the work you and the contributors have put into this project - it’s really impressive!
One quick question: does this mean we should rely on an SDL3 runtime installed on the system, or is that requirement only for the build process?
Best, Luis
Awesome - welcome! It can be intimidating when starting, so please ask questions when you get stuck.
Yes - I think to start we should rely on SDL3 runtime. I'd suggest starting by just hacking build.zig:
if (b.systemIntegrationOption("sdl2", .{})) {
backend_mod.linkSystemLibrary("SDL2", .{}
replacing sdl2 and SDL2 with sdl3 and SDL3 (and also setting sdl3=true in sdl_backend) and trying to get that to work on your machine. Once something is working you can worry about making a Pull Request, or just post the changes you needed.
SDL3 is not even out yet! It is in development. Shouldn't we wait for them to release something first?
It's a good point, but especially in zig land, working on top of still-under-development software seems like the norm. I think it's entirely up to @LuisJohnsonALR and how much they are willing to deal with sdl3 churn.
Can't complain too much - dvui is still pretty raw.
Hey, I just wanted to check in on the status of the SDL3 backend. I noticed a few bits and pieces in the SDL backend file, but it doesn’t seem fully implemented yet. Is SDL3 still on the to-do list, or is it something that’s not being focused on right now?
No rush or pressure at all - I totally get this is a project done in your free time! I’m just asking because I’m planning to use SDL3 for my project, and it would be super helpful if it were supported.
Thanks a lot, and best wishes, Luis Johnson