From patchwork Wed Feb 26 05:16:46 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: NeilBrown X-Patchwork-Id: 3721061 Return-Path: X-Original-To: patchwork-linux-nfs@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id E6E23BF13A for ; Wed, 26 Feb 2014 05:17:01 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2F41E201EF for ; Wed, 26 Feb 2014 05:17:01 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 2ABE92013D for ; Wed, 26 Feb 2014 05:17:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750745AbaBZFQ7 (ORCPT ); Wed, 26 Feb 2014 00:16:59 -0500 Received: from cantor2.suse.de ([195.135.220.15]:35046 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750712AbaBZFQ6 (ORCPT ); Wed, 26 Feb 2014 00:16:58 -0500 Received: from relay2.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 0173D7501F; Wed, 26 Feb 2014 05:16:57 +0000 (UTC) Date: Wed, 26 Feb 2014 16:16:46 +1100 From: NeilBrown To: Chuck Lever Cc: Steve Dickson , NFS Subject: What does rpc.mountd dlopen() libnfsjunct.so rather than libnfsjunct.so.0 Message-ID: <20140226161646.1520358b@notabene.brown> X-Mailer: Claws Mail 3.9.2 (GTK+ 2.24.22; x86_64-suse-linux-gnu) Mime-Version: 1.0 Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_TVD_MIME_EPI, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP See $SUBJ Shared libraries are usually versioned so you can release a new version with an incompatible API and gradually transition to it. A rpc.mountd dlopens libnfsjunct.so with no version it is effectively prohibited from ever changing the API in an incompatible way. Both Fedora and openSUSE get upset about packaging a libFOO.so in a non "-devel" package and so trip over this library which clearly needs to be installed even if you aren't doing 'devel'opment. I would like to change mountd as per the patch below to use the ".0" file. I believe this will not break any installation as the ".so" is installed as a symlink to the ".0" (or maybe ".0.0.0"). Would this be acceptable? There is a bit of a discussion about this here: https://bugzilla.redhat.com/show_bug.cgi?id=889174 but I either don't understand it or don't agree with it. Thanks, NeilBrown diff --git a/utils/mountd/cache.c b/utils/mountd/cache.c index ca35de28847a..f6d78490954f 100644 --- a/utils/mountd/cache.c +++ b/utils/mountd/cache.c @@ -1139,7 +1139,7 @@ static struct exportent *lookup_junction(char *dom, const char *pathname, struct link_map *map; void *handle; - handle = dlopen("libnfsjunct.so", RTLD_NOW); + handle = dlopen("libnfsjunct.so.0", RTLD_NOW); if (handle == NULL) { xlog(D_GENERAL, "%s: dlopen: %s", __func__, dlerror()); return NULL;