From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/4970 Path: news.gmane.org!not-for-mail From: Isaac Dunham Newsgroups: gmane.linux.lib.musl.general Subject: Re: [PATCH 2/3] Add soname to dynamic section Date: Sun, 27 Apr 2014 22:54:22 -0700 Message-ID: <20140428055421.GA1429@muslin> References: <1398649434-23560-1-git-send-email-raj.khem@gmail.com> <1398649434-23560-2-git-send-email-raj.khem@gmail.com> <20140428020032.GU26358@brightrain.aerifal.cx> 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 1398664458 11203 80.91.229.3 (28 Apr 2014 05:54:18 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 28 Apr 2014 05:54:18 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-4974-gllmg-musl=m.gmane.org@lists.openwall.com Mon Apr 28 07:54:11 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 1WeeW3-0001zy-1v for gllmg-musl@plane.gmane.org; Mon, 28 Apr 2014 07:54:11 +0200 Original-Received: (qmail 17695 invoked by uid 550); 28 Apr 2014 05:54:10 -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 17683 invoked from network); 28 Apr 2014 05:54:10 -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=Sbwj7CxF2DLDf3MMGUNYAZiea5E0d2jBrKHsTXHQvsM=; b=is1XoAZlisq22DSZB2DyAEss4IfDg/DUDVIP0DG9SahfmkmVnLOSelZg6+dDQczMZb Bjm9YhIFxvcqzQmskT9FmDS4mz5C/Pwvod1oIfUok4CrX9phvlBVg1GqxblPcjowvY34 9fuBoN1CUZ/ULPff6FURK2RUe6BNLXqTaTRFRkiwnFbJjIcGSTpH+N4V6+m9lwY1ScLB StWEJG3sgrxcfH2g0bUFs/5WON6yktNzehm/sdSsYwc3kzpchaNkn3epEzn7Dwdn79Yu +JbJslbQZFahIj7hKMIr5phJNEpwCm5FfRElnFoPIS0b1gejD6SVW5qPhDhTNU89DujW YfRw== X-Received: by 10.66.218.193 with SMTP id pi1mr23391140pac.20.1398664437255; Sun, 27 Apr 2014 22:53:57 -0700 (PDT) Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Xref: news.gmane.org gmane.linux.lib.musl.general:4970 Archived-At: On Sun, Apr 27, 2014 at 10:02:45PM -0700, Khem Raj wrote: > On Sun, Apr 27, 2014 at 7:00 PM, Rich Felker wrote: > > This is intentionally omitted. If it exists on a system where glibc is > > also present, running ldconfig will create a symlink named libc.so in > > /lib pointing to ld-musl-$ARCH.so.1. > > > > What exactly are you trying to achieve by adding it? > > I am bootstrapping system using OpenEmbedded/musl and we use the > content of SONAME > to rename the library package as well as shlibs code then uses it to > for dependencies as well. I kept it libc.so for simplicity but it > could be a distinct name. Coexisting with glibc is not my usecase. > here. but if you have libc.so in /usr/lib then you are in conflict > with glibc anyway, how do you handle that ? Default configuration is to set libdir to /usr/local/musl/lib, and syslibdir to /lib. ld-musl-$ARCH.so.1 goes in syslibdir; the libc.so symlink is solely used for dynamic linking and goes in libdir. Putting libc.so in /usr/lib requires passing --prefix=/usr, as is specifically recommended against in INSTALL: DO NOT set the prefix to "/usr", "/usr/local", or "/" unless you're upgrading libc on an existing musl-based system. Doing so will break your system when you run "make install" and it may be difficult to recover. The SONAME used to be in the makefile, but was removed due to people encountering problems when they ran ldconfig. For the record, here's the approach I used to fix a Debian system that I hosed at least twice due to the SONAME causing trouble with ldconfig: -boot to a busybox ash or other static shell (root=... rw init=/bin/...) -manually correct the links if glibc is still installed; otherwise use "busybox dpkg -i /var/cache/apt/archives/..." and check that libc.so exists. -sync twice, then reboot. There are no problems with coxistence caused by the existing approach. Hope this clarifies things, Isaac Dunham