render / rpms / qemu

Forked from rpms/qemu 9 months ago
Clone

Blame 0001-libcacard-stop-linking-against-every-single-3rd-part.patch

Daniel P. Berrange fc57f4
From e7039b9919f637cebf453d45f407d823ba52b423 Mon Sep 17 00:00:00 2001
Daniel P. Berrange fc57f4
From: "Daniel P. Berrange" <berrange@redhat.com>
Daniel P. Berrange fc57f4
Date: Tue, 3 Feb 2015 11:27:52 +0000
Daniel P. Berrange fc57f4
Subject: [PATCH] libcacard: stop linking against every single 3rd party
Daniel P. Berrange fc57f4
 library
Daniel P. Berrange fc57f4
Daniel P. Berrange fc57f4
Building QEMU results in a libcacard.so that links against
Daniel P. Berrange fc57f4
practically the entire world
Daniel P. Berrange fc57f4
Daniel P. Berrange fc57f4
	linux-vdso.so.1 =>  (0x00007fff71e99000)
Daniel P. Berrange fc57f4
	libssl3.so => /usr/lib64/libssl3.so (0x00007f49f94b6000)
Daniel P. Berrange fc57f4
	libsmime3.so => /usr/lib64/libsmime3.so (0x00007f49f928e000)
Daniel P. Berrange fc57f4
	libnss3.so => /usr/lib64/libnss3.so (0x00007f49f8f67000)
Daniel P. Berrange fc57f4
	libnssutil3.so => /usr/lib64/libnssutil3.so (0x00007f49f8d3b000)
Daniel P. Berrange fc57f4
	libplds4.so => /usr/lib64/libplds4.so (0x00007f49f8b36000)
Daniel P. Berrange fc57f4
	libplc4.so => /usr/lib64/libplc4.so (0x00007f49f8931000)
Daniel P. Berrange fc57f4
	libnspr4.so => /usr/lib64/libnspr4.so (0x00007f49f86f2000)
Daniel P. Berrange fc57f4
	libdl.so.2 => /usr/lib64/libdl.so.2 (0x00007f49f84ed000)
Daniel P. Berrange fc57f4
	libm.so.6 => /usr/lib64/libm.so.6 (0x00007f49f81e5000)
Daniel P. Berrange fc57f4
	libgthread-2.0.so.0 => /usr/lib64/libgthread-2.0.so.0 (0x00007f49f7fe3000)
Daniel P. Berrange fc57f4
	librt.so.1 => /usr/lib64/librt.so.1 (0x00007f49f7dda000)
Daniel P. Berrange fc57f4
	libz.so.1 => /usr/lib64/libz.so.1 (0x00007f49f7bc4000)
Daniel P. Berrange fc57f4
	libcap-ng.so.0 => /usr/lib64/libcap-ng.so.0 (0x00007f49f79be000)
Daniel P. Berrange fc57f4
	libuuid.so.1 => /usr/lib64/libuuid.so.1 (0x00007f49f77b8000)
Daniel P. Berrange fc57f4
	libgnutls.so.28 => /usr/lib64/libgnutls.so.28 (0x00007f49f749a000)
Daniel P. Berrange fc57f4
	libSDL-1.2.so.0 => /usr/lib64/libSDL-1.2.so.0 (0x00007f49f71fd000)
Daniel P. Berrange fc57f4
	libpthread.so.0 => /usr/lib64/libpthread.so.0 (0x00007f49f6fe0000)
Daniel P. Berrange fc57f4
	libvte.so.9 => /usr/lib64/libvte.so.9 (0x00007f49f6d3f000)
Daniel P. Berrange fc57f4
	libXext.so.6 => /usr/lib64/libXext.so.6 (0x00007f49f6b2d000)
Daniel P. Berrange fc57f4
	libgtk-x11-2.0.so.0 => /usr/lib64/libgtk-x11-2.0.so.0 (0x00007f49f64a0000)
Daniel P. Berrange fc57f4
	libgdk-x11-2.0.so.0 => /usr/lib64/libgdk-x11-2.0.so.0 (0x00007f49f61de000)
Daniel P. Berrange fc57f4
	libpangocairo-1.0.so.0 => /usr/lib64/libpangocairo-1.0.so.0 (0x00007f49f5fd1000)
