Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix build.zig for Zig 0.13 #135

Merged
merged 1 commit into from
Jul 21, 2024
Merged

Conversation

luchak
Copy link
Contributor

@luchak luchak commented Jul 20, 2024

This change updates build.zig so it works with Zig 0.13 by using the b.path() function to initialize LazyPaths. Apparently specifying paths with struct literals is no longer allowed? Or at least not with these struct literals. This change also adds sokold.cc to a list of sources it was missing from, which was causing a link error.

I'm new to Zig, so it's possible there's a more idiomatic way to do this, but b.path() is what I've seen elsewhere.

I didn't see any tests for the Zig build, so I just smoke tested this change on my Mac: build the binary, run it on a few GLSL files fromtest/, make sure the output looks halfway reasonable.

@floooh
Copy link
Owner

floooh commented Jul 21, 2024

Many thanks! Yes, Builder.path() is the "proper" way to build a LazyPath now.

@floooh floooh merged commit 6d2e673 into floooh:master Jul 21, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants