Re: Troubleshooting openSUSE's packaging process

Alexander Leithner <[email protected]> Sat, 5 Apr 2025 14:47:30 +0200
Newsgroups gmane.comp.emulators.wine.devel
Message-ID <[email protected]>
Am 04.04.25 um 15:44 schrieb Alexandre Julliard:
> Alexander Leithner <[email protected]> writes:
>> Shouldn't GCC provide support for -mabi=ms out of the box?
> 
> Yes, there must be something else going on. Is the config.log file
> available?

OK, I've managed to extract config.log from a local OBS build. The 
section relevant to -mabi=ms reads:

configure:20674: checking for working -mabi=ms
configure:20693: gcc -m64 -c -O2 -Wall -U_FORTIFY_SOURCE 
-D_FORTIFY_SOURCE=3 -fstack-protector-strong -funwind-tables 
-fasynchronous-unwind-tables -fstack-clash-protection 
-Werror=return-type  -mabi=ms  conftest.c >&5
conftest.c: In function 'a':
conftest.c:165:79: error: control reaches end of non-void function 
[-Werror=return-type]
   165 | int a(int b, ...) { __builtin_ms_va_list list; 
__builtin_ms_va_start(list,b); }
       | 
               ^
cc1: some warnings being treated as errors
configure:20693: $? = 1

Indeed, the build script on OBS exports a bunch of additional flags 
before configuring Wine as seen above, including setting 
-Werror=return-type.

Running configure with CFLAGS='-Werror=return-type ' also is enough to 
reproduce OBS' config.log output locally on my machine. Is this a bug in 
-mabi=ms detection or should OBS not set -Werror=return-type?

As a side note, OBS also enables Fortify. Isn't this subsequently 
disabled by configure anyway? If so, I imagine OBS could just not enable 
it in the first place, right?

Thanks for your help!

Best,
Alexander Leithner
OpenPGP_signature.asc (application/pgp-signature, 236 B)
-----BEGIN PGP SIGNATURE-----

wnsEABYIACMWIQQftGQEMKbKavcifoTZadYVna+vuQUCZ/EmYgUDAAAAAAAKCRDZadYVna+vudR4
AP4+8xQbEIfcjgkAA+aglHdqa+eMZ4V7yvxuNnhn/jY/uQD/WYr7oFY3jKzDFi1yZjG3auFsZzbq
Z4QVUihBoASmZAY=
=eaig
-----END PGP SIGNATURE-----