delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2012/02/08/08:34:11

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-6.9 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_RP_MATCHES_RCVD
X-Spam-Check-By: sourceware.org
Message-ID: <4F3279AC.2010705@redhat.com>
Date: Wed, 08 Feb 2012 06:33:32 -0700
From: Eric Blake <eblake AT redhat DOT com>
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0) Gecko/20120131 Thunderbird/10.0
MIME-Version: 1.0
To: cygwin <cygwin AT cygwin DOT com>
Subject: <sys/sysmacros.h> is broken
OpenPGP: url=http://people.redhat.com/eblake/eblake.gpg
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

--------------enig24085C387F25566C4AB8DCA0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

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=3Dc99
/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 `=3D', `,', `;',
`asm', or `__attribute__' before `int'
...

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


--------------enig24085C387F25566C4AB8DCA0
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Public key at http://people.redhat.com/eblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQEcBAEBCAAGBQJPMnmsAAoJEKeha0olJ0NqZe0H/3q6qSYYLud5cUlvyh7rwohs
Jk4dskMDmoYtvjDBv6ea1eDIqGE8+3395ScRsW9Ep3i/bfvvBGyPsJdIoIFEEj7q
NDl3FiFjNBuASOL/v40JWtogbcgTGMjzuNbq07a+ZVHLJdQK/p4C+Vz43rrPJpRy
leFE2yzeEJA60uscPkS74atsfVJCAQCyb7XHLYVeurM1B7QzOvfy8sevDsbv275v
+c1tF10uCU2ZO0Y0dEZ5ypPTpByPzGb5c1TpiJqlp9882gPnsM21QcQArGXThmy5
0YpwGfoCYv4QKHZ9thUl3T7/Fd+DWXr7XYW7bM8X0hWm3hz2UwCMjqRNSo+g8IM=
=/dP6
-----END PGP SIGNATURE-----

--------------enig24085C387F25566C4AB8DCA0--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019