From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/10999 Path: news.gmane.org!.POSTED!not-for-mail From: Rich Felker Newsgroups: gmane.linux.lib.musl.general Subject: Re: Re: [alpine-devel] Non-standard C library Date: Tue, 31 Jan 2017 14:37:41 -0500 Message-ID: <20170131193741.GS1533@brightrain.aerifal.cx> References: <5blaf1.okfi73.2tnq26-qmf@gmx.com> <5890704A.8090402@mail.com> <717ca2a3-d579-4ab6-ace2-1bc0dbbb111c@skogtun.org> <5890E097.1060601@adelielinux.org> <20170131192310.GR1533@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: blaine.gmane.org 1485891482 19015 195.159.176.226 (31 Jan 2017 19:38:02 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 31 Jan 2017 19:38:02 +0000 (UTC) User-Agent: Mutt/1.5.21 (2010-09-15) To: musl@lists.openwall.com Original-X-From: musl-return-11014-gllmg-musl=m.gmane.org@lists.openwall.com Tue Jan 31 20:37:55 2017 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by blaine.gmane.org with smtp (Exim 4.84_2) (envelope-from ) id 1cYeFS-0004am-Ps for gllmg-musl@m.gmane.org; Tue, 31 Jan 2017 20:37:50 +0100 Original-Received: (qmail 17612 invoked by uid 550); 31 Jan 2017 19:37:54 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 17587 invoked from network); 31 Jan 2017 19:37:53 -0000 Content-Disposition: inline In-Reply-To: <20170131192310.GR1533@brightrain.aerifal.cx> Original-Sender: Rich Felker Xref: news.gmane.org gmane.linux.lib.musl.general:10999 Archived-At: On Tue, Jan 31, 2017 at 02:23:10PM -0500, Rich Felker wrote: > On Tue, Jan 31, 2017 at 01:08:07PM -0600, A. Wilcox wrote: > > -----BEGIN PGP SIGNED MESSAGE----- > > Hash: SHA256 > > > > On 31/01/17 12:50, William Pitcock wrote: > > > On Tue, Jan 31, 2017 at 12:22 PM, Harald Arnesen > > > wrote: > > >> musl defines "IPPORT_RESERVED" in "netdb.h", while both GNU libc > > >> and BSD libc define it in "netinet/in.h". And I can't find an > > >> e-mail address for a musl developer without subscribing to their > > >> mailing list. > > > > > > POSIX.1-2008 clearly says IPPORT_RESERVED shall be defined in : > > http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/netdb.h.html > > > > ..... > > > > > > > I checked on both a Debian and FreeBSD machine and indeed, they > > > both have it in netinet/in.h. > > > > ..... > > > > however, POSIX.1-2008 also clearly says "may also make visible > > all symbols from ". > > > > > > > What shall we do? > > > > > > Theoretically, the code they are compiling is wrong; POSIX only > > guarantees the definition in . However, there is a bit of > > leeway in the standard since may include all symbols from > > ; if it's defined there, can pull that header > > in providing the definition. > > > > I would say that the best thing to do in the interests of > > compatibility would be to put the definition in *and* > > fix whatever broken project that is (Snobol?) to include . > > This is what FreeBSD and glibc both do; define it in > > and include that header in . > > The name IPPORT_RESERVED is not reserved in the namespace for > netinet/in.h, so it can't be added there unless it's conditional on > nonstandard feature profile. That might be justifiable if lots of > applications had the wrong expectation here, but being that this is > the first time we've heard of the issue, it seems there are just a few > (or only one) applications which are doing this wrong, and they should > just be fixed. I seem to have overlooked it in the second table of reserved names: http://pubs.opengroup.org/onlinepubs/9699919799/functions/V2_chap02.html#tag_15_02_02 so it does seem like we could reasonably move it to netinet/in.h. Rich