Bug #12705
closed
With GCC9, compiling some of ON gives:
libucb: mismatch in argument 1 type of built-in function '__builtin_alloca'; expected 'unsigned int'
The problem is that "size_t" for 32-bit C in ucbhead/sys/types.h is defined as "ulong_t". This doesn't occur in other situations.
As the extern declaration of the builtin is completely unecessary under GCC 4 onwards at least, the simplest solution is to remove it from string.h
John Levon wrote:
With GCC9, compiling some of ON gives:
[...]
The problem is that "size_t" for 32-bit C in ucbhead/sys/types.h is defined as "ulong_t". This doesn't occur in other situations.
As the extern declaration of the builtin is completely unecessary under GCC 4 onwards at least, the simplest solution is to remove it from string.h
The issue is reported for: libucb, libtermcap, libdbm, libcurses, librpcsoc and vipw.
I spot tested this under GCC4, 7, and 9, as well doing a nightly on a system installed with this new string.h
- Status changed from New to Closed
- % Done changed from 0 to 100
git commit c8907381b10259bed3a871a2881c0f3b7287ab3c
commit c8907381b10259bed3a871a2881c0f3b7287ab3c
Author: John Levon <john.levon@joyent.com>
Date: 2020-05-11T16:21:08.000Z
12705 remove __builtin_alloca() declaration from string.h
Reviewed by: Toomas Soome <tsoome@me.com>
Reviewed by: Andy Stormont <astormont@racktopsystems.com>
Approved by: Gordon Ross <gordon.w.ross@gmail.com>
Also available in: Atom
PDF