testshell_markdown_tutorial_crypto fails if libgpgme is not found #2668
Steps to Reproduce the Problem
Do not have libgpgme installed and run:
All tests complete sucessfully.
@petermax2 I assigned this to you, because you added the
Did you try to do a full re-build? I can not reproduce the problem. Only
Starting with the master branch (HEAD at 8c19811 ) I ran:
root@3f4532595f7c:/libelektra# mkdir build && cd build root@3f4532595f7c:/libelektra/build# cmake -DENABLE_COVERAGE=OFF -DENABLE_OPTIMIZATIONS=OFF -DENABLE_DEBUG=ON -DENABLE_LOGGER=ON -DBUILD_STATIC=OFF -DINSTALL_SYSTEM_FILES=OFF -DPLUGINS="ALL" -DTOOLS="ALL" .. # ... <output omitted> -- Include Tool gen-gpg-testkey -- Exclude tool gen-gpg-testkey because libgpgme not found # ... root@3f4532595f7c:/libelektra/build# make -j6 # ... root@3f4532595f7c:/libelektra/build# make run_all # ... 99% tests passed, 1 tests failed out of 224 Label Time Summary: kdbtests = 103.32 sec*proc (99 tests) memleak = 94.76 sec*proc (92 tests) Total Test time (real) = 104.08 sec The following tests FAILED: 112 - testshell_markdown_path (Failed) Errors while running CTest tests/CMakeFiles/run_all.dir/build.make:57: recipe for target 'tests/CMakeFiles/run_all' failed make: *** [tests/CMakeFiles/run_all] Error 8 CMakeFiles/Makefile2:21466: recipe for target 'tests/CMakeFiles/run_all.dir/all' failed make: *** [tests/CMakeFiles/run_all.dir/all] Error 2 CMakeFiles/Makefile2:21473: recipe for target 'tests/CMakeFiles/run_all.dir/rule' failed make: *** [tests/CMakeFiles/run_all.dir/rule] Error 2 Makefile:5761: recipe for target 'run_all' failed make: *** [run_all] Error 2 root@3f4532595f7c:/libelektra/build#
Please provide more details on how to reproduce the problem!
Thank you for reporting the problem and the quick reply!
I was able to reproduce it but the problem disappeared after completely removing the build directory. So I assume it is only a problem of a CMake cache inconsistency.
Please reopen if it appears again.
I created a new build directory and re-created the same CMake setup. I still get the error.
Steps to reproduce
mkdir build2 && cd build2 cmake .. -DCMAKE_INSTALL_PREFIX:PATH=install -DCMAKE_BUILD_TYPE:STRING=Debug -DINSTALL_DOCUMENTATION:BOOL=OFF -DBUILD_DOCUMENTATION:BOOL=OFF -DINSTALL_SYSTEM_FILES:BOOL=OFF -DKDB_DB_SPEC:PATH=~/.config/kdb/build2/spec -DKDB_DB_SYSTEM:PATH=~/.config/kdb/build2/system -DKDB_DB_USER:PATH=.config/kdb/build2/user -DENABLE_DEBUG:BOOL=OFF make -j 8 make run_all
I used my
If you also want some system information:
EDIT: it shouldn't be relevant here, but when using
I can reproduce with above CMake command. ctest -V -R testshell_markdown_tutorial_crypto is enough to run the test.
I think the problem here is that the gen-gpg-testkey tool is never removed because CMake did not try to add it and thus it is not in the REMOVED_TOOLS variable.
Ideally, we should rewrite the handling of TOOLS, so that it behaves like PLUGINS and BINDINGS. Then such a bug would not be possible.
@kodebach you can use
@petermax2 as quickfix, please add gen-gpg-testkey to the default tools, otherwise this problem appears for everyone not passing above mentioned