From mboxrd@z Thu Jan 1 00:00:00 1970 From: Steve Grubb Subject: Re: Missing linker flags when statically linking Date: Sun, 10 Jul 2016 13:18:01 -0400 Message-ID: <1510754.00qYpxzr8S@x2> References: <270aeb86-be05-03f0-0983-10e199083f56@debian.org> <1593477.8QKBr1tzSR@x2> <8e8169d1-647f-4ff2-0003-29fe51fa8488@debian.org> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: <8e8169d1-647f-4ff2-0003-29fe51fa8488@debian.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-audit-bounces@redhat.com Errors-To: linux-audit-bounces@redhat.com To: Laurent Bigonville Cc: linux-audit@redhat.com List-Id: linux-audit@redhat.com On Sunday, July 10, 2016 10:45:13 AM EDT Laurent Bigonville wrote: > Le 09/07/16 =E0 23:41, Steve Grubb a =E9crit : > > On Saturday, July 9, 2016 11:02:44 PM EDT Laurent Bigonville wrote: > >> Apparently the fix is not 100% correct: > >> = > >> The "Libs.private" field should be _after_ the Libs one in the .pc fil= e, > >> otherwise the ordering of the libraries is not OK during liking: > >> = > >> -lcap-ng -laudit > >> = > >> it should be: -laudit -lcap-ng instead. > > = > > OK, I switched the order. > = > Thanks > = > >> Also any reasons you are using Libs.private instead of Package.private? > > = > > Libs.private is used to add flags for static linking. The dynamic linker > > shouldn't need a hint since libaudit its already linked to libcap-ng. > = > I was talking about Package*.private* not package itself. > Package.private is the equivalent to Libs.private but for libs that also > have a .pc file Do you mean Requires.private? (I don't see Package.private documented in th= e = man page.) That takes a package name which is not available from the m4 mac= ro = that libcap-ng provides. I think what this means is that I should switch fr= om = using m4 to pkg-config which means reworking configure.ac and the Makefiles= .am = wherever libcap-ng is used. I'll look into this, but I think in the meantim= e = what's in svn generally works. libcap-ng is most likley built with the same = flags that audit is. -Steve