Dmitry V. Levin
a30d02e902
* tests/strace-V.test: Move config.h parser to a function. Rename $OUT to $EXP, swap arguments passed to match_diff.
18 lines
295 B
Bash
Executable File
18 lines
295 B
Bash
Executable File
#!/bin/sh
|
|
|
|
# Check -V option.
|
|
|
|
. "${srcdir=.}/init.sh"
|
|
|
|
run_strace -V > "$LOG"
|
|
|
|
getval()
|
|
{
|
|
sed -n 's/#define[[:space:]]*'"$1"'[[:space:]]*"\([^"]*\)".*/\1/p' ../config.h
|
|
}
|
|
|
|
printf "%s -- version %s\n" "$(getval PACKAGE_NAME)" "$(getval VERSION)" > "$EXP"
|
|
|
|
match_diff "$EXP" "$LOG"
|
|
rm -f "$EXP"
|