From patchwork Thu Aug 10 12:30:22 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Florian Weimer X-Patchwork-Id: 800192 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=sourceware.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=libc-alpha-return-82975-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="R1mNSgXy"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3xSnYc2vq5z9t2k for ; Thu, 10 Aug 2017 22:31:16 +1000 (AEST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:to:subject:mime-version:content-type :content-transfer-encoding:message-id:from; q=dns; s=default; b= bV7gjfRFsBRWbarKGWLER4pWHZrJuOwX7xYDHpVj7qI1ypJPlKtyoTX25KLnHeJQ 7fyXXqCVw742nLmf2Nc+pWnabiWfkJnPNhRJgmh8EV1Jma0jPfGHgX6hZZSLOPNX CsYIhhZHbHZ2G7x18UGkHhzgJs2/0ulK/mmC6f0jVyk= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:to:subject:mime-version:content-type :content-transfer-encoding:message-id:from; s=default; bh=cB/BWs x4MpaKcFPf9lFDqQ305gk=; b=R1mNSgXyEeenlCTLS0m+oFVFFAd4T1fseUXsGi S7qHyfC087h++9Y024FJ36n5ofEc4Pe4biZCv7xDFxgU/4XFZ5V+8MO8W6e0fYIX wkJBZ9cA6RiZbkVK3rYzEI4sYSvW1WBs0oFlhn0LXupPh7hiEI7qeO3EXl0gztnP xtEuI= Received: (qmail 85849 invoked by alias); 10 Aug 2017 12:31:04 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 62886 invoked by uid 89); 10 Aug 2017 12:30:37 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.9 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RP_MATCHES_RCVD, SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=HContent-Transfer-Encoding:8bit X-HELO: mx1.redhat.com DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 90FFDC0079B1 Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx08.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=fweimer@redhat.com Date: Thu, 10 Aug 2017 14:30:22 +0200 To: libc-alpha@sourceware.org Subject: [PATCH] scripts/test-installation.pl: Handle NSS crypto libraries [BZ #21940] User-Agent: Heirloom mailx 12.5 7/5/10 MIME-Version: 1.0 Message-Id: <20170810123022.6DB7B439942E1@oldenburg.str.redhat.com> From: fweimer@redhat.com (Florian Weimer) The warning looked like this: Use of uninitialized value in string ne at …/scripts/test-installation.pl line 184, line 24. It is triggered by this line of ldd output: libfreebl3.so => /lib64/libfreebl3.so (0x00007f055003c000) The other lines have a version in the soname: libanl.so.1 => /lib64/libanl.so.1 (0x00007f055023f000) 2017-08-10 Florian Weimer [BZ #21940] * scripts/test-installation.pl: Handle NSS crypto libaries in ldd output. diff --git a/scripts/test-installation.pl b/scripts/test-installation.pl index 4b0e9f3c4a..466c526cc9 100755 --- a/scripts/test-installation.pl +++ b/scripts/test-installation.pl @@ -177,10 +177,15 @@ open LDD, "ldd /tmp/test-prg$$ |" or die ("Couldn't execute ldd"); while () { if (/^\s*lib/) { + # When libcrypt is linked against NSS, some of the referenced + # libraries do not have a trailing version in their soname. ($name, $version1, $version2) = - /^\s*lib(\w*)\.so\.([0-9\.]*)\s*=>.*\.so\.([0-9\.]*)/; + /^\s*lib(\w*)\.so(?:\.([0-9\.]*))?\s*=>.*\.so(?:\.([0-9\.]*))?/; $found{$name} = 1; - if ($versions{$name} ne $version1 || $version1 ne $version2) { + if (defined($version1) != defined($version2) + || defined($version1) != defined($versions{$name}) + || (defined($versions{$name}) + && ($versions{$name} ne $version1 || $version1 ne $version2))) { print "Library lib$name is not correctly installed.\n"; print "Please check your installation!\n"; print "Offending line of ldd output: $_\n";