From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/9769 Path: news.gmane.org!not-for-mail From: Rashad Kanavath Newsgroups: gmane.linux.lib.musl.general Subject: Re: using musl with a c++ library. Date: Tue, 29 Mar 2016 13:41:31 +0200 Message-ID: References: <95A8D906-77D6-429E-93F5-E859974D593B@shiz.me> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a113f998c08821f052f2e8513 X-Trace: ger.gmane.org 1459251753 2130 80.91.229.3 (29 Mar 2016 11:42:33 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 29 Mar 2016 11:42:33 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-9782-gllmg-musl=m.gmane.org@lists.openwall.com Tue Mar 29 13:42:26 2016 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1aks2T-0007WH-N6 for gllmg-musl@m.gmane.org; Tue, 29 Mar 2016 13:42:25 +0200 Original-Received: (qmail 28493 invoked by uid 550); 29 Mar 2016 11:42:23 -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 28474 invoked from network); 29 Mar 2016 11:42:22 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=VV8rd6RYGWXIqC0rQ+SGZDoZFO16a+yB/9Q0BT4md30=; b=HInEIrfAsZtEnH2QV1N+lSrLqpdOLCoh9FneXOBfLCBPS/1YVsZd519xcSKD263pcI Sso8pIFjCO3NQTHDOyogxB9fKFrmg9U/P6bc4ZaehdKY6/f1A4TPN+87/G7t21X3lHQS sRK/jZFF187o93jQejb0v1YyMIwAUpmBvIP2stldgMAXIbiadoDJg4EWWMJDWpuiyjJX U+e08p0sCQWRFI9QBZHDZJTkOKpxNr6Rt4qYKTsJ9cAcythhpevxrSCXJecW6vX2v7SG BO3sWf7zF/s2bA+cZajHGOmkVwyE1b1uASerClBocNlt0zbfnVTLqs86F2hZcA3igyNN S45g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=VV8rd6RYGWXIqC0rQ+SGZDoZFO16a+yB/9Q0BT4md30=; b=nJaoPMNpHXuMV4f38wmiJN1Yjcl+mtx228+iVaO/Zi86AcDPafMgRxWMpdJyHf9xbv 63Cz9+YLo2YPd8VN64E6/OXl6EAPSAjOTBI793lB+Bwd/vC8coyPxpFE8HJlCVD6k4T4 mnuw6FosGML9l8btquQj6rT7bzeMRJEnWeQveg1ZJs7dj2Azpa/0FbGUkJ6vJAkM7DkF oxCHf3TIUwTW6dD1S++6wg/Y4NyjSKidJulz+9/H9thNk1VGTMOId0T0gqXAFGiBTUqo eAlqoZhFsrv3S/PojAH3k6kSPeLBFEhbgk5FD6ejUkhIsKqBQu4teCeVwNtLL3+PFxD+ raEA== X-Gm-Message-State: AD7BkJJziFtRryUGfZH6syTnpph3C03os90mWpL3VYLnYdCc1eWk2g9YXFvPLtEnRmWuCwSG8tswF3k0fy0heA== X-Received: by 10.107.7.72 with SMTP id 69mr2473609ioh.107.1459251730480; Tue, 29 Mar 2016 04:42:10 -0700 (PDT) In-Reply-To: <95A8D906-77D6-429E-93F5-E859974D593B@shiz.me> Xref: news.gmane.org gmane.linux.lib.musl.general:9769 Archived-At: --001a113f998c08821f052f2e8513 Content-Type: text/plain; charset=UTF-8 Hello Shiz, Thanks for your reply. I will try links you said and let you know how it goes.. On Tue, Mar 29, 2016 at 12:26 PM, Shiz wrote: > > > On 29 Mar 2016, at 11:02, Rashad Kanavath > wrote: > > > > should I rebuild just libstdc++ using musl-gcc wrapper script and use > that libstdc++ ?. > > I believe the current recommendation is to not use musl-gcc at all for C++ > stuff, > but just build a proper musl-native toolchain. Recipes for such can be > found at [1] and [2]. > musl-gcc is just a wrapper for convenience, but definitely not a > replacement for a proper > native toolchain. > > > Also Is it possible to distribute musl with an application package. > Currently I have a self-extracting archive which uses an older version of > glibc. so it will run on any platform that has a glibc version higher that > it was build (2.4). If I use musl and is able to distribute it along with > my application package, Then I don't have to rely on anything other than > linux kernel version on the target platform. > > Yes, as musl is licensed under the MIT license, this is allowed. > You could even statically link against it to be able to ship just a single > binary file. > > - Shiz > > [1]: https://bitbucket.org/GregorR/musl-cross > [2]: https://github.com/richfelker/musl-cross-make > -- Regards, Rashad --001a113f998c08821f052f2e8513 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hello Shiz,

Thanks for your reply. I wil= l try links you said and let you know how it goes..

On Tue, Mar 29, 2016 at 12:26 P= M, Shiz <hi@shiz.me> wrote:

> On 29 Mar 2016, at 11:02, Rashad Kanavath <mohammedrashadkm@gmail.com> wrote:
>
> should I rebuild just libstdc++ using musl-gcc wrapper script and use = that libstdc++ ?.

I believe the current recommendation is to not use musl-gcc at all f= or C++ stuff,
but just build a proper musl-native toolchain. Recipes for such can be foun= d at [1] and [2].
musl-gcc is just a wrapper for convenience, but definitely not a replacemen= t for a proper
native toolchain.

> Also Is it possible to distribute musl with an application package. Cu= rrently I have a self-extracting archive which uses an older version of gli= bc. so it will run on any platform that has a glibc version higher that it = was build (2.4). If I use musl and is able to distribute it along with my a= pplication package, Then I don't have to rely on anything other than li= nux kernel version on the target platform.

Yes, as musl is licensed under the MIT license, this is allowed.
You could even statically link against it to be able to ship just a single = binary file.

- Shiz

[1]: https://bitbucket.org/GregorR/musl-cross
[2]: https://github.com/richfelker/musl-cross-make<= br>



--
Regards,
=C2=A0= =C2=A0Rashad
--001a113f998c08821f052f2e8513--