]>
Commit | Line | Data |
---|---|---|
bd7854cb | 1 | #!/bin/sh |
2 | # | |
3 | # Check for global symbols that don't need to be made global... | |
4 | # | |
5 | ||
6 | for file in *.o; do | |
7 | echo -n "$file: " | |
8 | ||
9 | functions="" | |
10 | ||
11 | for function in `nm -g $file | grep "T " | awk '{print $3}'`; do | |
12 | found="" | |
13 | for file2 in *.o; do | |
14 | if test "$file" = "$file2"; then | |
15 | continue; | |
16 | fi | |
17 | ||
18 | found=`nm -g $file2 | grep $function` | |
19 | if test "$found" != ""; then | |
20 | break; | |
21 | fi | |
22 | done | |
23 | ||
24 | if test -z "$found"; then | |
25 | functions="$functions $function" | |
26 | fi | |
27 | done | |
28 | ||
29 | if test -z "$functions"; then | |
30 | echo "OK" | |
31 | else | |
32 | echo $functions | |
33 | fi | |
34 | done |