Daniel P. Berrange fc57f4
	libatk-1.0.so.0 => /usr/lib64/libatk-1.0.so.0 (0x00007f49f5daa000)
Daniel P. Berrange fc57f4
	libcairo.so.2 => /usr/lib64/libcairo.so.2 (0x00007f49f5a9d000)
Daniel P. Berrange fc57f4
	libgdk_pixbuf-2.0.so.0 => /usr/lib64/libgdk_pixbuf-2.0.so.0 (0x00007f49f5878000)
Daniel P. Berrange fc57f4
	libgio-2.0.so.0 => /usr/lib64/libgio-2.0.so.0 (0x00007f49f5500000)
Daniel P. Berrange fc57f4
	libpangoft2-1.0.so.0 => /usr/lib64/libpangoft2-1.0.so.0 (0x00007f49f52eb000)
Daniel P. Berrange fc57f4
	libpango-1.0.so.0 => /usr/lib64/libpango-1.0.so.0 (0x00007f49f50a0000)
Daniel P. Berrange fc57f4
	libgobject-2.0.so.0 => /usr/lib64/libgobject-2.0.so.0 (0x00007f49f4e4e000)
Daniel P. Berrange fc57f4
	libglib-2.0.so.0 => /usr/lib64/libglib-2.0.so.0 (0x00007f49f4b15000)
Daniel P. Berrange fc57f4
	libfontconfig.so.1 => /usr/lib64/libfontconfig.so.1 (0x00007f49f48d6000)
Daniel P. Berrange fc57f4
	libfreetype.so.6 => /usr/lib64/libfreetype.so.6 (0x00007f49f462b000)
Daniel P. Berrange fc57f4
	libX11.so.6 => /usr/lib64/libX11.so.6 (0x00007f49f42e8000)
Daniel P. Berrange fc57f4
	libxenstore.so.3.0 => /usr/lib64/libxenstore.so.3.0 (0x00007f49f40de000)
Daniel P. Berrange fc57f4
	libxenctrl.so.4.4 => /usr/lib64/libxenctrl.so.4.4 (0x00007f49f3eb6000)
Daniel P. Berrange fc57f4
	libxenguest.so.4.4 => /usr/lib64/libxenguest.so.4.4 (0x00007f49f3c8b000)
Daniel P. Berrange fc57f4
	libseccomp.so.2 => /usr/lib64/libseccomp.so.2 (0x00007f49f3a74000)
Daniel P. Berrange fc57f4
	librdmacm.so.1 => /usr/lib64/librdmacm.so.1 (0x00007f49f385d000)
Daniel P. Berrange fc57f4
	libibverbs.so.1 => /usr/lib64/libibverbs.so.1 (0x00007f49f364a000)
Daniel P. Berrange fc57f4
	libutil.so.1 => /usr/lib64/libutil.so.1 (0x00007f49f3447000)
Daniel P. Berrange fc57f4
	libc.so.6 => /usr/lib64/libc.so.6 (0x00007f49f3089000)
Daniel P. Berrange fc57f4
	/lib64/ld-linux-x86-64.so.2 (0x00007f49f9902000)
Daniel P. Berrange fc57f4
	libp11-kit.so.0 => /usr/lib64/libp11-kit.so.0 (0x00007f49f2e23000)
Daniel P. Berrange fc57f4
	libtspi.so.1 => /usr/lib64/libtspi.so.1 (0x00007f49f2bb2000)
Daniel P. Berrange fc57f4
	libtasn1.so.6 => /usr/lib64/libtasn1.so.6 (0x00007f49f299f000)
Daniel P. Berrange fc57f4
	libnettle.so.4 => /usr/lib64/libnettle.so.4 (0x00007f49f276d000)
Daniel P. Berrange fc57f4
	libhogweed.so.2 => /usr/lib64/libhogweed.so.2 (0x00007f49f2545000)
Daniel P. Berrange fc57f4
	libgmp.so.10 => /usr/lib64/libgmp.so.10 (0x00007f49f22cd000)
Daniel P. Berrange fc57f4
	libncurses.so.5 => /usr/lib64/libncurses.so.5 (0x00007f49f20a5000)
Daniel P. Berrange fc57f4
	libtinfo.so.5 => /usr/lib64/libtinfo.so.5 (0x00007f49f1e7a000)
Daniel P. Berrange fc57f4
	libgmodule-2.0.so.0 => /usr/lib64/libgmodule-2.0.so.0 (0x00007f49f1c76000)
