From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/9006 Path: news.gmane.org!not-for-mail From: Isaac Dunham Newsgroups: gmane.linux.lib.musl.general Subject: Re: musl & proprietary programs Date: Wed, 23 Dec 2015 23:00:52 -0800 Message-ID: <20151224070051.GA5769@newbook> References: <20151222132706.57214aa6@vostro> <20151222222513.10f23f5a@r2lynx> <20151223144852.GR23362@port70.net> <20151224002205.588ac8e8@r2lynx> <20151223174352.GA238@brightrain.aerifal.cx> <20151224015135.34dfe5f4@r2lynx> 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 1450940475 22919 80.91.229.3 (24 Dec 2015 07:01:15 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 24 Dec 2015 07:01:15 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-9019-gllmg-musl=m.gmane.org@lists.openwall.com Thu Dec 24 08:01:12 2015 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 1aBztf-0001DP-GN for gllmg-musl@m.gmane.org; Thu, 24 Dec 2015 08:01:11 +0100 Original-Received: (qmail 13470 invoked by uid 550); 24 Dec 2015 07:01:09 -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 13452 invoked from network); 24 Dec 2015 07:01:09 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=gf2sFAzkOPxoOzsip79Cnd3qjYqr/Puhc0tuuRS4qlk=; b=AagtYojFee3Uz8gIJEPQGf95YEc4VwvDhkmLC4GgpSkS4f8alyNeXaL7nnwSO8H+S+ qlftFCGJESWX1Bole+yvHqmAVpaKUQ3HWrxPHygMFPyc84QqGMjZyDRLRnz7qYmivec8 te2fGmGyWSMkIaeFwGbypq65bh7ZbZNL69Lb82fs4UB3SGst72kFpXlBBJ6ay1xbSv0q MzcA1OZgDZoMjrA29pDA2EmTHcMmd6rYLzAKM5ri97gKesH2Hh46TBsLntN0k7Yks1S7 A8LAPXHm38q0Dssf/87455TG/N3eHZOsFPdNVRcaEFshHzznlJCtXSNRPVqQIrwYQGZV pSDA== X-Received: by 10.66.120.200 with SMTP id le8mr50085384pab.61.1450940457410; Wed, 23 Dec 2015 23:00:57 -0800 (PST) Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) Xref: news.gmane.org gmane.linux.lib.musl.general:9006 Archived-At: On Wed, Dec 23, 2015 at 06:00:12PM -0200, Alba Pompeo wrote: > I also don't want to pollute my system with glibc. That's why I asked > if there was any plan to improve musl support of proprietary programs > like the ones I listed. I looked through the thread and saw no list of proprietary programs. (Is this undelivered mail? is google bouncing random emails?) > But as a last resort, I think Rich's method is the best so far, but > I'm a bit lost on the details since I'm not a libc expert. > I couldn't find a wiki page detailing Rich's method on Void or Alpine > (the 2 distros I know use musl). Is there a step-by-step for a novice > somewhere? I don't know of any step-by-step guide that covers what you're asking about, but I have done it before. The important things: * glibc uses paths configured in /etc/ld.so.conf, which these days usually just says "include /etc/ld.so.conf.d/*.conf". Those files, in turn, contain a newline-separated list of directories which are searched for libraries. musl uses /etc/ld-musl-$ARCH.path instead; this is a simple newline or colon separated list of directories. * with Debian's default configuration, the directories which glibc searches are {/usr/,/}lib/linux-$CPU-gnu, and /usr/local/lib. Delete /etc/ld.so.conf.d/libc.conf, and the library directory structure will have no conflicts with musl. * there are two possible approaches: - build a glibc chroot, drop a few links in /lib, put a few files in /etc, and you redirect glibc applications to the libraries in the chroot. - assemble a set of library packages, extract them, make sure there won't be conflicts, and copy it over into the root (so that you have both an Alpine install and a portion of a Debian install, with the same root) Only feasible with "multiarch-enabled" guest distros, meaning Debian and relatives. For the "use a chroot" approach, you will probably want to do something like this (assumes "guest" chroot in /opt/glibc-sys) touch /etc/ld.so.nohwcap sed -e 's|^/|/opt/glibc-sys/|' /opt/glibc-sys/etc/ld.so.conf.d/*.conf \ >/etc/ld.so.conf For the "parallel install" approach, I'd create a list of files that are both the glibc library set and the host, sort through them to figure out if they're needed/how to change them, and then do something like this (from the root of wherever you've extracted the libs to): rm ./etc/ld.so.conf.d/libc.conf find ./ | grep -v -x -F -f ../glibc-alpine-dupes | cpio -p / touch /etc/ld.so.nohwcap (This assumes that the list of duplicates is in the format: ./etc/passwd ...) HTH, Isaac Dunham