SHSTAT is like the stat command except that it is designed for use in shell scripts. An example:
eval `shstat -env -ctime -atime mbox`
if [ $ST_ATIME -lt $ST_MTIME ] then ...
which tests if the file "mbox" has been modified more
recently than it has been accessed (read).
The C source and manual page can be found here in tar.gzip format.