Date:2014-01-05 17:49:06 (10 months 22 days ago)
Author:Werner Almesberger
Commit:d00f04ffa36d116787cdf8ca774dfd64d5281a66
Message:scripts/missing-in-tree: new option "-x lib" to exclude libraries

Files: scripts/missing-in-tree (4 diffs)

Change Details

scripts/missing-in-tree
1313
1414usage()
1515{
16    echo "usage: $0 [-F] [-L libdir ...] [-l lib ...] hierarchy" 1>&2
17    echo " $0 -Q [-L libdir ...] [-l lib ...] project.pro" 1>&2
16    echo "usage: $0 [-F] [-x lib ...] [-L libdir ...] [-l lib ...] hierarchy" 1>&2
17    echo " $0 -Q [-x lib ...] [-L libdir ...] [-l lib ...] project.pro" 1>&2
1818    exit 1
1919}
2020
2121
22excluded()
23{
24    [ "`eval echo \\\$exclude_\`sanitize \"$1\"\``" ]
25}
26
27
2228scan_comp()
2329{
2430    for n in "$@"; do
31        excluded "$n" && continue
2532        sed '/^DEF ~\?/{s///;s/ .*//;p;};d' <$n >>_tmp2
2633    done
2734}
...... 
3037scan_fped()
3138{
3239    for n in "$@"; do
40        excluded "$n" && continue
3341        fped -k $n - | sed '/^\$MODULE /s///p;d' >>_tmp2
3442    done
3543}
...... 
4250    done
4351}
4452
53
54sanitize()
55{
56    basename "$1" .$ext | tr -d '\n' | tr -c 'A-Za-z0-9_[-]' _
57}
58
59
4560trap "rm -f _tmp1 _tmp2" 0
4661
4762if [ "$1" = -Q ]; then
...... 
7287        else
7388            scan_fped "$1"
7489        fi;;
90    -x) shift
91        eval exclude_`sanitize "$1"`=y;;
7592    -*) usage;;
7693    *) break;;
7794    esac

Archive Download the corresponding diff file

Branches:
master



interactive