Skip to contentSkip to conversation

package/binutils: add optional support for zlib

PATCH New Bernd Kuhls 2 participants 2 messages Feb 21, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/binutils: add optional support for zlib

When zlib was compiled before, binutils will use it as optional dependency:

$ output/host/usr/bin/x86_64-linux-readelf -a output/target/usr/lib/libbfd-2.24.so | grep NEEDED
 0x0000000000000001 (NEEDED)             Shared library: [libz.so.1]
 0x0000000000000001 (NEEDED)             Shared library: [libc.so.1]

Apparantly the build system offers no support to control the dependency, --without-system-zlib with zlib installed still provides libbfd-2.24.so linked to libz.so.1.

---
 package/binutils/binutils.mk | 4 ++++
 1 file changed, 4 insertions(+)
package/binutils/binutils.mk +4 -0
index a96a9a8..0f75c1d 100644
@@ -61,6 +61,10 @@ ifeq ($(BR2_PACKAGE_BUSYBOX),y)
 BINUTILS_DEPENDENCIES += busybox
 endif
 
+ifeq ($(BR2_PACKAGE_ZLIB),y)
+BINUTILS_DEPENDENCIES += zlib
+endif
+
 # "host" binutils should actually be "cross"
 # We just keep the convention of "host utility" for now
 HOST_BINUTILS_CONF_OPTS = \
Signature · 1 line
2.7.0
#1 lore raw

PATCH 1/1 package/binutils: add optional support for zlib

Dear Bernd Kuhls,

Quoted 7 lines · Bernd Kuhls

When zlib was compiled before, binutils will use it as optional dependency:

$ output/host/usr/bin/x86_64-linux-readelf -a output/target/usr/lib/libbfd-2.24.so | grep NEEDED
 0x0000000000000001 (NEEDED)             Shared library: [libz.so.1]
 0x0000000000000001 (NEEDED)             Shared library: [libc.so.1]
Quoted 8 lines

Apparantly the build system offers no support to control the dependency, --without-system-zlib with zlib installed still provides libbfd-2.24.so linked to libz.so.1.

---
 package/binutils/binutils.mk | 4 ++++
 1 file changed, 4 insertions(+)

Applied to master, thanks.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com