43.0 + master: build fails with `-Wint-conversion`
Looks like some code needs to be updated.
Build fails with
[tkloczko@pers-jacek x86_64-redhat-linux-gnu]$ ninja
[2/5] Compiling C object ssh/libseahorse-ssh.a.p/meson-generated_operation.c.o
FAILED: ssh/libseahorse-ssh.a.p/meson-generated_operation.c.o
/usr/bin/gcc -Issh/libseahorse-ssh.a.p -Issh -I../ssh -Icommon -I../common -I. -I.. -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/gio-unix-2.0 -I/usr/include/gcr-3 -I/usr/include/p11-kit-1 -I/usr/include/gtk-3.0 -I/usr/include/harfbuzz -I/usr/include/pango-1.0 -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/gck-1 -I/usr/include/libhandy-1 -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -DGCR_API_SUBJECT_TO_CHANGE -DGCK_API_SUBJECT_TO_CHANGE -DSECRET_WITH_UNSTABLE -include config.h -Wno-unused-parameter -Wno-missing-field-initializers -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -O2 -g -grecord-gcc-switches -pipe -mtls-dialect=gnu2 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -fdata-sections -ffunction-sections -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -flto=auto -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -Wall -Werror=format-security -Os -fPIC -pthread -MD -MQ ssh/libseahorse-ssh.a.p/meson-generated_operation.c.o -MF ssh/libseahorse-ssh.a.p/meson-generated_operation.c.o.d -o ssh/libseahorse-ssh.a.p/meson-generated_operation.c.o -c ssh/libseahorse-ssh.a.p/operation.c
In file included from /usr/include/glib-2.0/glib.h:64,
from /usr/include/glib-2.0/gobject/gbinding.h:30,
from /usr/include/glib-2.0/glib-object.h:24,
from /usr/include/glib-2.0/gio/gioenums.h:30,
from /usr/include/glib-2.0/gio/giotypes.h:30,
from /usr/include/glib-2.0/gio/gio.h:28,
from common/seahorse-common.h:6,
from ssh/seahorse-ssh.h:6,
from ssh/libseahorse-ssh.a.p/operation.c:25:
../ssh/operation.vala: In function ‘seahorse_ssh_operation_operation_async_co’:
/usr/include/glib-2.0/glib/gmessages.h:671:16: error: returning ‘void *’ from a function with return type ‘gboolean’ {aka ‘int’} makes integer from pointer without a cast [-Wint-conversion]
671 | return (val); \
| ^
../ssh/operation.vala:52:2: note: in expansion of macro ‘g_return_val_if_fail’
52 | return_val_if_fail (command != null && command != "", null);
| ^ ~~~~~~~~~~~~~
../ssh/operation.vala:86:73: warning: passing argument 2 of ‘g_subprocess_launcher_spawnv’ from incompatible pointer type [-Wincompatible-pointer-types]
86 | var subprocess = launcher.spawnv(args);
| ^
| |
| gchar ** {aka char **}
In file included from /usr/include/glib-2.0/gio/gio.h:156:
/usr/include/glib-2.0/gio/gsubprocesslauncher.h:54:97: note: expected ‘const gchar * const*’ {aka ‘const char * const*’} but argument is of type ‘gchar **’ {aka ‘char **’}
54 | const gchar * const *argv,
| ~~~~~~~~~~~~~~~~~~~~~~~^~~~
In file included from /usr/include/glib-2.0/glib/gthread.h:34,
from /usr/include/glib-2.0/glib/gasyncqueue.h:34,
from /usr/include/glib-2.0/glib.h:34:
operation.c: In function ‘seahorse_ssh_operation_get_type’:
/usr/include/glib-2.0/glib/gatomic.h:131:5: warning: argument 2 of ‘__atomic_load’ discards ‘volatile’ qualifier [-Wdiscarded-qualifiers]
131 | __atomic_load (gapg_temp_atomic, &gapg_temp_newval, __ATOMIC_SEQ_CST); \
| ^~~~~~~~~~~~~
/usr/include/glib-2.0/glib/gthread.h:272:7: note: in expansion of macro ‘g_atomic_pointer_get’
272 | (!g_atomic_pointer_get (location) && \
| ^~~~~~~~~~~~~~~~~~~~
operation.c:942:6: note: in expansion of macro ‘g_once_init_enter’
operation.c: In function ‘__lambda14_’:
operation.c:1093:30: warning: variable ‘self’ set but not used [-Wunused-but-set-variable]
../ssh/operation.vala: In function ‘seahorse_ssh_upload_operation_upload_async_co’:
../ssh/operation.vala:122:32: warning: passing argument 2 of ‘g_list_foreach’ from incompatible pointer type [-Wincompatible-pointer-types]
122 | keys.foreach((key) => {
| ^
| |
| void (*)(const void *, void *)
In file included from /usr/include/glib-2.0/glib/ghash.h:36,
from /usr/include/glib-2.0/glib.h:52:
/usr/include/glib-2.0/glib/glist.h:139:60: note: expected ‘GFunc’ {aka ‘void (*)(void *, void *)’} but argument is of type ‘void (*)(const void *, void *)’
139 | GFunc func,
| ~~~~~~~~~~~~~~~~~~^~~~
operation.c: In function ‘seahorse_ssh_upload_operation_get_type’:
/usr/include/glib-2.0/glib/gatomic.h:131:5: warning: argument 2 of ‘__atomic_load’ discards ‘volatile’ qualifier [-Wdiscarded-qualifiers]
131 | __atomic_load (gapg_temp_atomic, &gapg_temp_newval, __ATOMIC_SEQ_CST); \
| ^~~~~~~~~~~~~
/usr/include/glib-2.0/glib/gthread.h:272:7: note: in expansion of macro ‘g_atomic_pointer_get’
272 | (!g_atomic_pointer_get (location) && \
| ^~~~~~~~~~~~~~~~~~~~
operation.c:1424:6: note: in expansion of macro ‘g_once_init_enter’
operation.c: In function ‘seahorse_ssh_change_passphrase_operation_get_type’:
/usr/include/glib-2.0/glib/gatomic.h:131:5: warning: argument 2 of ‘__atomic_load’ discards ‘volatile’ qualifier [-Wdiscarded-qualifiers]
131 | __atomic_load (gapg_temp_atomic, &gapg_temp_newval, __ATOMIC_SEQ_CST); \
| ^~~~~~~~~~~~~
/usr/include/glib-2.0/glib/gthread.h:272:7: note: in expansion of macro ‘g_atomic_pointer_get’
272 | (!g_atomic_pointer_get (location) && \
| ^~~~~~~~~~~~~~~~~~~~
operation.c:1712:6: note: in expansion of macro ‘g_once_init_enter’
operation.c: In function ‘seahorse_ssh_generate_operation_get_type’:
/usr/include/glib-2.0/glib/gatomic.h:131:5: warning: argument 2 of ‘__atomic_load’ discards ‘volatile’ qualifier [-Wdiscarded-qualifiers]
131 | __atomic_load (gapg_temp_atomic, &gapg_temp_newval, __ATOMIC_SEQ_CST); \
| ^~~~~~~~~~~~~
/usr/include/glib-2.0/glib/gthread.h:272:7: note: in expansion of macro ‘g_atomic_pointer_get’
272 | (!g_atomic_pointer_get (location) && \
| ^~~~~~~~~~~~~~~~~~~~
operation.c:2032:6: note: in expansion of macro ‘g_once_init_enter’
operation.c: In function ‘seahorse_ssh_private_import_operation_get_type’:
/usr/include/glib-2.0/glib/gatomic.h:131:5: warning: argument 2 of ‘__atomic_load’ discards ‘volatile’ qualifier [-Wdiscarded-qualifiers]
131 | __atomic_load (gapg_temp_atomic, &gapg_temp_newval, __ATOMIC_SEQ_CST); \
| ^~~~~~~~~~~~~
/usr/include/glib-2.0/glib/gthread.h:272:7: note: in expansion of macro ‘g_atomic_pointer_get’
272 | (!g_atomic_pointer_get (location) && \
| ^~~~~~~~~~~~~~~~~~~~
operation.c:2646:6: note: in expansion of macro ‘g_once_init_enter’
operation.c: In function ‘seahorse_ssh_rename_operation_change_raw_comment’:
operation.c:2941:7: warning: variable ‘_tmp13__length1’ set but not used [-Wunused-but-set-variable]
operation.c:2936:7: warning: variable ‘_tmp9__length1’ set but not used [-Wunused-but-set-variable]
operation.c:2933:10: warning: variable ‘_tmp8_’ set but not used [-Wunused-but-set-variable]
operation.c:2932:7: warning: variable ‘_parts_size_’ set but not used [-Wunused-but-set-variable]
operation.c: In function ‘seahorse_ssh_rename_operation_get_type’:
/usr/include/glib-2.0/glib/gatomic.h:131:5: warning: argument 2 of ‘__atomic_load’ discards ‘volatile’ qualifier [-Wdiscarded-qualifiers]
131 | __atomic_load (gapg_temp_atomic, &gapg_temp_newval, __ATOMIC_SEQ_CST); \
| ^~~~~~~~~~~~~
/usr/include/glib-2.0/glib/gthread.h:272:7: note: in expansion of macro ‘g_atomic_pointer_get’
272 | (!g_atomic_pointer_get (location) && \
| ^~~~~~~~~~~~~~~~~~~~
operation.c:3092:6: note: in expansion of macro ‘g_once_init_enter’
operation.c: At top level:
operation.c:1059:1: warning: ‘block7_data_ref’ defined but not used [-Wunused-function]
ssh/libseahorse-ssh.a.p/operation.c:86:20: warning: ‘seahorse_ssh_rename_operation_properties’ defined but not used [-Wunused-variable]
86 | static GParamSpec* seahorse_ssh_rename_operation_properties[SEAHORSE_SSH_RENAME_OPERATION_NUM_PROPERTIES];
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ssh/libseahorse-ssh.a.p/operation.c:80:20: warning: ‘seahorse_ssh_private_import_operation_properties’ defined but not used [-Wunused-variable]
80 | static GParamSpec* seahorse_ssh_private_import_operation_properties[SEAHORSE_SSH_PRIVATE_IMPORT_OPERATION_NUM_PROPERTIES];
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ssh/libseahorse-ssh.a.p/operation.c:74:20: warning: ‘seahorse_ssh_generate_operation_properties’ defined but not used [-Wunused-variable]
74 | static GParamSpec* seahorse_ssh_generate_operation_properties[SEAHORSE_SSH_GENERATE_OPERATION_NUM_PROPERTIES];
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ssh/libseahorse-ssh.a.p/operation.c:68:20: warning: ‘seahorse_ssh_change_passphrase_operation_properties’ defined but not used [-Wunused-variable]
68 | static GParamSpec* seahorse_ssh_change_passphrase_operation_properties[SEAHORSE_SSH_CHANGE_PASSPHRASE_OPERATION_NUM_PROPERTIES];
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ssh/libseahorse-ssh.a.p/operation.c:60:20: warning: ‘seahorse_ssh_upload_operation_properties’ defined but not used [-Wunused-variable]
60 | static GParamSpec* seahorse_ssh_upload_operation_properties[SEAHORSE_SSH_UPLOAD_OPERATION_NUM_PROPERTIES];
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ssh/libseahorse-ssh.a.p/operation.c:51:20: warning: ‘seahorse_ssh_operation_properties’ defined but not used [-Wunused-variable]
51 | static GParamSpec* seahorse_ssh_operation_properties[SEAHORSE_SSH_OPERATION_NUM_PROPERTIES];
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ninja: build stopped: subcommand failed.