Did you know LQ has a Linux Hardware Compatibility List?
Go Back > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Slackware This Forum is for the discussion of Slackware Linux.


  Search this Thread
Old 06-26-2004, 10:29 PM   #1
Registered: Dec 2003
Location: Mysore
Distribution: Mandrake, Libranet, Slackware
Posts: 101

Rep: Reputation: 15
Why strip binaries?


Please pardon me for my ignorance. What is the meaing of stripping of ELF binaries. While creating a Slackware package, why should this be done? Can any body direct me to the correct information?

Thanks for your help.

Old 06-27-2004, 12:18 AM   #2
Senior Member
Registered: Feb 2003
Distribution: Slackware
Posts: 4,113

Rep: Reputation: Disabled
Stripping removes debugging symbols and such junk. It makes them smaller, faster, and require less memory. However, if they crash, you can't really figure out why. If you're a developer and need to debug your stuff, you wouldn't want to strip. If you're just a user who wouldn't debug something or even know how, might as well strip.

You can strip libs, too, but this sometimes has more negative effects. Not sure of the details there. A guru can maybe clarify or correct me if I'm altogether mistaken but this is my understanding.
Old 06-27-2004, 07:28 AM   #3
Registered: Dec 2003
Location: Mysore
Distribution: Mandrake, Libranet, Slackware
Posts: 101

Original Poster
Rep: Reputation: 15
How to strip binaries?

Thanks for the reply. But how to strip binaries?

Old 06-27-2004, 07:51 AM   #4
Registered: Apr 2003
Location: uk
Distribution: slackware current
Posts: 746

Rep: Reputation: 52
Are you using checkinstall? This will strip the binary files for you
the option is in

else read 'man strip'

Old 06-27-2004, 04:17 PM   #5
Registered: Dec 2003
Location: USA (Pacific coast)
Distribution: Vector 5.8-SOHO, FreeBSD 6.2
Posts: 513

Rep: Reputation: 34
Here's the Slack way of stripping binaries, both executables and libs ("shared object")......................
  find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
  find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
NOTE: First 'cd' to the top=level directory where you want to strip the files............These are the commands used in Patrick's SlackBuild scripts found in the source trees of the Slack mirrors.................


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
sendmail - strip attachments - is this possible irubin Linux - Software 1 09-22-2004 08:23 AM
strip -s blackzone Linux - Newbie 1 09-01-2004 12:08 AM
strip command? blackzone Linux - General 2 07-09-2004 03:20 AM
strip poker JROCK1980 Linux - Games 7 04-10-2004 12:40 AM
A quick question about strip.. sandy Linux - Newbie 1 10-09-2003 07:32 AM

All times are GMT -5. The time now is 10:58 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration