unit test failures (llvm/clang/scan-build/clang/clang++)

Maarten Hoes hoes.maarten at gmail.com
Mon Nov 23 00:28:09 PST 2015


Hi,



Im trying to run the llvm/clang static source code analyzer on libreoffice
~master, but ran into some unit test failures. I told 'scan-build' to use
the clang/clang++ compilers instead of gcc. I ran the suggested 'make
testname DEBUGCPPUNIT=TRUE' commands in order to get the backtraces of
'CppunitTest_sc_rangelst_test' [1], 'CppunitTest_sc_filters_test'[2], and
'CppunitTest_sc_ucalc'[3]. Im running Fedora 23.


Any and all suggestions about what's going on and/or how to go about
troubleshooting things are more than welcome.


- Maarten



[1]
scan-build: Using '/usr/local/bin/clang-3.8' for static analysis
make -j 8 -rs -f /home/maarten/src/libreoffice/core/Makefile.gbuild
CppunitTest_sc_rangelst_test
[build CUT] sc_rangelst_test
Catchpoint 1 (throw)
Catchpoint 2 (catch)
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
[New Thread 0x2aaaac6a7700 (LWP 21313)]
warning: the debug information found in
"/usr/lib/debug//lib64/libpcre.so.1.2.5.debug" does not match
"/lib64/libpcre.so.1" (CRC mismatch).

warning: the debug information found in
"/usr/lib/debug//usr/lib64/libpcre.so.1.2.5.debug" does not match
"/lib64/libpcre.so.1" (CRC mismatch).

Catchpoint 1 (exception thrown), __cxxabiv1::__cxa_throw (obj=0xf3a9f0,
tinfo=0x2aaaaaf6b7a0 <typeinfo for
CppUnit::DynamicLibraryManagerException>, dest=0x2aaaaad1f130
<CppUnit::DynamicLibraryManagerException::~DynamicLibraryManagerException()>)
at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:63
63        PROBE2 (throw, obj, tinfo);
#0  0x00002aaaab2afb2d in __cxxabiv1::__cxa_throw(void*, std::type_info*,
void (*)(void*)) (obj=0xf3a9f0, tinfo=0x2aaaaaf6b7a0 <typeinfo for
CppUnit::DynamicLibraryManagerException>, dest=0x2aaaaad1f130
<CppUnit::DynamicLibraryManagerException::~DynamicLibraryManagerException()>)
at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:63
#1  0x00002aaaaad1ef22 in
CppUnit::DynamicLibraryManager::loadLibrary(std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > const&) (this=0x6ff640,
libraryName="/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_rangelst_test.so")
at DynamicLibraryManager.cpp:57
#2  0x00002aaaaad1ee03 in
CppUnit::DynamicLibraryManager::DynamicLibraryManager(std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > const&) (this=0x6ff640,
libraryFileName="/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_rangelst_test.so")
at DynamicLibraryManager.cpp:13
#3  0x00002aaaaad25d87 in
CppUnit::PlugInManager::load(std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > const&,
CppUnit::PlugInParameters const&) (this=0x7fffffff3bb8,
libraryFileName="/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_rangelst_test.so",
parameters=...) at PlugInManager.cpp:32
#4  0x000000000040510d in (anonymous
namespace)::ProtectedFixtureFunctor::run() const (this=0x7fffffff3f00) at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:227
#5  0x0000000000404c09 in sal_main() () at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:431
#6  0x00000000004044e7 in main(int, char**) (argc=22, argv=0x7fffffff4308)
at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:338
Catchpoint 2 (exception caught), __cxxabiv1::__cxa_begin_catch
(exc_obj_in=0xf3a9d0) at ../../../../libstdc++-v3/libsupc++/eh_catch.cc:84
84        PROBE2 (catch, objectp, header->exceptionType);
#0  0x00002aaaab2ae981 in __cxxabiv1::__cxa_begin_catch(void*)
(exc_obj_in=0xf3a9d0) at ../../../../libstdc++-v3/libsupc++/eh_catch.cc:84
#1  0x000000000040516b in (anonymous
namespace)::ProtectedFixtureFunctor::run() const (this=0x7fffffff3f00) at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:228
#2  0x0000000000404c09 in sal_main() () at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:431
#3  0x00000000004044e7 in main(int, char**) (argc=22, argv=0x7fffffff4308)
at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:338
DynamicLibraryManagerException: "Failed to load dynamic library:
/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_rangelst_test.so
/home/maarten/src/libreoffice/core/instdir/program/liborcus-0.10.so.0:
undefined symbol: _ZNSt8ios_base7failureC2EPKcRKSt10error_code"
Path is
'/usr/lib64/ccache:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/home/maarten/.local/bin:/home/maarten/bin:/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.65-3.b17.fc23.x86_64/bin'
warn:legacy.osl:21309:1:unotools/source/config/configmgr.cxx:168:
OSL_ASSERT: items_.empty()
[Thread 0x2aaaac6a7700 (LWP 21313) exited]
[Inferior 1 (process 21309) exited with code 01]
/home/maarten/src/libreoffice/core/solenv/bin/gdbtrycatchtrace-stdout:13:
Error in sourced command file:
No stack.

