diff options
author | Roland McGrath <roland@redhat.com> | 2009-01-04 03:26:58 -0800 |
---|---|---|
committer | Roland McGrath <roland@redhat.com> | 2009-01-04 03:26:58 -0800 |
commit | e5528628bd8a01aa42916314173f65330487fa85 (patch) | |
tree | 876989a14b7f9a164d751d74d312b59bc82402f7 /find-files.sh | |
download | debuginfo-test-scripts-e5528628bd8a01aa42916314173f65330487fa85.tar.gz debuginfo-test-scripts-e5528628bd8a01aa42916314173f65330487fa85.tar.xz debuginfo-test-scripts-e5528628bd8a01aa42916314173f65330487fa85.zip |
initial commit of testing scripts
Diffstat (limited to 'find-files.sh')
-rwxr-xr-x | find-files.sh | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/find-files.sh b/find-files.sh new file mode 100755 index 0000000..2094291 --- /dev/null +++ b/find-files.sh @@ -0,0 +1,13 @@ +#!/bin/sh + +while read dir; do + find "$dir" -name '*.debug' -type f -print0 | + xargs -0 file -N -F ' ' -i | + awk ' +NF == 2 && $2 == "application/x-executable" { print $1 >> "exec" ; next } +NF == 2 && $2 == "application/x-sharedlib" { print $1 >> "dyn" ; next } +NF == 2 && $2 == "application/x-object" { print $1 >> "rel" ; next } +NF == 2 && $2 == "application/x-archive" { print $1 >> "archive" ; next } +{ print "unexpected line:", $0; next } +' +done |