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

build: Use c11 rather than gnu11 and define vendor extensions separately #302

Merged
merged 2 commits into from Feb 10, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
@@ -1,6 +1,6 @@
project('AppStream', 'c',
meson_version: '>=0.48',
default_options: ['c_std=gnu11', 'cpp_std=gnu++14'],
default_options: ['c_std=c11', 'cpp_std=gnu++14'],

license: 'LGPL-2.1+ and GPL-2.0+',
version: '0.14.1',
@@ -80,6 +80,9 @@ add_project_arguments('-Werror=implicit-function-declaration', '-Wno-unused-para
add_project_arguments('-Wno-unused-parameter', language: 'cpp')
add_project_arguments('-DAS_COMPILATION', language: 'c')

# Vendor extensions in system headers
add_project_arguments('-D_POSIX_C_SOURCE=200112L', language: 'c')

#
# Dependencies
#
@@ -209,7 +209,7 @@ ascli_what_provides (const gchar *cachepath, const gchar *kind_str, const gchar

kind = as_provided_kind_from_string (kind_str);
if (kind == AS_PROVIDED_KIND_UNKNOWN) {
uint i;
unsigned int i;
g_printerr ("%s\n", _("Invalid type for provided item selected. Valid values are:"));
for (i = 1; i < AS_PROVIDED_KIND_LAST; i++)
g_printerr (" • %s\n", as_provided_kind_to_string (i));