From e3b87cac4f6e163566c746849d4b798726f62c11 Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Thu, 19 Jan 2012 23:19:55 -0500 Subject: Add comments to oh-strip. --- (limited to 'src') diff --git a/src/oh-strip b/src/oh-strip index e3ae500..9e11f75 100644 --- a/src/oh-strip +++ b/src/oh-strip @@ -63,10 +63,15 @@ if [ ${#} -eq 0 ]; then exit 1 fi +# Iterate over object files. while [ ${#} -gt 0 ]; do if ${make_dbg_pkg}; then + # Copy debugging symbols into a debugging object file and add a GDB link + # from the original object file to the debugging object file. objcopy --only-keep-debug "dest/${1}" "dest/usr/lib/debug/${1}" objcopy --add-gnu-debuglink="/usr/lib/debug/${1}" "dest/${1}" fi + # Strip the object file of symbols. + # TODO: If the file is not a library, strip it of all symbols. strip -g "dest/${1}" done -- cgit v0.9.1