<sys/sysmacros.h> is broken
Eric Blake
eblake@redhat.com
Wed Feb 8 13:33:00 GMT 2012
STC showing that sysmacros doesn't work when included indirectly in C99
mode:
$ cat foo.c
#include <sys/types.h>
int main() { return makedev(0,0); }
$ gcc -o foo foo.c
$ gcc -o foo foo.c --std=c99
/tmp/ccT40f0H.o:foo.c:(.text+0x1e): undefined reference to
`_gnu_dev_makedev'
collect2: ld returned 1 exit status
Another STC showing that sysmacros is broken as a standalone header:
$ cat bar.c
#include <sys/sysmacros.h>
int main() { return makedev(0,0); }
$ gcc -o foo foo.c
In file include from foo.c:1:0:
/usr/include/sys/sysmacros.h:14:18: error: expected `=', `,', `;',
`asm', or `__attribute__' before `int'
...
--
Eric Blake eblake@redhat.com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 620 bytes
Desc: OpenPGP digital signature
URL: <http://cygwin.com/pipermail/cygwin/attachments/20120208/08c51481/attachment.sig>
More information about the Cygwin
mailing list