Error: a unit test failed, please do one of:
make CppunitTest_sc_rangelst_test CPPUNITTRACE="gdb --args"
    # for interactive debugging on Linux
make CppunitTest_sc_rangelst_test VALGRIND=memcheck
    # for memory checking
make CppunitTest_sc_rangelst_test DEBUGCPPUNIT=TRUE
    # for exception catching

/home/maarten/src/libreoffice/core/solenv/gbuild/CppunitTest.mk:90: recipe
for target
'/home/maarten/src/libreoffice/core/workdir/CppunitTest/sc_rangelst_test.test'
failed
make[1]: ***
[/home/maarten/src/libreoffice/core/workdir/CppunitTest/sc_rangelst_test.test]
Error 1
Makefile:146: recipe for target 'CppunitTest_sc_rangelst_test' failed
make: *** [CppunitTest_sc_rangelst_test] Error 2
scan-build: Removing directory
'/home/maarten/tmp/wis/2015-11-23-091531-21253-1' because it contains no
reports.
scan-build: No bugs found.



[2]
scan-build: Using '/usr/local/bin/clang-3.8' for static analysis
make -j 8 -rs -f /home/maarten/src/libreoffice/core/Makefile.gbuild
CppunitTest_sc_filters_test
[build CUT] sc_filters_test
Catchpoint 1 (throw)
Catchpoint 2 (catch)
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
[New Thread 0x2aaaac6a7700 (LWP 21384)]
warning: the debug information found in
"/usr/lib/debug//lib64/libpcre.so.1.2.5.debug" does not match
"/lib64/libpcre.so.1" (CRC mismatch).

warning: the debug information found in
"/usr/lib/debug//usr/lib64/libpcre.so.1.2.5.debug" does not match
"/lib64/libpcre.so.1" (CRC mismatch).

