source: freewrt/scripts/rstrip.sh@ fdd4f59

freewrt_1_0 freewrt_2_0
Last change on this file since fdd4f59 was 475ad56, checked in by Waldemar Brodkorb <wbx@…>, 20 years ago

add OpenWrt trunk revision 3830.

git-svn-id: svn://www.freewrt.org/trunk/freewrt@1 afb5a338-a214-0410-bd46-81f09a774fd1

  • Property mode set to 100755
File size: 489 bytes
Line 
1#!/bin/sh
2
3SELF=${0##*/}
4
5[ -z "$STRIP" ] && {
6 echo "$SELF: strip command not defined (STRIP variable not set)"
7 exit 1
8}
9
10TARGETS=$*
11
12[ -z "$TARGETS" ] && {
13 echo "$SELF: no directories / files specified"
14 echo "usage: $SELF [PATH...]"
15 exit 1
16}
17
18find $TARGETS -type f -a -exec file {} \; | \
19 sed -n -e 's/^\(.*\):.*ELF.*\(executable\|relocatable\|shared object\).*, not stripped/\1:\2/p' | \
20(
21 IFS=":"
22 while read F S; do
23 echo "$SELF: $F:$S"
24 eval "$STRIP $F"
25 done
26)
Note: See TracBrowser for help on using the repository browser.