|
- #! /bin/sh
- #
- # Script that test whether or not a given file has been built for
- # debug (-g option specified in the compilation)
- if [ $# -le 0 ]
- then
- echo "Usage: $1 filename"
- exit 1
- fi
- if [ ! -f $1 ]
- then
- echo "File $1 does not exist"
- exit 1
- fi
- /usr/ccs/bin/dump -hv $1 | /bin/egrep -s '.stab$'
- if [ $? -eq 0 ]
- then
- echo "File '$1' has been built for debug"
- exit 0
- else
- echo "File '$1' has not been built for debug"
- exit 1
- fi
复制代码 |
|