Bug 349102 - Fail cmake check when set -DBUILD_TESTING=OFF
Summary: Fail cmake check when set -DBUILD_TESTING=OFF
Status: RESOLVED FIXED
Alias: None
Product: kdepim
Classification: Applications
Component: general (show other bugs)
Version: GIT (master)
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: KDE PIM Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-06-13 13:59 UTC by Gustavo Alvarez
Modified: 2015-06-13 16:31 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gustavo Alvarez 2015-06-13 13:59:39 UTC
Hi

Hen set CMake -DBUILD_TESTING=OFF:

Error at /usr/share/ECM/modules/ECMMarkAsTest.cmake:42 (set_target_properties):
  set_target_properties Can not find target to add properties to:
  kcheckcomboboxtest_gui
Call Stack (most recent call first):
  libkdepim/tests/CMakeLists.txt:21 (ecm_mark_as_test)


CMake Error at /usr/share/ECM/modules/ECMMarkAsTest.cmake:42 (set_target_properties):
  set_target_properties Can not find target to add properties to:
  kleo-test_kdhorizontalline
Call Stack (most recent call first):
  libkleo/tests/CMakeLists.txt:9 (ecm_mark_as_test)
  libkleo/tests/CMakeLists.txt:15 (add_kleo_test)


CMake Error at /usr/share/ECM/modules/ECMMarkAsTest.cmake:42 (set_target_properties):
  set_target_properties Can not find target to add properties to:
  kleo-test_jobs
Call Stack (most recent call first):
  libkleo/tests/CMakeLists.txt:9 (ecm_mark_as_test)
  libkleo/tests/CMakeLists.txt:16 (add_kleo_test)


CMake Error at /usr/share/ECM/modules/ECMMarkAsTest.cmake:42 (set_target_properties):
  set_target_properties Can not find target to add properties to:
  kleo-test_gnupgprocessbase
Call Stack (most recent call first):
  libkleo/tests/CMakeLists.txt:9 (ecm_mark_as_test)
  libkleo/tests/CMakeLists.txt:17 (add_kleo_test)


CMake Error at /usr/share/ECM/modules/ECMMarkAsTest.cmake:42 (set_target_properties):
  set_target_properties Can not find target to add properties to:
  kleo-test_cryptoconfig
Call Stack (most recent call first):
  libkleo/tests/CMakeLists.txt:9 (ecm_mark_as_test)
  libkleo/tests/CMakeLists.txt:18 (add_kleo_test)


CMake Error at /usr/share/ECM/modules/ECMMarkAsTest.cmake:42 (set_target_properties):
  set_target_properties Can not find target to add properties to:
  kleo-test_keyselectiondialog
Call Stack (most recent call first):
  libkleo/tests/CMakeLists.txt:9 (ecm_mark_as_test)
  libkleo/tests/CMakeLists.txt:19 (add_kleo_test)


CMake Error at /usr/share/ECM/modules/ECMMarkAsTest.cmake:42 (set_target_properties):
  set_target_properties Can not find target to add properties to:
  kleo-test_keygen
Call Stack (most recent call first):
  libkleo/tests/CMakeLists.txt:9 (ecm_mark_as_test)
  libkleo/tests/CMakeLists.txt:20 (add_kleo_test)


CMake Error at /usr/share/ECM/modules/ECMMarkAsTest.cmake:42 (set_target_properties):
  set_target_properties Can not find target to add properties to:
  kleo-test_keylister
Call Stack (most recent call first):
  libkleo/tests/CMakeLists.txt:9 (ecm_mark_as_test)
  libkleo/tests/CMakeLists.txt:21 (add_kleo_test)

if set BUILD_TESTING=OFF works again

Reproducible: Always

Steps to Reproduce:
1.download kdepim and dependencies from git
2. set cmake options and include -DBUILD_TESTING=OFF
3. run cmake

Actual Results:  
fail cmake check

Expected Results:  
cmake chek ok

full cmake log http://sl1pkn07.wtf/paste/view/46a8bf1f

  cmake ../kdepim \
    -DCMAKE_BUILD_TYPE=Release \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DLIB_INSTALL_DIR=lib \
    -DKDE_INSTALL_USE_QT_SYS_PATHS=ON \
    -DBUILD_TESTING=OFF \
    -DSYSCONF_INSTALL_DIR=/etc \
    -DCMAKE_SKIP_RPATH=ON
