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

Remove unused CMake logic and add -Wno-pointer-sign #196

Merged
merged 3 commits into from
Dec 8, 2018

Conversation

no-more-secrets
Copy link
Contributor

There were a series of statements in the CMake file having
to do with controlling warning flags (including adding -Wall)
however they were not actually applied to the CMAKE_C_FLAGS
and so were unused.

This commit deletes that logic (which, if enabled, would
introduce many new warnings, especially the -std=c99). But,
it leaves the -Wno-pointer-sign to disable that particular
warning which occurs in many places.

There were a series of statements in the CMake file having
to do with controlling warning flags (including adding -Wall)
however they were not actually applied to the CMAKE_C_FLAGS
and so were unused.

This commit deletes that logic (which, if enabled, would
introduce many new warnings, especially the -std=c99).  But,
it leaves the -Wno-pointer-sign to disable that particular
warning which occurs in many places.
@vstakhov
Copy link
Owner

vstakhov commented Dec 7, 2018

It also disables -W flag that is undesired.

@no-more-secrets
Copy link
Contributor Author

I have added the -W into the list of warnings; but notice that, before these commits, the -W was not enabled at all, because the CMAKE_C_WARN_FLAGS variable was not being set into the CMAKE_C_FLAGS variable (that's why -Wall was in fact not set!) Let me know if you want more explanation. Thanks

@vstakhov
Copy link
Owner

vstakhov commented Dec 8, 2018

Good catch, thank you! I've copied that fragment from Rspamd in fact, but I forgot to set CFLAGS appropriately.

@vstakhov vstakhov merged commit d67ea82 into vstakhov:master Dec 8, 2018
@no-more-secrets no-more-secrets deleted the warning-fix branch December 8, 2018 16:36
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