From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/4947 Path: news.gmane.org!not-for-mail From: Rich Felker Newsgroups: gmane.linux.lib.musl.general Subject: Re: musl-llvm and crtbegin/crtend Date: Tue, 22 Apr 2014 18:38:11 -0400 Message-ID: <20140422223811.GM26358@brightrain.aerifal.cx> References: <5356E4CA.7060907@midipix.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 1398206310 21607 80.91.229.3 (22 Apr 2014 22:38:30 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 22 Apr 2014 22:38:30 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-4951-gllmg-musl=m.gmane.org@lists.openwall.com Wed Apr 23 00:38:25 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 1WcjKb-000506-37 for gllmg-musl@plane.gmane.org; Wed, 23 Apr 2014 00:38:25 +0200 Original-Received: (qmail 30589 invoked by uid 550); 22 Apr 2014 22:38:24 -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 30575 invoked from network); 22 Apr 2014 22:38:24 -0000 Content-Disposition: inline In-Reply-To: <5356E4CA.7060907@midipix.org> User-Agent: Mutt/1.5.21 (2010-09-15) Original-Sender: Rich Felker Xref: news.gmane.org gmane.linux.lib.musl.general:4947 Archived-At: On Tue, Apr 22, 2014 at 05:53:14PM -0400, writeonce@midipix.org wrote: > Greetings, > > First issue, and probably an easy fix, is the link to crtbegin.S and > crtend.S on the musl wiki page entitled BuildingLLVM. The current > links are broken, and should (probably) point to > http://cvsweb.netbsd.org/bsdweb.cgi/src/lib/csu/ (the actual files > are under arch/{$ARCH} > > More importantly, though: from very recent communication on the > clang developer list, it is my understanding that the NetBSD > crtbegin/crtend are the _de facto_ standard for self-hosting clang > toolchains. If that is the case, does anyone know of a special > license exception pertaining to these files? If I read the license > correctly, then every binary containing the resulting crtbegin.o and > crtend.o would have to include a copy of the license with its > documentation. If there is such exception, then I'd suggest that > the wiki page includes a link to it. I'm not aware of this, but you might want to check and see if this junk is even needed. My understanding is that these files do nothing useful whatsoever unless you're using the old _init/_fini based ctor/dtor system. GCC at least has switched to generating __init_array and __fini_array which are much saner and I would guess clang has too. Note that these files aren't needed at all for pure C code anyway, only for C++, GNU C, or other langs with static ctors/dtors. Rich