Hello all. I was trying to mess around with clay using raylib as a backend (with a recent version of zig: zig-linux-x86_64-0.14.0-dev.3237+ddff1fa4c) and I’m running into a build error using the basic recommendations of clay-zig and raylib-zig: defineCMacro() (which is an integral part of the raylib-zig build process) seems to be missing! I’ve grepped for it in my local zig std library, and it only exists in Build.Step.TranslateC.
All the calls in the raylib-zig build.zig (e.g. raylib.defineCMacro(options.opengl_version.toCMacroStr(), null);
etc…) just fail with an error that raylib has no such member function in Build.Step.Compile
Am I just doing something particularly stupid or is this a real change? If so, is this change going to break like every package on allyourcodebase?
Thanks for the pointer! I guess I should have been paying closer attention to the changes in the build system… Also, that’s a lot of recursive-dependency-breaking-changes coming soon! The perils of pre-1.0 software development I suppose…
However, when i executed this zig command, and attempt to build the project I still receive:
.cache/zig/p/1220d93782859726c2c46a05450615b7edfc82b7319daac50cbc7c3345d660b022d7/build.zig:170:15: error: no field or member function named 'defineCMacro' in 'Build.Step.Compile'
raylib.defineCMacro(options.opengl_version.toCMacroStr(), null);
~~~~~~^~~~~~~~~~~~~
/usr/local/bin/lib/std/Build/Step/Compile.zig:1:1: note: struct declared here
const builtin = @import("builtin");
I assume you are using the raylib-zig project, as @bunxen said, they are using a local copy of the project so they were able to update the dependencies of their copy of raylib-zig, until raylib-zig update it themselves you will either have to wait or use raylib directly
I just found out, raylib-zig has a branch for raylib 5.6 and zig 0.14dev, you could try using that as a dependency : GitHub - Not-Nik/raylib-zig at 5.6-dev