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

Hide C compiler warnings about unused items, explain some others #232

Merged
merged 1 commit into from
Mar 3, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 10 additions & 5 deletions meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,19 @@ g_ir_compiler = find_program('g-ir-compiler', required: false)
# generated vala code triggers tons of these
add_project_arguments(
cc.get_supported_arguments(
# Vala doesn't have `const void*`, or a way to selectively #pragma these in the code
'-Wno-error=discarded-qualifiers',
# mostly const dropping and dropped "volatile" in fully autogenerated code;
# upstream Vala does not support fixing this warning
'-Wno-error=incompatible-pointer-types',
# https://gitlab.gnome.org/GNOME/vala/-/issues/1529
'-Wno-error=pointer-sign',
'-Wno-error=unused-but-set-variable',
'-Wno-error=unused-function',
'-Wno-error=unused-label',
'-Wno-error=unused-value',
'-Wno-error=unused-variable'
# "mostly harmless", fallout from Vala C code template generation, C compiler will optimize away
'-Wno-unused-but-set-variable',
'-Wno-unused-function',
'-Wno-unused-label',
'-Wno-unused-value',
'-Wno-unused-variable'
), language: 'c')

# HACK: vala doesn't support declaring const arguments, so we get a lot of errors
Expand Down
Loading