From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/1810 Path: news.gmane.org!not-for-mail From: Rich Felker Newsgroups: gmane.linux.lib.musl.general Subject: Re: Best bikeshed ever (feature test macros) Date: Sun, 2 Sep 2012 13:10:33 -0400 Message-ID: <20120902171033.GE27715@brightrain.aerifal.cx> References: <20120824214138.GA17792@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1346605705 3442 80.91.229.3 (2 Sep 2012 17:08:25 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 2 Sep 2012 17:08:25 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-1811-gllmg-musl=m.gmane.org@lists.openwall.com Sun Sep 02 19:08:27 2012 Return-path: Envelope-to: gllmg-musl@plane.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1T8Deq-0002Da-UU for gllmg-musl@plane.gmane.org; Sun, 02 Sep 2012 19:08:25 +0200 Original-Received: (qmail 16313 invoked by uid 550); 2 Sep 2012 17:08:22 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Original-Received: (qmail 16305 invoked from network); 2 Sep 2012 17:08:21 -0000 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Xref: news.gmane.org gmane.linux.lib.musl.general:1810 Archived-At: On Sun, Sep 02, 2012 at 10:00:27AM -0700, nwmcsween@gmail.com wrote: > > Much like the last thread I created to assess opinion (the license > > one), this is all fairly open-ended and not necessarily going to lead > > to any short- or long-term change in direction, but then again it > > could... Replies don't have to be of the form 1/2/3; alternative ideas > > are welcome, as are replies that just address which goals/criteria are > > most important to you. > > Leave it as is, this actually helps find bugs in software. A real > world example is accidentally utilizing gnu extensions in mruby (see > github mruby bug page for more info). I'm glad to hear of a real-world example where somebody was actually happy about catching bugs like this. However I don't see how the current default contributes to finding such bugs. If you're compiling an app that's targetting POSIX or POSIX+XSI portability, the current default will not handle that; you need to add feature test macros like -D_POSIX_C_SOURCE=200809L, and that would work just as well if we changed the default. Or do you mean to say that the fact that it broke by default prompted you to add -D_POSIX_C_SOURCE=200809L manually, and then when you tried compiling again and got an error message, you realized the issue was a GNU extension that was being used? Can you clarify? As I'm reading the situation, it sounds to me like providing POSIX or POSIX+XSI by default would be just as likely to catch such bugs (if nor moreso, since it would eliminate the case where somebody adds -D_GNU_SOURCE "just to be safe"). Rich