Comment 1 Laurent Montel 2015-06-13 14:48:13 UTC
Git commit 12bb582e097b0e4ac024929a857330b6a45ee961 by Montel Laurent.
Committed on 13/06/2015 at 14:47.
Pushed by mlaurent into branch 'master'.

Fix Bug 349102 - Fail cmake check when set -DBUILD_TESTING=OFF

M  +3    -1    libkdepim/CMakeLists.txt
M  +3    -1    libkleo/CMakeLists.txt

http://commits.kde.org/kdepim/12bb582e097b0e4ac024929a857330b6a45ee961
Comment 2 desaparecido 2015-06-13 15:40:47 UTC
hi, I don't know if is here even that is marked like SOLVED, but when try to build I have this error at the end:

                                     ^
Linking CXX executable korganizer
[100%] Building CXX object korganizer/kontactplugin/korganizer/CMakeFiles/kontact_korganizerplugin.dir/korg_uniqueapp.cpp.o                                                                                       
Linking CXX shared module kontact_specialdatesplugin.so
[100%] Building CXX object korganizer/kontactplugin/korganizer/CMakeFiles/kontact_korganizerplugin.dir/korganizerplugin_debug.cpp.o                                                                               
[100%] Building CXX object korganizer/kontactplugin/korganizer/CMakeFiles/kontact_korganizerplugin.dir/calendarinterface.cpp.o                                                                                    
/usr/lib/libtemplateparser.so.5: undefined reference to `PimCommon::SyntaxHighlighterBase::~SyntaxHighlighterBase()'
/usr/lib/libtemplateparser.so.5: undefined reference to `PimCommon::SyntaxHighlighterBase::highlightBlock(QString const&)'
/usr/lib/libtemplateparser.so.5: undefined reference to `PimCommon::SyntaxHighlighterBase::qt_metacall(QMetaObject::Call, int, void**)'
/usr/lib/libtemplateparser.so.5: undefined reference to `PimCommon::SyntaxHighlighterBase::staticMetaObject'
/usr/lib/libtemplateparser.so.5: undefined reference to `PimCommon::SyntaxHighlighterBase::SyntaxHighlighterBase(QTextDocument*)'
/usr/lib/libtemplateparser.so.5: undefined reference to `typeinfo for PimCommon::SyntaxHighlighterBase'
/usr/lib/libtemplateparser.so.5: undefined reference to `PimCommon::SyntaxHighlighterBase::qt_metacast(char const*)'
/usr/lib/libmessageviewer.so.5: undefined reference to `PimCommon::NetworkUtil::lowBandwidh() const'
collect2: error: ld returned 1 exit status
korganizer/CMakeFiles/korganizer.dir/build.make:188: recipe for target 'korganizer/korganizer' failed
make[2]: *** [korganizer/korganizer] Error 1
CMakeFiles/Makefile2:8376: recipe for target 'korganizer/CMakeFiles/korganizer.dir/all' failed
make[1]: *** [korganizer/CMakeFiles/korganizer.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[100%] Building CXX object korganizer/kontactplugin/korganizer/CMakeFiles/kontact_korganizerplugin.dir/korganizerinterface.cpp.o                                                                                  
[100%] Built target kontact_specialdatesplugin
[100%] Building CXX object korganizer/kontactplugin/korganizer/CMakeFiles/kontact_korganizerplugin.dir/kontact_korganizerplugin_automoc.cpp.o                                                                     
In file included from /tmp/makepkg/kdepim-git/src/kdepim/korganizer/widgets/kitemiconcheckcombo.cpp:23:0:
/tmp/makepkg/kdepim-git/src/kdepim/korganizer/koglobals.h:78:43: warning: ‘KComponentData’ is deprecated [-Wdeprecated-declarations]
     const KComponentData &componentData() const
                                           ^
In file included from /usr/include/KF5/KDELibs4Support/KDE/KComponentData:1:0,
                 from /tmp/makepkg/kdepim-git/src/kdepim/korganizer/koglobals.h:30,
                 from /tmp/makepkg/kdepim-git/src/kdepim/korganizer/widgets/kitemiconcheckcombo.cpp:23:
/usr/include/KF5/KDELibs4Support/kcomponentdata.h:51:47: note: declared here
 class KDELIBS4SUPPORT_DEPRECATED_EXPORT_NOISE KComponentData // krazy:exclude=dpointer (implicitly share
                                               ^
In file included from /tmp/makepkg/kdepim-git/src/kdepim/korganizer/widgets/kitemiconcheckcombo.cpp:23:0:
/tmp/makepkg/kdepim-git/src/kdepim/korganizer/koglobals.h:87:20: warning: ‘KComponentData’ is deprecated [-Wdeprecated-declarations]
     KComponentData mOwnInstance;
                    ^
In file included from /usr/include/KF5/KDELibs4Support/KDE/KComponentData:1:0,
                 from /tmp/makepkg/kdepim-git/src/kdepim/korganizer/koglobals.h:30,
                 from /tmp/makepkg/kdepim-git/src/kdepim/korganizer/widgets/kitemiconcheckcombo.cpp:23:
/usr/include/KF5/KDELibs4Support/kcomponentdata.h:51:47: note: declared here
 class KDELIBS4SUPPORT_DEPRECATED_EXPORT_NOISE KComponentData // krazy:exclude=dpointer (implicitly share
                                               ^
[100%] Building CXX object korganizer/kontactplugin/korganizer/CMakeFiles/kontact_todoplugin.dir/korg_uniqueapp.cpp.o
[100%] Building CXX object korganizer/kontactplugin/korganizer/CMakeFiles/kontact_todoplugin.dir/korganizerplugin_debug.cpp.o
In file included from /tmp/makepkg/kdepim-git/src/build/korganizer/kcm_korganizer_automoc.cpp:4:0:
/tmp/makepkg/kdepim-git/src/build/korganizer/moc_kitemiconcheckcombo.cpp:88:1: warning: ‘virtual void KComboBox::setContextMenuEnabled(bool)’ is deprecated [-Wdeprecated-declarations]
 }
 ^
