On 04/25/13 12:36, Richard Henderson wrote: > On 2013-04-25 07:47, Martin Husemann wrote: >> I just tried building git HEAD on NetBSD-current and gcc chokes on >> a prototype mismatch for popcountl: >> >> util/hbitmap.c has: >> >> static inline int popcountl(unsigned long l) >> { >> return BITS_PER_LONG == 32 ? ctpop32(l) : ctpop64(l); >> } >> >> while NetBSD's strings.h uses: >> >> unsigned int popcountl(unsigned long) __constfunc; > > <strings.h> is the K&R header supplanted by ISO <string.h>. > Is there any good reason that we're including it at all?
- <strings.h> is a portable SUS/POSIX header: http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/strings.h.html - "popcountl()" in NetBSD's <strings.h> is either a standards-nonconformance issue, or the the qemu build system doesn't set up the right SUS/POSIX environment for compilation on NetBSD. (If that's possible at all, I don't know.) Laszlo