From nobody Fri May 3 14:04:34 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1533747634274599.6679164906501; Wed, 8 Aug 2018 10:00:34 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 0CA201291; Wed, 8 Aug 2018 17:00:31 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id BD01060F8A; Wed, 8 Aug 2018 17:00:28 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 0DA944A460; Wed, 8 Aug 2018 17:00:24 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w78H0Mvu026693 for ; Wed, 8 Aug 2018 13:00:22 -0400 Received: by smtp.corp.redhat.com (Postfix) id B58DA87A8; Wed, 8 Aug 2018 17:00:22 +0000 (UTC) Received: from mx1.redhat.com (ext-mx05.extmail.prod.ext.phx2.redhat.com [10.5.110.29]) by smtp.corp.redhat.com (Postfix) with ESMTPS id AB36DD1CA for ; Wed, 8 Aug 2018 17:00:17 +0000 (UTC) Received: from smtp2.provo.novell.com (smtp2.provo.novell.com [137.65.250.81]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id EA1AA20277 for ; Wed, 8 Aug 2018 17:00:15 +0000 (UTC) Received: from linux-tbji.provo.novell.com (prv-ext-foundry1int.gns.novell.com [137.65.251.240]) by smtp2.provo.novell.com with ESMTP (NOT encrypted); Wed, 08 Aug 2018 11:00:10 -0600 From: Jim Fehlig To: libvir-list@redhat.com Date: Wed, 8 Aug 2018 11:00:01 -0600 Message-Id: <20180808170001.17225-1-jfehlig@suse.com> X-Greylist: Sender passed SPF test, Sender IP whitelisted by DNSRBL, ACL 212 matched, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.29]); Wed, 08 Aug 2018 17:00:16 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.29]); Wed, 08 Aug 2018 17:00:16 +0000 (UTC) for IP:'137.65.250.81' DOMAIN:'smtp2.provo.novell.com' HELO:'smtp2.provo.novell.com' FROM:'jfehlig@suse.com' RCPT:'' X-RedHat-Spam-Score: -2.301 (RCVD_IN_DNSWL_MED, SPF_PASS) 137.65.250.81 smtp2.provo.novell.com 137.65.250.81 smtp2.provo.novell.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.29 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH] Fix link errors in tools/nss and tests X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.29]); Wed, 08 Aug 2018 17:00:32 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" While local builds succeed fine, a build worker building in a chroot environment is encountering errors when linking some items in tools/nss and tests, e.g. [ 469s] libtool: link: gcc -shared -fPIC -DPIC -Wl,--whole-archive nss/.= libs/libnss_libvirt_impl.a -Wl,--no-whole-archive -lpthread -lutil -ltirpc= -fstack-protector-strong -grecord-gcc-switches -O2 -fstack-protector-stro= ng -g -Wl,--version-script=3D./nss/libvirt_nss.syms -Wl,-z -Wl,relro -Wl,-z= -Wl,now -Wl,--no-copy-dt-needed-entries -Wl,-z -Wl,defs -grecord-gcc-switc= hes -O2 -fstack-protector-strong -g -pthread -Wl,-soname -Wl,libnss_libvi= rt.so.2 -o nss/.libs/libnss_libvirt.so.2 [ 469s] nss/.libs/libnss_libvirt_impl.a(libvirt_nss_la-virjsoncompat.o): I= n function `virJSONJanssonOnce': [ 469s] /home/abuild/rpmbuild/BUILD/libvirt-4.6.0/src/util/virjsoncompat.c= :63: undefined reference to `dlopen' [ 469s] /home/abuild/rpmbuild/BUILD/libvirt-4.6.0/src/util/virjsoncompat.c= :79: undefined reference to `dlsym' ... A similar problem was fixed in commit b018ada3 and inspires this fix. Signed-off-by: Jim Fehlig Reviewed-by: Daniel P. Berrang=C3=A9 --- tools/Makefile.am | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tools/Makefile.am b/tools/Makefile.am index 1452d984a0..26c887649e 100644 --- a/tools/Makefile.am +++ b/tools/Makefile.am @@ -527,7 +527,8 @@ nss_libnss_libvirt_impl_la_CFLAGS =3D \ =20 nss_libnss_libvirt_impl_la_LIBADD =3D \ ../gnulib/lib/libgnu.la \ - ../src/libvirt-nss.la + ../src/libvirt-nss.la \ + $(DLOPEN_LIBS) =20 nss_libnss_libvirt_la_SOURCES =3D nss_libnss_libvirt_la_LDFLAGS =3D \ @@ -554,7 +555,8 @@ nss_libnss_libvirt_guest_impl_la_CFLAGS =3D \ =20 nss_libnss_libvirt_guest_impl_la_LIBADD =3D \ ../gnulib/lib/libgnu.la \ - ../src/libvirt-nss.la + ../src/libvirt-nss.la \ + $(DLOPEN_LIBS) =20 nss_libnss_libvirt_guest_la_SOURCES =3D nss_libnss_libvirt_guest_la_LDFLAGS =3D \ --=20 2.18.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list