In file included from /usr/include/KF5/KDELibs4Support/KDE/KComboBox:1:0,
                 from /tmp/makepkg/kdepim-git/src/kdepim/libkdepim/widgets/kcheckcombobox.h:31,
                 from /tmp/makepkg/kdepim-git/src/build/korganizer/../../kdepim/korganizer/widgets/kitemiconcheckcombo.h:25,
                 from /tmp/makepkg/kdepim-git/src/build/korganizer/moc_kitemiconcheckcombo.cpp:9,
                 from /tmp/makepkg/kdepim-git/src/build/korganizer/kcm_korganizer_automoc.cpp:4:
/usr/include/KF5/KCompletion/kcombobox.h:303:41: note: declared here
     virtual KCOMPLETION_DEPRECATED void setContextMenuEnabled(bool showMenu);
                                         ^
[100%] Building CXX object korganizer/kontactplugin/korganizer/CMakeFiles/kontact_todoplugin.dir/calendarinterface.cpp.o
Linking CXX shared module kcm_korganizer.so
[100%] Building CXX object korganizer/kontactplugin/korganizer/CMakeFiles/kontact_todoplugin.dir/korganizerinterface.cpp.o
[100%] Building CXX object korganizer/kontactplugin/korganizer/CMakeFiles/kontact_todoplugin.dir/kontact_todoplugin_automoc.cpp.o
[100%] Built target kcm_korganizer
Linking CXX shared module kontact_korganizerplugin.so
[100%] Built target kontact_korganizerplugin
Linking CXX shared module kontact_todoplugin.so
[100%] Built target kontact_todoplugin
Makefile:116: recipe for target 'all' failed
make: *** [all] Error 2
==> ERROR: A failure occurred in build().
    Aborting...

All the others KF5, plasma et kdepim are GIT versions and are recently builded before.  I use Archlinux (gcc 5.1 and Qt 5.4.2)
Comment 3 Gustavo Alvarez 2015-06-13 16:31:00 UTC
builded for me with last commit. make sure you have update all dependencies to last commit