-
Notifications
You must be signed in to change notification settings - Fork 76
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
build: misc changes #111
build: misc changes #111
Conversation
mochaaP
commented
Jan 2, 2025
- move subproject to root, install docs if not a subproject
- only add warning flags if compiler supports them
f65b1cc
to
04bfa17
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's OK to remove cmake.yml - not needed for ci, but the CMakeLists.txt may still be useful to be able to build with TinyC for development (up to 10x compilation speed). Meson does not support TinyC. I will modify CMakeList.txt to make it work.
rebasing this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have moved the typeof test to common.h (see usage in coroutine.h), and made it overridable, i.e. -DSTC_HAS_TYPEOF=0
The fine grained test for typeof is not needed. I don't think __typeof__
can be disabled if supported, i.e. even with -std=c99 -Wpedantic, __typeof__
is awailable, but not typeof
.
25e8aca
to
9e31c20
Compare
i believe it is possible to disable |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's very useful to have meson build multiple target platforms, but I'm a bit unsure if all these sanitizer combinations are needed? E.g. I would think clang sanitizers works equally across the platforms, so one instance should in principle be enough to catch memory and other bugs in the code. Additional MSVC and GCC sanitizers are useful because they may work slightly differently.
PS. could you add so that also the example programs are executed at least for the santized builds?
I think the example programs are already added to the tests. I reviewed all sanitizer setups, and they should have different codegen behaviors (different optimization levels, different compilers, and specifically windows because windows being windows ¯\_(ツ)_/¯) |
btw, about TCC: There is https://sr.ht/~lattis/muon/ which supports tcc out of the box. |
No, it also works with -ansi, but it's irrelevant because -ansi is equal to -std=c90 in C mode and STC requires C99. I tried gcc 3.4.5 and clang 3.0.0 up to the newest with -std=c99 -pedantic and they all support I will accept the PR but will modify common.h. |
removed that |