On Sun, Aug 2, 2020 at 9:55 AM Fabio Valentini decathorpe@gmail.com wrote:
I'm looking through F33 FTBFS issues, and I see an increasing number of packages that fail to build because their test suites (using check) fail to build with errors like this:
/usr/include/check.h:502:27: note: declared here 502 | CK_DLL_EXP void CK_EXPORT _ck_assert_failed(const char *file, int line, | ^~~~~~~~~~~~~~~~~ path_utils/path_utils_ut.c:698:3: error: too few arguments to function '_ck_assert_failed'
For example, gsignond-plugin-oauth, gsignond-plugin-sasl, libaccounts-glib, signon-glib, ding-libs fail with these issues.
Any idea if that's a problem with the "check" 0.15.x builds themselves, or if packages need to adapt to changed API here?
You can point the finger of blame at least partly at me for this. Version 0.15.0 of check introduced the use of __attribute__((printf....)) to check the arguments to some of the calls. However, upstream didn't do it right, with the result that gcc warned on pretty much every use of the check macros. I submitted a patch upstream to fix that, which upstream applied and included in version 0.15.1. That patch, however, broke other things, such as the ability to call fail_if() with only one argument.
I've been working on another patch to fix *that*. It's not too hard to do for gcc, which makes __VA_OPT__ available to the C compiler, but not so easy for the Microsoft compiler. I'll attach what I have so far. Comments or suggestions on how to make it better are much appreciated. I would like to submit something upstream by tomorrow. If upstream likes the idea, I'll do another build of check that includes the patch.