-
Notifications
You must be signed in to change notification settings - Fork 49
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
Linux: build on newer GCC and Clang releases, silence compiler warnings #216
base: v2.57
Are you sure you want to change the base?
Conversation
I cloned your v2.57-new branch and I'm trying to build with gcc version 14.2.0 (GCC) but it fail at the codegenv2.c file.
Your branch builds with gcc version 13.2.0 but here the error messages are just warnings. |
I didn't change those parts in codegenv2.c. But I can try to fix that and get it to work on different versions of gcc and clang. |
Try building with GCC 14.2. |
It now builds on GCC 14 and Clang 18. |
Yes now it can be built.
There are only 8 warnings left. |
Line 1041 in 540d215
Line 1042 in 540d215
Produces the first warning from those exposed in the previous post (warnings.txt). Could it be used? if ( (intptr_t)curr->sym.altname > 1 )
https://stackoverflow.com/questions/22624737/casting-a-pointer-to-an-int If it is a viable solution can it be used to resolve all remaining warnings? |
Some of the Linux test files in Maybe you just have to stick to an old version of GCC to compile uasm? |
It might be a good start for fixing the (lots of) compilation warnings that have been there since I used it! |
I have built 7-Zip 24.08 using GCC version 14.2.0 + UASM with all the patches without any errors.
|
I've tested it with the 7zip sources and both the patched and unpatched UASM produce exactly the same output. |
Correct! But the unpatched version does not compile in GCC 14.2.0! |
…discards-qualifiers
Still some errors when making with
|
Debug build should work now. |
Got rid of the |
I've tried to fix some of the GCC compiler warnings on Linux. I've also silenced
-Wdiscarded-qualifiers
as there are way too many warnings, since the code doesn't seem to distinguish much betweenconst char
andchar
arrays.By the way, I wish there was a
make test
Makefile target.Here are the warnings from the unpatched sources (without qualifiers warnings):
https://gist.github.com/darealshinji/25fa279e5d765d78a006fc3180e9e2fb