AIX have a diffrent nm, use -B to get bsd like output
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15332 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -8,6 +8,12 @@ export LANG
|
||||
esym=
|
||||
symbols=
|
||||
|
||||
# AIX has different default output format
|
||||
nmargs=""
|
||||
if [ "`uname`" = AIX ]; then
|
||||
nmargs="-B"
|
||||
fi
|
||||
|
||||
while test $# != 0 ;do
|
||||
case "$1" in
|
||||
-lib) lib="$2" ; shift;;
|
||||
@@ -33,9 +39,9 @@ for a in "$@" $esym; do
|
||||
symbols="\$3 !~ /^_?${a}/ ${symbols:+&&} ${symbols}"
|
||||
done
|
||||
|
||||
# F is filename, N for debugsymbols, W weak symbols
|
||||
# F filename, N debugsymbols, W weak symbols, U undefined
|
||||
|
||||
(nm .libs/lib${lib}.a || nm .libs/lib${lib}.so*) |
|
||||
(nm $nmargs .libs/lib${lib}.a || nm $nmargs .libs/lib${lib}.so*) |
|
||||
awk "BEGIN { stat = 0 }
|
||||
NF == 3 && \$2 ~ /[A-EG-MO-VX-Z]/ && $symbols { printf \"%s should not be exported (type %s)\\n\", \$3, \$2; ++stat } END { exit stat }"
|
||||
NF == 3 && \$2 ~ /[A-EG-MO-TVX-Z]/ && $symbols { printf \"%s should not be exported (type %s)\\n\", \$3, \$2; ++stat } END { exit stat }"
|
||||
|
||||
|
Reference in New Issue
Block a user