kasp test broken on freebsd
The test for #3302 (closed) introuduced in commit 7249bad7 isn't working on freebsd:
I:kasp:check number of keys for zone step5.csk-algorithm-roll.kasp in dir ns6 (1118)
I:kasp:check key id 64886
stat: illegal option -- c
usage: stat [-FLnq] [-f format | -l | -r | -s | -x] [-t timefmt] [file|handle ...]
stat: illegal option -- c
usage: stat [-FLnq] [-f format | -l | -r | -s | -x] [-t timefmt] [file|handle ...]
stat: illegal option -- c
usage: stat [-FLnq] [-f format | -l | -r | -s | -x] [-t timefmt] [file|handle ...]
I:kasp:check key id 47202
stat: illegal option -- c
usage: stat [-FLnq] [-f format | -l | -r | -s | -x] [-t timefmt] [file|handle ...]
stat: illegal option -- c
usage: stat [-FLnq] [-f format | -l | -r | -s | -x] [-t timefmt] [file|handle ...]
stat: illegal option -- c
usage: stat [-FLnq] [-f format | -l | -r | -s | -x] [-t timefmt] [file|handle ...]
stat
isn't a posix standard. The equivalent of stat -c '%Z'
on freebsd is stat -a '%m'
.
I don't actually know of a posix-standard way to do this. date -r <filename> +%s
does work on both linux and freebsd, but possibly not solaris. Or we could use $PERL -e 'print((stat @ARGV[0])[9] . "\n");' <filename>
, or add a perl script to the test directory.