Closed grjzwaan closed 2 months ago
I'm afraid there's currently no way to customize path to sdl.json
.
You need to create a seperate .build_config/sdl.json
file in jok
directory in order to run examples.
Normally, you can just copy the sdl.json
from your project, everything should just work.
I might add support for grabbing path to sdl.json from environment variable, not 100% sure yet.
Thanks, if I add it to both folders (for sdl and jok) then it builds.
I just started working in Zig, but if I read the code correctly a path to SDL is constructed in joke.createGame
. Perhaps passing this as an optional argument would work on Windows and still work on Linux. I'll try to see if I can make that work locally.
I thought about this way, didn't work for some reason (on linux). Also, it would require modifying examples' build option after first downloaded or updated jok dependency, which is undesirable IMO. Hence the environment variable mentioned above, looks more approachable to me.
Support for getting sdl config path from environment variable has been added. Feel free to create new issue if there's still problem.
I followed the instruction and got the following error on
zig build
This temporary folder contains the sdl.zig dependency.
Any idea how I can influence the place where the install/build script is looking for this JSON? It is properly configured in the project folder.