Catchpoint 1 (exception thrown), __cxxabiv1::__cxa_throw (obj=0xf39d50,
tinfo=0x2aaaaaf6b7a0 <typeinfo for
CppUnit::DynamicLibraryManagerException>, dest=0x2aaaaad1f130
<CppUnit::DynamicLibraryManagerException::~DynamicLibraryManagerException()>)
at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:63
63        PROBE2 (throw, obj, tinfo);
#0  0x00002aaaab2afb2d in __cxxabiv1::__cxa_throw(void*, std::type_info*,
void (*)(void*)) (obj=0xf39d50, tinfo=0x2aaaaaf6b7a0 <typeinfo for
CppUnit::DynamicLibraryManagerException>, dest=0x2aaaaad1f130
<CppUnit::DynamicLibraryManagerException::~DynamicLibraryManagerException()>)
at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:63
#1  0x00002aaaaad1ef22 in
CppUnit::DynamicLibraryManager::loadLibrary(std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > const&) (this=0x700d30,
libraryName="/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_filters_test.so")
at DynamicLibraryManager.cpp:57
#2  0x00002aaaaad1ee03 in
CppUnit::DynamicLibraryManager::DynamicLibraryManager(std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > const&) (this=0x700d30,
libraryFileName="/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_filters_test.so")
at DynamicLibraryManager.cpp:13
#3  0x00002aaaaad25d87 in
CppUnit::PlugInManager::load(std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > const&,
CppUnit::PlugInParameters const&) (this=0x7fffffff3cc8,
libraryFileName="/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_filters_test.so",
parameters=...) at PlugInManager.cpp:32
#4  0x000000000040510d in (anonymous
namespace)::ProtectedFixtureFunctor::run() const (this=0x7fffffff4010) at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:227
#5  0x0000000000404c09 in sal_main() () at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:431
#6  0x00000000004044e7 in main(int, char**) (argc=22, argv=0x7fffffff4418)
at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:338
Catchpoint 2 (exception caught), __cxxabiv1::__cxa_begin_catch
(exc_obj_in=0xf39d30) at ../../../../libstdc++-v3/libsupc++/eh_catch.cc:84
84        PROBE2 (catch, objectp, header->exceptionType);
#0  0x00002aaaab2ae981 in __cxxabiv1::__cxa_begin_catch(void*)
(exc_obj_in=0xf39d30) at ../../../../libstdc++-v3/libsupc++/eh_catch.cc:84
#1  0x000000000040516b in (anonymous
namespace)::ProtectedFixtureFunctor::run() const (this=0x7fffffff4010) at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:228
#2  0x0000000000404c09 in sal_main() () at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:431
#3  0x00000000004044e7 in main(int, char**) (argc=22, argv=0x7fffffff4418)
at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:338
DynamicLibraryManagerException: "Failed to load dynamic library:
/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_filters_test.so
/home/maarten/src/libreoffice/core/instdir/program/liborcus-0.10.so.0:
undefined symbol: _ZNSt8ios_base7failureC2EPKcRKSt10error_code"
Path is
'/usr/lib64/ccache:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/home/maarten/.local/bin:/home/maarten/bin:/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.65-3.b17.fc23.x86_64/bin'
warn:legacy.osl:21380:1:unotools/source/config/configmgr.cxx:168:
OSL_ASSERT: items_.empty()
[Thread 0x2aaaac6a7700 (LWP 21384) exited]
[Inferior 1 (process 21380) exited with code 01]
/home/maarten/src/libreoffice/core/solenv/bin/gdbtrycatchtrace-stdout:13:
Error in sourced command file:
No stack.

Error: a unit test failed, please do one of:
make CppunitTest_sc_filters_test CPPUNITTRACE="gdb --args"
    # for interactive debugging on Linux
make CppunitTest_sc_filters_test VALGRIND=memcheck
    # for memory checking
make CppunitTest_sc_filters_test DEBUGCPPUNIT=TRUE
    # for exception catching

/home/maarten/src/libreoffice/core/solenv/gbuild/CppunitTest.mk:90: recipe
for target
'/home/maarten/src/libreoffice/core/workdir/CppunitTest/sc_filters_test.test'
failed
make[1]: ***
[/home/maarten/src/libreoffice/core/workdir/CppunitTest/sc_filters_test.test]
Error 1
Makefile:146: recipe for target 'CppunitTest_sc_filters_test' failed
make: *** [CppunitTest_sc_filters_test] Error 2
scan-build: Removing directory
'/home/maarten/tmp/wis/2015-11-23-091722-21324-1' because it contains no
reports.
scan-build: No bugs found.



[3]
scan-build: Using '/usr/local/bin/clang-3.8' for static analysis
make -j 8 -rs -f /home/maarten/src/libreoffice/core/Makefile.gbuild
CppunitTest_sc_ucalc
[build CUT] sc_ucalc
Catchpoint 1 (throw)
Catchpoint 2 (catch)
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
[New Thread 0x2aaaac6a7700 (LWP 21455)]
warning: the debug information found in
"/usr/lib/debug//lib64/libpcre.so.1.2.5.debug" does not match
"/lib64/libpcre.so.1" (CRC mismatch).

warning: the debug information found in
"/usr/lib/debug//usr/lib64/libpcre.so.1.2.5.debug" does not match
"/lib64/libpcre.so.1" (CRC mismatch).