Daniel P. Berrange fc57f4
	libXfixes.so.3 => /usr/lib64/libXfixes.so.3 (0x00007f49f1a6f000)
Daniel P. Berrange fc57f4
	libXrender.so.1 => /usr/lib64/libXrender.so.1 (0x00007f49f1865000)
Daniel P. Berrange fc57f4
	libXinerama.so.1 => /usr/lib64/libXinerama.so.1 (0x00007f49f1662000)
Daniel P. Berrange fc57f4
	libXi.so.6 => /usr/lib64/libXi.so.6 (0x00007f49f1452000)
Daniel P. Berrange fc57f4
	libXrandr.so.2 => /usr/lib64/libXrandr.so.2 (0x00007f49f1247000)
Daniel P. Berrange fc57f4
	libXcursor.so.1 => /usr/lib64/libXcursor.so.1 (0x00007f49f103c000)
Daniel P. Berrange fc57f4
	libXcomposite.so.1 => /usr/lib64/libXcomposite.so.1 (0x00007f49f0e39000)
Daniel P. Berrange fc57f4
	libXdamage.so.1 => /usr/lib64/libXdamage.so.1 (0x00007f49f0c35000)
Daniel P. Berrange fc57f4
	libharfbuzz.so.0 => /usr/lib64/libharfbuzz.so.0 (0x00007f49f09dd000)
Daniel P. Berrange fc57f4
	libpixman-1.so.0 => /usr/lib64/libpixman-1.so.0 (0x00007f49f072f000)
Daniel P. Berrange fc57f4
	libEGL.so.1 => /usr/lib64/libEGL.so.1 (0x00007f49f0505000)
Daniel P. Berrange fc57f4
	libpng16.so.16 => /usr/lib64/libpng16.so.16 (0x00007f49f02d2000)
Daniel P. Berrange fc57f4
	libxcb-shm.so.0 => /usr/lib64/libxcb-shm.so.0 (0x00007f49f00cd000)
Daniel P. Berrange fc57f4
	libxcb-render.so.0 => /usr/lib64/libxcb-render.so.0 (0x00007f49efec3000)
Daniel P. Berrange fc57f4
	libxcb.so.1 => /usr/lib64/libxcb.so.1 (0x00007f49efca1000)
Daniel P. Berrange fc57f4
	libGL.so.1 => /usr/lib64/libGL.so.1 (0x00007f49efa06000)
Daniel P. Berrange fc57f4
	libffi.so.6 => /usr/lib64/libffi.so.6 (0x00007f49ef7fe000)
Daniel P. Berrange fc57f4
	libselinux.so.1 => /usr/lib64/libselinux.so.1 (0x00007f49ef5d8000)
Daniel P. Berrange fc57f4
	libresolv.so.2 => /usr/lib64/libresolv.so.2 (0x00007f49ef3be000)
Daniel P. Berrange fc57f4
	libexpat.so.1 => /usr/lib64/libexpat.so.1 (0x00007f49ef193000)
Daniel P. Berrange fc57f4
	libbz2.so.1 => /usr/lib64/libbz2.so.1 (0x00007f49eef83000)
Daniel P. Berrange fc57f4
	libgcc_s.so.1 => /usr/lib64/libgcc_s.so.1 (0x00007f49eed6c000)
Daniel P. Berrange fc57f4
	liblzma.so.5 => /usr/lib64/liblzma.so.5 (0x00007f49eeb46000)
Daniel P. Berrange fc57f4
	libnl-route-3.so.200 => /usr/lib64/libnl-route-3.so.200 (0x00007f49ee8e2000)
Daniel P. Berrange fc57f4
	libnl-3.so.200 => /usr/lib64/libnl-3.so.200 (0x00007f49ee6c4000)
Daniel P. Berrange fc57f4
	libcrypto.so.10 => /usr/lib64/libcrypto.so.10 (0x00007f49ee2d6000)
Daniel P. Berrange fc57f4
	libssl.so.10 => /usr/lib64/libssl.so.10 (0x00007f49ee067000)
Daniel P. Berrange fc57f4
	libgraphite2.so.3 => /usr/lib64/libgraphite2.so.3 (0x00007f49ede48000)
Daniel P. Berrange fc57f4
	libX11-xcb.so.1 => /usr/lib64/libX11-xcb.so.1 (0x00007f49edc46000)
