From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/10780 Path: news.gmane.org!.POSTED!not-for-mail From: Rob Landley Newsgroups: gmane.linux.lib.musl.general Subject: Re: cortex-m support? Date: Thu, 8 Dec 2016 16:36:02 -0600 Message-ID: <1507a1db-9153-f5a6-8af8-a80c77c2ef87@landley.net> References: <04e5a294-719e-8029-704f-a57d1ec935b0@landley.net> <20161207152936.GB16379@port70.net> <20161207153519.GC16379@port70.net> <20161208011625.GL1555@brightrain.aerifal.cx> <59e46cdf-0a51-7dd6-e299-dc4137ef91cc@landley.net> <20161208210114.GN1555@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-Trace: blaine.gmane.org 1481236580 14709 195.159.176.226 (8 Dec 2016 22:36:20 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 8 Dec 2016 22:36:20 +0000 (UTC) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 To: musl@lists.openwall.com Original-X-From: musl-return-10793-gllmg-musl=m.gmane.org@lists.openwall.com Thu Dec 08 23:36:16 2016 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 1cF7IV-0002rA-Cc for gllmg-musl@m.gmane.org; Thu, 08 Dec 2016 23:36:15 +0100 Original-Received: (qmail 20093 invoked by uid 550); 8 Dec 2016 22:36:17 -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 20069 invoked from network); 8 Dec 2016 22:36:16 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=landley-net.20150623.gappssmtp.com; s=20150623; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding; bh=6feCVjtPjLQkH9qq+Dm/wut+RTnYECyGowjF7d9K0Ps=; b=rRqv+bGpwwc2J8RkqsKNYd1nR27htldCAaz3G+e+cZxSqMZ7NN3sTb5oDP7o/NXJxH qCBu9a0RhPK38JdCtAt8S261X7knhib9Owd+XF5MewmWrUYvUhSHLBTsyL6SpvlgBFDT aJ9gwgOLLj+TROEkFNrJDS4VsUgdEvIsWtraFDCMH9DUGzcC7xJGjG4lflgVJFPHR6C6 ZQRjTbx4nUHX8EZCS7YSAXORg082Zy7OIV9OHjqwq3OXpt9k+CMnNx0NFq/PbwXt5mhX LqKtH6yVvI6a2L5exki5a9YoJWXuqdxZy/t86Ws6C5DQoy9nZj8ih6nDjKwNZLsny6o4 ph9w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=6feCVjtPjLQkH9qq+Dm/wut+RTnYECyGowjF7d9K0Ps=; b=iee67LykFqdRisdG9Pg6WKeEliy4vFdwjcas6K8SupD0+0PAWOU7o8OHeTxGOEopX7 ZBaa7ly2BfMT5kcld5EcTWjwLLU/3rCLb0DIr+qqBl8kpEzUm8D8oJUl1rpUR3qogOYi eC5hquFKf3I4vQMgFRI80SMhHNQT3CT7UfV9uHdID5cYFDFfjAYzX3TIGEkGG/41rDSE OJYTQsqO0LhXFjdCvLs+q2X5HNlD/LmRHJS/zY3VoZs+LGgwIkrNGrbBQQJPIDTJ51q+ 6m0hJgKAuHGpaFnJ4OpB+pzbxFv+XRdpW9eYHJciewU1aIBN4eMMDsYD7ELJ8ZgU14V5 ncIw== X-Gm-Message-State: AKaTC01207ePS7flT1f/HiuTxztPni0iahgNNkE/AFv5NOZuQGbx/tfzZSCqWk6JI6FNkA== X-Received: by 10.99.19.65 with SMTP id 1mr136398889pgt.71.1481236564193; Thu, 08 Dec 2016 14:36:04 -0800 (PST) In-Reply-To: <20161208210114.GN1555@brightrain.aerifal.cx> Xref: news.gmane.org gmane.linux.lib.musl.general:10780 Archived-At: On 12/08/2016 03:01 PM, Rich Felker wrote: > On Thu, Dec 08, 2016 at 01:10:11PM -0600, Rob Landley wrote: >> On 12/07/2016 07:16 PM, Rich Felker wrote: >>> On Wed, Dec 07, 2016 at 06:55:56PM -0600, Rob Landley wrote: >>>> Not sure where you get the relevant gcc patch... >>> >>> I have links to the repos somewhere; the problem is that they're >>> forked from a fairly old gcc version (although not nearly as bad as >>> sh-fdpic; I think it's 4.8 or so) >> >> https://github.com/mickael-guene/gcc has a 5.2 branch and "master" >> updated 20 hours ago, although I'm not sure how much of master updating >> is an automatic tracking branch and how much is the account owner >> updating things. > > Excellent! That's new since I last communicated with him. > >>> and the authors probably don't have >>> copyright assignments taken care of. >> >> Nobody does copyright assignments voluntarily. In the long run those >> kill projects. > > I don't want to start an unrelated GNU-politics thread, but... >... > In my opinion this is 100% the FSF's fault for creating such a broken > system, but it's the reality. More or less what I meant, yes. Keep in mind gcc development -already_ died once (egcs), and the lesson the llvm guys learned is "don't fork off the old dead base, even if it's been dead for years it's poison and they'll steal it back if you get it going again, instead start over from scratch with something they have no claim to". > So people who modify GNU stuff and who do want their work > to live on and be useful in the future already screwed up before the "and"; everything else is damage control. > This is really good news -- I think adding the patches should be easy. > You can probably just diff his tree against stock 5.2.0 and make it > one big combined patch. This makes getting stuff ready on the musl > side a lot more attractive to me, so I will try to get back to is > asap. FYI, the cortex-m toolchain I've been building (which builds a kernel and userspace that runs on the board) is just buildroot's cortex-m toolchain. Grab current buildroot, "make defconfig" then "make menuconfig" and: target options -> target architecture -> arm little endian target options -> target architecture variant -> cortex-m3 build options -> host dir (set to /opt/arm-linux) toolchain->enable c++ support Then "sudo make" (so it can write to /opt/arm-linux). The version of buildroot I had needed to do "ln -s arm-linux-ld.real /opt/arm-linux/usr/bin/ld.real" because the binflt wrapper is broken and evil, but maybe that's fixed upstream since? And the buildroot commit history disables -Os on cortex-m due to some compiler bug (maybe fixed now? Haven't hit it myself but I build with -O2 instead for this board on general principles.) Oh, and there's a separate "Enable elf2flt support" config thing in the toolchain menu that you DON'T want to select or it'll wrap the toolchain _twice_ and break, buildroot does it automatically for cortex-m. I think it's even a magic wrapper doing the -Wl,-elf2flt stuff automatically. :) > Rich > . Rob