Re: [PATCH] build: Include sys/wait.h in commandtest.c

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 03/04/2014 12:45 AM, Ján Tomko wrote:
> Commit 631923e used a few macros from sys/wait.h without including
> it. On Linux, they were also defined in stdlib.h, but on FreeBSD
> the build failed:
> 
> ../../tests/commandtest.c: In function 'test1':
> warning: implicit declaration of function 'WIFEXITED'
> warning: nested extern declaration of 'WIFEXITED' [-Wnested-externs]

Bah - FreeBSD has a bug.  POSIX requires these macros in <stdlib.h>:

http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/stdlib.h.html#tag_13_50

Ah - gnulib works around it already!  But only if you use the
'system-posix' module, which libvirt isn't doing yet.  Guess I'll do the
obvious followup patch to bootstrap.conf to work around the <stdlib.h>
FreeBSD bug for all platforms.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]