[buildroot] $(STRIP) --strip-unneeded on a SHARED library...WHY?
John Z. Bohach
jzb at aexorsyst.com
Tue Dec 6 15:51:46 UTC 2005
On Tuesday 06 December 2005 01:25, Peter S. Mazinger wrote:
> are you sure you used the correct strip (it is that you render your libs
> useless, if you use the host strip against the cross-compiled libs)
Sorry, I thought this would be more obvious. I don't want to start a big long
thread, so specifically, in buildroot/packages/Makefile.in, we have:
STRIP=$(TARGET_CROSS)strip --remove-section=.comment --remove-section=.note
which is fine. But then later, specific package makefiles do this:
-$(STRIP) --strip-unneeded $(TARGET_DIR)/lib/libncurses.so.$(NCURSES_VER)
-$(STRIP) --strip-unneeded $(TARGET_DIR)/lib/libdb*so*
which is not fine, because all symbol information from the libraries is now
removed, and whenever a linker tries linking against thusly stripped
libraries, you get "undefined symbol..." errors.
Just an FYI, and a learning point.
P.S.: freetype, directfb, libpng, libsys, and more all suffer from this, so
whatever the thinking was, it was contagious...
### Any similarity between my views and the truth is completely ###
### coincidental, except that they are endorsed by NO ONE ###
More information about the busybox