From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/2333 Path: news.gmane.org!not-for-mail From: Florian Fainelli Newsgroups: gmane.comp.embedded.openwrt.devel,gmane.linux.lib.musl.general Subject: Re: [musl] Support for musl libc in OpenWrt Date: Sun, 25 Nov 2012 12:46:26 +0100 Message-ID: <201211251246.27100.florian@openwrt.org> References: <50AFD839.9010408@openwrt.org> <20121123221533.eb6d941c.idunham@lavabit.com> Reply-To: OpenWrt Development List NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1353843992 17220 80.91.229.3 (25 Nov 2012 11:46:32 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 25 Nov 2012 11:46:32 +0000 (UTC) Cc: Isaac Dunham , openwrt-devel@lists.openwrt.org To: musl@lists.openwall.com Original-X-From: openwrt-devel-bounces@lists.openwrt.org Sun Nov 25 12:46:44 2012 Return-path: Envelope-to: gceod-openwrt-devel@m.gmane.org Original-Received: from arrakis.dune.hu ([78.24.191.176]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TcafZ-0003hi-Jc for gceod-openwrt-devel@m.gmane.org; Sun, 25 Nov 2012 12:46:41 +0100 Original-Received: from arrakis.dune.hu ([127.0.0.1]) by localhost (arrakis.dune.hu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5Huv-Q-ucdAN; Sun, 25 Nov 2012 12:45:57 +0100 (CET) Original-Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id A235C28098F; Sun, 25 Nov 2012 12:45:57 +0100 (CET) Original-Received: from arrakis.dune.hu ([127.0.0.1]) by localhost (arrakis.dune.hu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id kyZ8jHtCG2dd for ; Sun, 25 Nov 2012 12:45:57 +0100 (CET) Original-Received: from mail-wi0-f170.google.com (mail-wi0-f170.google.com [209.85.212.170]) by arrakis.dune.hu (Postfix) with ESMTPS id 35FBF280835 for ; Sun, 25 Nov 2012 12:45:57 +0100 (CET) Original-Received: by mail-wi0-f170.google.com with SMTP id hq7so2237126wib.1 for ; Sun, 25 Nov 2012 03:46:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:content-type:content-transfer-encoding:message-id; bh=7HeOqQbj94zsEKPDLwMTPbTAX9kds+aE6qRXVKkyKAE=; b=KcWpFRH3Dblmfv+mIAONJMA0zJwMlfZWae1yq1RDyc+xNQETzFENMx8ybzaYNm4oIo RPQocZ5OTeiEVB3UjPxICw7K3yGNbQ4Ypo9H1S8ZL031hyxb+O0GJ7Mpb8lVvK8AWopQ VvT2ghnh6zcNwMPiI2ZjCvbmEHCtGuypP3twVBOqOuXYpRuoUAk/9YRuztR7sFz4N3kz g+gQ9i8f42qAgulWMp+dnhLhYvGM0AxvxSRCYKqWAD0dM7uwnfMudvG1qJLK0Pf9Urk0 UfkXc6Yrl01yUEUnpVioweDtqfjJS3HVqsbuVtXOB66Iay9xeNM4Dg8EWERrp3Faiy8U MGsg== Original-Received: by 10.180.7.197 with SMTP id l5mr16454975wia.13.1353843989108; Sun, 25 Nov 2012 03:46:29 -0800 (PST) Original-Received: from lenovo.localnet ([2a01:e35:2f70:4010:21d:7dff:fe45:5399]) by mx.google.com with ESMTPS id em6sm1605753wib.0.2012.11.25.03.46.28 (version=SSLv3 cipher=OTHER); Sun, 25 Nov 2012 03:46:28 -0800 (PST) In-Reply-To: <20121123221533.eb6d941c.idunham@lavabit.com> X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: openwrt-devel-bounces@lists.openwrt.org Original-Sender: "openwrt-devel" Xref: news.gmane.org gmane.comp.embedded.openwrt.devel:16421 gmane.linux.lib.musl.general:2333 Archived-At: Le samedi 24 novembre 2012 07:15:33, Isaac Dunham a =E9crit : > On Fri, 23 Nov 2012 21:10:33 +0100 > = > Florian Fainelli wrote: > > Hi All, > > = > > Support for musl libc in OpenWrt has been added in revision r34314, > = > Glad to hear it! > = > > Note that the following issues are known: > > = > > - unable to complete libstdc++ build due to some missing declarations > > (WIP) > = > Are you using the default "linux-gnu" libstdc++, or the "generic" target? > Only the latter is known to work at this point. It is the linux-gnu libstdc++, we do not support building the "generic" one = yet, might be worth supporting it now. > = > > - MIPS and MIPSel ports are not functionnal (details below) > > = > > -- > > MIPS and MIPSel specific issues: > > = > > using qemu's binary emulation (qemu-mips[el]) against a statically > > linked binary works, a dynamic binary makes my host qemu segv. Using > > qemu-system-mips[el], the binary segfaults while being executed by the > > kernel. So far I have not had the time to debug this further. > = > There are likely other issues, but are you using a hardfloat-compatible > kernel (FPU emulation enabled)? = No, we have patched the kernel do disable the hardware FPU emulation, which = was actually the issue, because musl setjmp MIPS-specific code tried to acc= ess = Cop1 registers. After patching setjmp not to access these it works flawless= ly = on MIPS (big-endian) but MIPS (little-endian) still segfaults while being = executed either from the kernel or qemu-mipsel. > At present, musl/mips relies on certain > instructions that the kernel ordinarily emulates when they aren't > supported. You mean ll/sc right? I build for MIPS32r2 so this should not be an issue. -- = Florian