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

Add build.zig #377

Draft
wants to merge 2 commits into
base: v0_master
Choose a base branch
from
Draft

Add build.zig #377

wants to merge 2 commits into from

Conversation

iacore
Copy link
Contributor

@iacore iacore commented Nov 25, 2023

This will make this repo a Zig package.

TODO

  • configurable -DXXXX

@vnmakarov
Copy link
Owner

I am not well familiar with ZIG (I only read common description of the language and I liked it). I have no time check that this will build mir by zig but I trust you and I am not against to include this PR into repository if/when you finish this.

@iacore
Copy link
Contributor Author

iacore commented Nov 29, 2023

As of Zig 0.11.0, putting build.zig in this repo is not much useful.

I noticed that when building libmir.a, c2mir/c2mir.c is also included. Why is the file included?

Also, MIR relies on way too much C UB. (this is not a problem in practice.) If you build the project with $CC -fsanitize=undefined you will see where relies on UB.

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.

2 participants