My command fails with what I think is a thread dump or something. Since I want to inspect, I would like to redirect the output to a file or less. However the output doesn't seem to be on stderr or stdout?! How can I capture this output?
7f47efcda000-7f47efcdb000 r--p 00000000 fc:00 174138 /usr/lib/libgtest_main.so.0.0.0
7f47efcdb000-7f47efcdc000 rw-p 00001000 fc:00 174138 /usr/lib/libgtest_main.so.0.0.0
7f47efcdc000-7f47efd25000 r-xp 00000000 fc:00 174141 /usr/lib/libgtest.so.0.0.0
7f47efd25000-7f47eff25000 ---p 00049000 fc:00 174141 /usr/lib/libgtest.so.0.0.0
7f47eff25000-7f47eff26000 r--p 00049000 fc:00 174141 /usr/lib/libgtest.so.0.0.0
7f47eff26000-7f47eff27000 rw-p 0004a000 fc:00 174141 /usr/lib/libgtest.so.0.0.0
7f47eff27000-7f47eff28000 rw-p 00000000 00:00 0
7f47eff28000-7f47eff4e000 r-xp 00000000 fc:00 899 /lib/x86_64-linux-gnu/ld-2.23.so
7f47f00c6000-7f47f00e2000 rw-p 00000000 00:00 0
7f47f00e2000-7f47f0100000 r-xp 00000000 fc:00 422 /lib/x86_64-linux-gnu/libudev.so.1.6.4
7f47f0100000-7f47f0101000 r--p 0001d000 fc:00 422 /lib/x86_64-linux-gnu/libudev.so.1.6.4
7f47f0101000-7f47f0102000 rw-p 0001e000 fc:00 422 /lib/x86_64-linux-gnu/libudev.so.1.6.4
7f47f0102000-7f47f0132000 rw-p 00000000 00:00 0
7f47f014c000-7f47f014d000 rw-p 00000000 00:00 0
7f47f014d000-7f47f014e000 r--p 00025000 fc:00 899 /lib/x86_64-linux-gnu/ld-2.23.so
7f47f014e000-7f47f014f000 rw-p 00026000 fc:00 899 /lib/x86_64-linux-gnu/ld-2.23.so
7f47f014f000-7f47f0150000 rw-p 00000000 00:00 0
7ffca7f25000-7ffca7f46000 rw-p 00000000 00:00 0 [stack]
7ffca7f84000-7ffca7f86000 r--p 00000000 00:00 0 [vvar]
7ffca7f86000-7ffca7f88000 r-xp 00000000 00:00 0 [vdso]
ffffffffff600000-ffffffffff601000 r-xp 00000000 00:00 0 [vsyscall]
2/2 Test #2: subscriberSkeleton_gtest .........***Exception: Other 0.03 sec
0% tests passed, 2 tests failed out of 2
Total Test time (real) = 0.07 sec
I tried variations of make test 2> file
, make test 2>&1 | less
, these only output the last lines, not the dump.
The code in question is just this:
#include <gtest/gtest.h>
int main(int argc, char **argv) {
::testing::InitGoogleTest(&argc, argv);
return RUN_ALL_TESTS();
}
The issue that makes this program fail is that it is linked together with OpenCV, which contains a testing component opencv_ts that conflicts with GTest. Blog post of someone with the same problem. I know how to solve this, but am stumped as to why I can't capture the output that is produced by the error.