From owner-svn-ports-all@freebsd.org Sun Mar 12 12:26:34 2017 Return-Path: Delivered-To: svn-ports-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AE565D091FB; Sun, 12 Mar 2017 12:26:34 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2610:1c1:1:6074::16:84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 888381EB4; Sun, 12 Mar 2017 12:26:34 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: by freefall.freebsd.org (Postfix, from userid 1033) id DB4EDCED; Sun, 12 Mar 2017 12:26:33 +0000 (UTC) Date: Sun, 12 Mar 2017 12:26:33 +0000 From: Alexey Dokuchaev To: Matthew Rezny Cc: Adam Weinberger , Tijl Coosemans , ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org, swills@freebsd.org, gnome@freebsd.org Subject: Re: svn commit: r435961 - in head/www/webkit-gtk2: . files Message-ID: <20170312122633.GB43736@FreeBSD.org> References: <201703112115.v2BLF3qk062113@repo.freebsd.org> <1651531.nGg9pBWiG5@workstation.reztek> <96D05335-EC74-4CD0-9F00-95CC02B62CF8@adamw.org> <6528743.Wv2563vc2k@workstation.reztek> <20170312120533.GA43736@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170312120533.GA43736@FreeBSD.org> User-Agent: Mutt/1.7.1 (2016-10-04) X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 12:26:34 -0000 On Sun, Mar 12, 2017 at 12:05:33PM +0000, Alexey Dokuchaev wrote: > On Sun, Mar 12, 2017 at 03:10:09AM +0100, Matthew Rezny wrote: > > Many ports that use gnutls produce warnings from stage-qa because gnutls > > depends on libgcrypt which depends on libgpg-error, and while I sometime > > see libgcrypt alongside gnutls, I rarely notice libgpg-error alongside > > either, and I find myself frequently adding both. [...] > > > > Should every port using libgcrypt have to depend on libgpg-error when > > libgcrypt already depends on it, or is the stage-qa check over aggressive? > > `Mk/Scripts/qa.sh' is doing what it can: that is, what readelf(1) tells > it. Technically no, not every port using libgcrypt has to depend on > libgpg-error, as long as you link with -lgcrypt only and it's sufficient. > However, libgpg-error is pulled by default via libgcrypt's config script: > > $ /usr/local/bin/libgcrypt-config --libs > -L/usr/local/lib -lgcrypt -lgpg-error > > [...] Another approach is to use -Wl,--as-needed option After checking with Ulrich Drepper's paper [1] looks like lazyman's version of the above with overlinking prevented should be this: -Wl,--as-needed -lgcrypt -lgpg-error -Wl,--no-as-needed One might also find this page [2] useful. ./danfe [1] http://www.akkadia.org/drepper/dsohowto.pdf, p.41 [2] http://wiki.rosalab.ru/ru/index.php/Overlinking