Daniel P. Berrange fc57f4
	libxcb-dri2.so.0 => /usr/lib64/libxcb-dri2.so.0 (0x00007f49eda41000)
Daniel P. Berrange fc57f4
	libxcb-xfixes.so.0 => /usr/lib64/libxcb-xfixes.so.0 (0x00007f49ed838000)
Daniel P. Berrange fc57f4
	libxcb-shape.so.0 => /usr/lib64/libxcb-shape.so.0 (0x00007f49ed634000)
Daniel P. Berrange fc57f4
	libgbm.so.1 => /usr/lib64/libgbm.so.1 (0x00007f49ed426000)
Daniel P. Berrange fc57f4
	libwayland-client.so.0 => /usr/lib64/libwayland-client.so.0 (0x00007f49ed217000)
Daniel P. Berrange fc57f4
	libwayland-server.so.0 => /usr/lib64/libwayland-server.so.0 (0x00007f49ed005000)
Daniel P. Berrange fc57f4
	libglapi.so.0 => /usr/lib64/libglapi.so.0 (0x00007f49ecddb000)
Daniel P. Berrange fc57f4
	libdrm.so.2 => /usr/lib64/libdrm.so.2 (0x00007f49ecbce000)
Daniel P. Berrange fc57f4
	libXau.so.6 => /usr/lib64/libXau.so.6 (0x00007f49ec9ca000)
Daniel P. Berrange fc57f4
	libxcb-glx.so.0 => /usr/lib64/libxcb-glx.so.0 (0x00007f49ec7b0000)
Daniel P. Berrange fc57f4
	libxcb-dri3.so.0 => /usr/lib64/libxcb-dri3.so.0 (0x00007f49ec5ad000)
Daniel P. Berrange fc57f4
	libxcb-present.so.0 => /usr/lib64/libxcb-present.so.0 (0x00007f49ec3aa000)
Daniel P. Berrange fc57f4
	libxcb-randr.so.0 => /usr/lib64/libxcb-randr.so.0 (0x00007f49ec19b000)
Daniel P. Berrange fc57f4
	libxcb-sync.so.1 => /usr/lib64/libxcb-sync.so.1 (0x00007f49ebf94000)
Daniel P. Berrange fc57f4
	libxshmfence.so.1 => /usr/lib64/libxshmfence.so.1 (0x00007f49ebd91000)
Daniel P. Berrange fc57f4
	libXxf86vm.so.1 => /usr/lib64/libXxf86vm.so.1 (0x00007f49ebb8a000)
Daniel P. Berrange fc57f4
	libpcre.so.1 => /usr/lib64/libpcre.so.1 (0x00007f49eb91d000)
Daniel P. Berrange fc57f4
	libgssapi_krb5.so.2 => /usr/lib64/libgssapi_krb5.so.2 (0x00007f49eb6cf000)
Daniel P. Berrange fc57f4
	libkrb5.so.3 => /usr/lib64/libkrb5.so.3 (0x00007f49eb3ec000)
Daniel P. Berrange fc57f4
	libcom_err.so.2 => /usr/lib64/libcom_err.so.2 (0x00007f49eb1e8000)
Daniel P. Berrange fc57f4
	libk5crypto.so.3 => /usr/lib64/libk5crypto.so.3 (0x00007f49eafb4000)
Daniel P. Berrange fc57f4
	libkrb5support.so.0 => /usr/lib64/libkrb5support.so.0 (0x00007f49eada5000)
Daniel P. Berrange fc57f4
	libkeyutils.so.1 => /usr/lib64/libkeyutils.so.1 (0x00007f49eaba0000)
Daniel P. Berrange fc57f4
Daniel P. Berrange fc57f4
All libcacard actually needs are the NSS libs. Linking against the entire
Daniel P. Berrange fc57f4
world is a regression caused by
Daniel P. Berrange fc57f4
Daniel P. Berrange fc57f4
  commit 9d171bd9375e4d08feff9adda15163e0811f5f42
Daniel P. Berrange fc57f4
  Author: Michael Tokarev <mjt@tls.msk.ru>
Daniel P. Berrange fc57f4
  Date:   Thu May 8 16:48:27 2014 +0400
