fix test runner exit code
link against libm on linux