Catchpoint 1 (exception thrown), __cxxabiv1::__cxa_throw (obj=0xf02680,
tinfo=0x2aaaaaf6b7a0 <typeinfo for
CppUnit::DynamicLibraryManagerException>, dest=0x2aaaaad1f130
<CppUnit::DynamicLibraryManagerException::~DynamicLibraryManagerException()>)
at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:63
63        PROBE2 (throw, obj, tinfo);
#0  0x00002aaaab2afb2d in __cxxabiv1::__cxa_throw(void*, std::type_info*,
void (*)(void*)) (obj=0xf02680, tinfo=0x2aaaaaf6b7a0 <typeinfo for
CppUnit::DynamicLibraryManagerException>, dest=0x2aaaaad1f130
<CppUnit::DynamicLibraryManagerException::~DynamicLibraryManagerException()>)
at ../../../../libstdc++-v3/libsupc++/eh_throw.cc:63
#1  0x00002aaaaad1ef22 in
CppUnit::DynamicLibraryManager::loadLibrary(std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > const&) (this=0x6c9110,
libraryName="/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_ucalc.so")
at DynamicLibraryManager.cpp:57
#2  0x00002aaaaad1ee03 in
CppUnit::DynamicLibraryManager::DynamicLibraryManager(std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > const&) (this=0x6c9110,
libraryFileName="/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_ucalc.so")
at DynamicLibraryManager.cpp:13
#3  0x00002aaaaad25d87 in
CppUnit::PlugInManager::load(std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> > const&,
CppUnit::PlugInParameters const&) (this=0x7fffffff4588,
libraryFileName="/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_ucalc.so",
parameters=...) at PlugInManager.cpp:32
#4  0x000000000040510d in (anonymous
namespace)::ProtectedFixtureFunctor::run() const (this=0x7fffffff48d0) at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:227
#5  0x0000000000404c09 in sal_main() () at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:431
#6  0x00000000004044e7 in main(int, char**) (argc=22, argv=0x7fffffff4cd8)
at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:338
Catchpoint 2 (exception caught), __cxxabiv1::__cxa_begin_catch
(exc_obj_in=0xf02660) at ../../../../libstdc++-v3/libsupc++/eh_catch.cc:84
84        PROBE2 (catch, objectp, header->exceptionType);
#0  0x00002aaaab2ae981 in __cxxabiv1::__cxa_begin_catch(void*)
(exc_obj_in=0xf02660) at ../../../../libstdc++-v3/libsupc++/eh_catch.cc:84
#1  0x000000000040516b in (anonymous
namespace)::ProtectedFixtureFunctor::run() const (this=0x7fffffff48d0) at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:228
#2  0x0000000000404c09 in sal_main() () at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:431
#3  0x00000000004044e7 in main(int, char**) (argc=22, argv=0x7fffffff4cd8)
at
/home/maarten/src/libreoffice/core/sal/cppunittester/cppunittester.cxx:338
DynamicLibraryManagerException: "Failed to load dynamic library:
/home/maarten/src/libreoffice/core/workdir/LinkTarget/CppunitTest/libtest_sc_ucalc.so
/home/maarten/src/libreoffice/core/instdir/program/liborcus-0.10.so.0:
undefined symbol: _ZNSt8ios_base7failureC2EPKcRKSt10error_code"
Path is
'/usr/lib64/ccache:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/home/maarten/.local/bin:/home/maarten/bin:/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.65-3.b17.fc23.x86_64/bin'
warn:legacy.osl:21451:1:unotools/source/config/configmgr.cxx:168:
OSL_ASSERT: items_.empty()
[Thread 0x2aaaac6a7700 (LWP 21455) exited]
[Inferior 1 (process 21451) exited with code 01]
/home/maarten/src/libreoffice/core/solenv/bin/gdbtrycatchtrace-stdout:13:
Error in sourced command file:
No stack.

Error: a unit test failed, please do one of:
make CppunitTest_sc_ucalc CPPUNITTRACE="gdb --args"
    # for interactive debugging on Linux
make CppunitTest_sc_ucalc VALGRIND=memcheck
    # for memory checking
make CppunitTest_sc_ucalc DEBUGCPPUNIT=TRUE
    # for exception catching

/home/maarten/src/libreoffice/core/solenv/gbuild/CppunitTest.mk:90: recipe
for target
'/home/maarten/src/libreoffice/core/workdir/CppunitTest/sc_ucalc.test'
failed
make[1]: ***
[/home/maarten/src/libreoffice/core/workdir/CppunitTest/sc_ucalc.test]
Error 1
Makefile:146: recipe for target 'CppunitTest_sc_ucalc' failed
make: *** [CppunitTest_sc_ucalc] Error 2
scan-build: Removing directory
'/home/maarten/tmp/wis/2015-11-23-091757-21395-1' because it contains no
reports.
scan-build: No bugs found.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20151123/cf2a6aa7/attachment.html>


More information about the LibreOffice mailing list