From 9c636934a0cbe7c5b1644ed3688a2a2cb3518d3f Mon Sep 17 00:00:00 2001 From: Eric Andersen Date: Thu, 13 Mar 2003 20:30:07 +0000 Subject: [PATCH] Do not blindly strip all symbols from from all libs. libpthread needs its symbols for pthread debugging to work. Let it be a local decision. --- make/bzip2.mk | 1 + make/cramfsroot.mk | 2 +- make/ext2root.mk | 2 +- make/jffs2root.mk | 2 +- make/jpeg.mk | 1 + make/ncurses.mk | 3 ++- make/openssl.mk | 2 ++ make/uclibc_toolchain.mk | 4 +--- make/uclibc_toolchain_2_95.mk | 4 +--- 9 files changed, 11 insertions(+), 10 deletions(-) diff --git a/make/bzip2.mk b/make/bzip2.mk index 7387ad2c87..187795f9de 100644 --- a/make/bzip2.mk +++ b/make/bzip2.mk @@ -68,6 +68,7 @@ $(TARGET_DIR)/usr/lib/libbz2.a: $(STAGING_DIR)/lib/libbz2.a (cd $(TARGET_DIR)/usr/lib; \ ln -fs /usr/lib/libbz2.so.1.0 libbz2.so; \ ) + -$(STRIP) --strip-unneeded $(TARGET_DIR)/usr/lib/libbz2.so.1.0 touch -c $(TARGET_DIR)/usr/lib/libbz2.a bzip2-headers: $(TARGET_DIR)/usr/lib/libbz2.a diff --git a/make/cramfsroot.mk b/make/cramfsroot.mk index 2de865a93d..29ac4787d2 100644 --- a/make/cramfsroot.mk +++ b/make/cramfsroot.mk @@ -36,7 +36,7 @@ cramfs-dirclean: ############################################################# cramfsroot: cramfs - -@find $(TARGET_DIR)/lib -type f -name \*.so\* | xargs $(STRIP) --strip-unneeded 2>/dev/null || true; + #-@find $(TARGET_DIR)/lib -type f -name \*.so\* | xargs $(STRIP) --strip-unneeded 2>/dev/null || true; -@find $(TARGET_DIR) -type f -perm +111 | xargs $(STRIP) 2>/dev/null || true; @rm -rf $(TARGET_DIR)/usr/man @rm -rf $(TARGET_DIR)/usr/info diff --git a/make/ext2root.mk b/make/ext2root.mk index f9c79b0001..889cb05a94 100644 --- a/make/ext2root.mk +++ b/make/ext2root.mk @@ -40,7 +40,7 @@ GENEXT2_INODES=$(shell expr $(shell find $(TARGET_DIR) | wc -l) + 400) #GENEXT2_SIZE=100000 ext2root: genext2fs - -@find $(TARGET_DIR)/lib -type f -name \*.so\* | xargs $(STRIP) --strip-unneeded 2>/dev/null || true; + #-@find $(TARGET_DIR)/lib -type f -name \*.so\* | xargs $(STRIP) --strip-unneeded 2>/dev/null || true; -@find $(TARGET_DIR) -type f -perm +111 | xargs $(STRIP) 2>/dev/null || true; $(GENEXT2_DIR)/genext2fs -i $(GENEXT2_INODES) -b $(GENEXT2_SIZE) \ -d $(TARGET_DIR) -q -D $(SOURCE_DIR)/device_table.txt $(IMAGE) diff --git a/make/jffs2root.mk b/make/jffs2root.mk index b0f8ce7b6a..569ae7e39a 100644 --- a/make/jffs2root.mk +++ b/make/jffs2root.mk @@ -29,7 +29,7 @@ mtd: $(MKFS_JFFS2) ############################################################# jffs2root: mtd - -@find $(TARGET_DIR)/lib -type f -name \*.so\* | xargs $(STRIP) --strip-unneeded 2>/dev/null || true; + #-@find $(TARGET_DIR)/lib -type f -name \*.so\* | xargs $(STRIP) --strip-unneeded 2>/dev/null || true; -@find $(TARGET_DIR) -type f -perm +111 | xargs $(STRIP) 2>/dev/null || true; @rm -rf $(TARGET_DIR)/usr/man @rm -rf $(TARGET_DIR)/usr/info diff --git a/make/jpeg.mk b/make/jpeg.mk index fa15569e67..e3489b28af 100644 --- a/make/jpeg.mk +++ b/make/jpeg.mk @@ -63,6 +63,7 @@ $(STAGING_DIR)/lib/libjpeg.so.62.0.0: $(JPEG_DIR)/.configured $(TARGET_DIR)/lib/libjpeg.so.62.0.0: $(STAGING_DIR)/lib/libjpeg.so.62.0.0 cp -dpf $(STAGING_DIR)/lib/libjpeg.so* $(TARGET_DIR)/lib/ + -$(STRIP) --strip-unneeded $(TARGET_DIR)/lib/libjpeg.so.62.0.0 jpeg: uclibc $(TARGET_DIR)/lib/libjpeg.so.62.0.0 diff --git a/make/ncurses.mk b/make/ncurses.mk index 7cc7947387..e499de4a82 100644 --- a/make/ncurses.mk +++ b/make/ncurses.mk @@ -5,7 +5,7 @@ # ############################################################# # Copyright (C) 2002 by Ken Restivo -# $Id: ncurses.mk,v 1.23 2003/03/04 19:16:18 andersen Exp $ +# $Id: ncurses.mk,v 1.24 2003/03/13 20:30:07 andersen Exp $ # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU Library General Public License as @@ -109,6 +109,7 @@ $(TARGET_DIR)/usr/lib/libncurses.a: $(STAGING_DIR)/lib/libncurses.a (cd $(TARGET_DIR)/usr/include; ln -fs ncurses.h curses.h) rm -f $(TARGET_DIR)/lib/libncurses.so (cd $(TARGET_DIR)/usr/lib; ln -fs /lib/libncurses.so.5.2 libncurses.so) + -$(STRIP) --strip-unneeded $(TARGET_DIR)/lib/libncurses.so.5.2 touch -c $(TARGET_DIR)/usr/lib/libncurses.a ncurses-headers: $(TARGET_DIR)/usr/lib/libncurses.a diff --git a/make/openssl.mk b/make/openssl.mk index 095aa07370..3434278199 100644 --- a/make/openssl.mk +++ b/make/openssl.mk @@ -56,6 +56,8 @@ $(TARGET_DIR)/usr/lib/libssl.a: $(STAGING_DIR)/lib/libcrypto.so.0.9.7 ln -fs /lib/libssl.so.0.9.7 libssl.so; \ ln -fs /lib/libcrypto.so.0.9.7 libcrypto.so; \ ) + -$(STRIP) --strip-unneeded $(TARGET_DIR)/lib/libssl.so.0.9.7 + -$(STRIP) --strip-unneeded $(TARGET_DIR)/lib/libcrypto.so.0.9.7 touch -c $(TARGET_DIR)/usr/lib/libssl.a openssl-headers: $(TARGET_DIR)/usr/lib/libssl.a diff --git a/make/uclibc_toolchain.mk b/make/uclibc_toolchain.mk index 2027d7dd3f..6e3e33e2f5 100644 --- a/make/uclibc_toolchain.mk +++ b/make/uclibc_toolchain.mk @@ -455,9 +455,7 @@ $(STAGING_DIR)/bin/$(ARCH)-uclibc-g++: $(GCC_BUILD_DIR2)/.compiled $(STAGING_DIR)/share/locale # Strip the host binaries -strip --strip-all -R .note -R .comment $(STAGING_DIR)/bin/* - # Strip the target shared libs - -$(STRIP) --strip-unneeded -R .note -R .comment $(STAGING_DIR)/lib/*.so*; - set -e; + set -e; \ for app in cc gcc c89 cpp c++ g++ ; do \ if [ -x $(STAGING_DIR)/bin/$(ARCH)-uclibc-$${app} ] ; then \ (cd $(STAGING_DIR)/usr/bin; \ diff --git a/make/uclibc_toolchain_2_95.mk b/make/uclibc_toolchain_2_95.mk index 3335d0483d..9a040ddf32 100644 --- a/make/uclibc_toolchain_2_95.mk +++ b/make/uclibc_toolchain_2_95.mk @@ -510,9 +510,7 @@ $(STAGING_DIR)/bin/$(ARCH)-uclibc-g++: $(GCC_BUILD_DIR2)/.compiled $(STAGING_DIR)/share/locale # Strip the host binaries -strip --strip-all -R .note -R .comment $(STAGING_DIR)/bin/* - # Strip the target shared libs - -$(STRIP) --strip-unneeded -R .note -R .comment $(STAGING_DIR)/lib/*.so*; - set -e; + set -e; \ for app in cc gcc c89 cpp c++ g++ ; do \ if [ -x $(STAGING_DIR)/bin/$(ARCH)-uclibc-$${app} ] ; then \ (cd $(STAGING_DIR)/usr/bin; \ -- 2.30.2