Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 21 Feb 2004 10:50:13 -0800 (PST)
From:      Andrey Chernov <ache@nagual.pp.ru>
To:        freebsd-standards@FreeBSD.org
Subject:   Re: standards/63173: Patch to add getopt_long_only(3) to libc
Message-ID:  <200402211850.i1LIoDJW041528@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR standards/63173; it has been noted by GNATS.

From: Andrey Chernov <ache@nagual.pp.ru>
To: Marius Strobl <marius@alchemy.franken.de>
Cc: FreeBSD-gnats-submit@FreeBSD.ORG, ru@FreeBSD.ORG
Subject: Re: standards/63173: Patch to add getopt_long_only(3) to libc
Date: Sat, 21 Feb 2004 21:48:14 +0300

 On Sat, Feb 21, 2004 at 04:57:06PM +0100, Marius Strobl wrote:
 > 	after applying the patch still doesn't implement getopt(3) and
 > 	therefore replace src/lib/libc/stdlib/getopt.c, i.e. it doesn't
 > 	define REPLACE_GETOPT, yet. This is something that should be taken
 > 	into consideration for FreeBSD 6 (regardless if the patch is applied
 > 	or not).
 
 Please always consider POSIX as superceeded standard against GNU/Linux.
 
 It means your patch for header is wrong. If POSIX says that getopt() must 
 be declared in <unistd.h>, it is only place where is must be declared, and 
 not in <getopt.h> etc. If you need its declaration in non-standard header 
 <getopt.h>, <unistd.h> must be included, as was done before your patch. 
 Also please remove all getopt()-related redeclarations from <getopt.h>
 
 Forget about REPLACE_GETOPT, it will never be defined, we already have 
 standard-conforming one. Making getopt() like getopt_long() really breaks 
 some strict getopt() syntax. If some GNU program likes to use plain 
 getopt() as getopt_long(), it should either use separate library or it 
 source code should replace getopt->getopt_long.
 
 Otherwise it looks fine.
 -- 
 Andrey Chernov | http://ache.pp.ru/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200402211850.i1LIoDJW041528>