Contains strip binary (from GNU Binutils), shell script for strip binary and right-click context menu.
pstrip-2.21-w-20110126.pet 359KB software package
cd /dir/to/be/stripped pstrip
When an executable is produced from source code, there are two stages - compilation and linking. Compiling takes a source file and produces an object file. Linking concatenates these object files into a single executable. The concatenation occurs by section. For example, the ".comment" section for the final executable will contain the contents of the ".comment" section of each object file that was linked into the executable. Note that the contents of the ".comment" section are not standardized, and hence the compiler can fill it with anything it likes.
GNU strip can discard all symbols from object files, but Pstrip only removes that which is superfluous by using strip with specific arguments. The list of object files may include archives. At least one object file must be given. GNU strip modifies the files named in its argument, rather than writing modified copies under different names.
There are 3 sections that are of special interest: the ".comment", ".note", and ".note.ABI-tag" sections. Pstrip will discard all symbols from these 3 sections of each chosen object file, plus all debugging symbols, plus all symbols that are not needed for relocation processing.
This is the script within Pstrip:
strip -p -d --strip-unneeded -R .comment -R .note -R .note.ABI-tag [file...]