From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/6139 Path: news.gmane.org!not-for-mail From: Szabolcs Nagy Newsgroups: gmane.linux.lib.musl.general Subject: Re: why is there no __MUSL__ macro? Date: Thu, 11 Sep 2014 13:17:21 +0200 Message-ID: <20140911111721.GG21835@port70.net> References: <541180B9.5070604@posteo.de> <541182D3.5010104@skarnet.org> 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 1410434259 19228 80.91.229.3 (11 Sep 2014 11:17:39 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 11 Sep 2014 11:17:39 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-6152-gllmg-musl=m.gmane.org@lists.openwall.com Thu Sep 11 13:17:34 2014 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 1XS2Na-0004kp-0a for gllmg-musl@plane.gmane.org; Thu, 11 Sep 2014 13:17:34 +0200 Original-Received: (qmail 20321 invoked by uid 550); 11 Sep 2014 11:17:33 -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 20313 invoked from network); 11 Sep 2014 11:17:33 -0000 Mail-Followup-To: musl@lists.openwall.com Content-Disposition: inline In-Reply-To: <541182D3.5010104@skarnet.org> User-Agent: Mutt/1.5.23 (2014-03-12) Xref: news.gmane.org gmane.linux.lib.musl.general:6139 Archived-At: * Laurent Bercot [2014-09-11 12:09:07 +0100]: > >FFmpeg needs support for library features defined in POSIX.1-2001 with XSI extension and the standards below. Currently configure probes the host and target libc by checking for defined macros like __GLIBC__ and __UCLIBC__. In case of glibc and uclibc it sets -D_XOPEN_SOURCE=600 properly. > > Why not set this macro unconditionally ? > All standards-compliant libcs will make the correct symbols visible > if you define _XOPEN_SOURCE to a certain value. This include glibc, this has to be the most frequently asked question http://wiki.musl-libc.org/wiki/FAQ#Q:_why_is_there_no_MUSL_macro_.3F and yes, assuming standard conformance by default is the sane thing to do then _testing_ for conformance issues is the second try if the default fails and only if testing is somehow difficult/inappropriate should one fall back to hardcoding behaviour for particular non-conforming systems in case of musl conformance bugs are fixed so you should report them instead of trying to work them around