From owner-freebsd-current Sun Dec 8 7:53:29 2002 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 174EC37B401 for ; Sun, 8 Dec 2002 07:53:28 -0800 (PST) Received: from espresso.q9media.com (espresso.q9media.com [65.39.129.122]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8934D43EB2 for ; Sun, 8 Dec 2002 07:53:27 -0800 (PST) (envelope-from mike@espresso.q9media.com) Received: by espresso.q9media.com (Postfix, from userid 1002) id C47CA9BC3; Sun, 8 Dec 2002 10:43:35 -0500 (EST) Date: Sun, 8 Dec 2002 10:43:35 -0500 From: Mike Barcroft To: Marc Recht Cc: freebsd-current@FreeBSD.ORG Subject: Re: sys/file.h and POSIX Message-ID: <20021208104335.E74206@espresso.q9media.com> References: <509390000.1039349835@leeloo.intern.geht.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <509390000.1039349835@leeloo.intern.geht.de>; from marc@informatik.uni-bremen.de on Sun, Dec 08, 2002 at 01:17:15PM +0100 Organization: The FreeBSD Project Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Marc Recht writes: > Hi! > > While compiling some third-party code I got this: > gcc -D_POSIX_C_SOURCE=200112L -D_XOPEN_SOURCE_=600 > -D_XOPEN_SOURCE_EXTENDED=1 test.c > In file included from test.c:2: > /usr/include/sys/file.h:130: syntax error before "u_int" > > This makes me wonder a bit.. Shouldn't the header at least be includeable ? > Eg. setting __BSD_VISIBLE around xfile ? > > Test source: > > #include > #include > > int main() { > return 0; > } Why are you specifying a standard and then using features outside its scope? Either you want a BSD environment (in which case don't specify a standard), or you want a standard environment (where file.h doesn't exist). Indeed what you are trying to do is unsupported. For details on how to write a conforming application see section 2.2 of POSIX.1-2001. Best regards, Mike Barcroft To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message