Daniel P. Berrange fc57f4
Daniel P. Berrange fc57f4
    libcacard: remove libcacard-specific CFLAGS and LIBS from global vars
Daniel P. Berrange fc57f4
Daniel P. Berrange fc57f4
Which removed the setting of the LIBS variable in libcacard/Makefile.
Daniel P. Berrange fc57f4
Daniel P. Berrange fc57f4
Adding it back as an empty assignment brings the linked libs back to a more
Daniel P. Berrange fc57f4
reasonable set
Daniel P. Berrange fc57f4
Daniel P. Berrange fc57f4
	linux-vdso.so.1 =>  (0x00007fff575c1000)
Daniel P. Berrange fc57f4
	libssl3.so => /usr/lib64/libssl3.so (0x00007f7f753b1000)
Daniel P. Berrange fc57f4
	libsmime3.so => /usr/lib64/libsmime3.so (0x00007f7f75189000)
Daniel P. Berrange fc57f4
	libnss3.so => /usr/lib64/libnss3.so (0x00007f7f74e62000)
Daniel P. Berrange fc57f4
	libnssutil3.so => /usr/lib64/libnssutil3.so (0x00007f7f74c36000)
Daniel P. Berrange fc57f4
	libplds4.so => /usr/lib64/libplds4.so (0x00007f7f74a31000)
Daniel P. Berrange fc57f4
	libplc4.so => /usr/lib64/libplc4.so (0x00007f7f7482c000)
Daniel P. Berrange fc57f4
	libnspr4.so => /usr/lib64/libnspr4.so (0x00007f7f745ed000)
Daniel P. Berrange fc57f4
	libpthread.so.0 => /usr/lib64/libpthread.so.0 (0x00007f7f743d0000)
Daniel P. Berrange fc57f4
	libdl.so.2 => /usr/lib64/libdl.so.2 (0x00007f7f741cc000)
Daniel P. Berrange fc57f4
	libgthread-2.0.so.0 => /usr/lib64/libgthread-2.0.so.0 (0x00007f7f73fca000)
Daniel P. Berrange fc57f4
	libglib-2.0.so.0 => /usr/lib64/libglib-2.0.so.0 (0x00007f7f73c90000)
Daniel P. Berrange fc57f4
	libc.so.6 => /usr/lib64/libc.so.6 (0x00007f7f738d3000)
Daniel P. Berrange fc57f4
	libz.so.1 => /usr/lib64/libz.so.1 (0x00007f7f736bd000)
Daniel P. Berrange fc57f4
	librt.so.1 => /usr/lib64/librt.so.1 (0x00007f7f734b4000)
Daniel P. Berrange fc57f4
	/lib64/ld-linux-x86-64.so.2 (0x00007f7f757fd000)
Daniel P. Berrange fc57f4
Daniel P. Berrange fc57f4
Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Daniel P. Berrange fc57f4
---
Daniel P. Berrange fc57f4
 libcacard/Makefile | 2 ++
Daniel P. Berrange fc57f4
 1 file changed, 2 insertions(+)
Daniel P. Berrange fc57f4
Daniel P. Berrange fc57f4
diff --git a/libcacard/Makefile b/libcacard/Makefile
Daniel P. Berrange fc57f4
index 0e7903f..b5eddff 100644
Daniel P. Berrange fc57f4
--- a/libcacard/Makefile
Daniel P. Berrange fc57f4
+++ b/libcacard/Makefile
Daniel P. Berrange fc57f4
@@ -19,6 +19,8 @@ vscclient$(EXESUF): libcacard/vscclient.o libcacard.la
Daniel P. Berrange fc57f4
 
Daniel P. Berrange fc57f4
 libcacard.la: LDFLAGS += -rpath $(libdir) -no-undefined \
Daniel P. Berrange fc57f4
 	-export-symbols $(SRC_PATH)/libcacard/libcacard.syms
Daniel P. Berrange fc57f4
+# Prevent libcacard.so linking against the entire world of 3rd party libs
Daniel P. Berrange fc57f4
+libcacard.la: LIBS =
Daniel P. Berrange fc57f4
 libcacard.la: $(libcacard-lobj-y)
Daniel P. Berrange fc57f4
 	$(call LINK,$^)
Daniel P. Berrange fc57f4
 
Daniel P. Berrange fc57f4
-- 
Daniel P. Berrange fc57f4
2.1.0
Daniel P. Berrange fc57f4