Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 490264 - [qt overlay] =dev-qt/qtcore-5.2.0_beta1 with cmake: find_package(Qt5Core): list sub-command REMOVE_DUPLICATES requires list to be present.
Summary: [qt overlay] =dev-qt/qtcore-5.2.0_beta1 with cmake: find_package(Qt5Core): li...
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Development (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Qt Bug Alias
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-11-03 13:19 UTC by Franz Trischberger
Modified: 2013-11-06 18:55 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Franz Trischberger 2013-11-03 13:19:43 UTC
[14:21] $ cat CMakeLists.txt
find_package(Qt5Core REQUIRED)
[14:21] $ cmake .
-- The C compiler identification is GNU 4.7.3
-- The CXX compiler identification is GNU 4.7.3
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
CMake Error at /usr/lib64/cmake/Qt5Core/Qt5CoreConfig.cmake:116 (list):
  list sub-command REMOVE_DUPLICATES requires list to be present.
Call Stack (most recent call first):
  CMakeLists.txt:1 (find_package)
Comment 1 Franz Trischberger 2013-11-03 13:22:01 UTC
Just forgot:
[14:22] $ eix qtcore
[I] dev-qt/qtcore
     Available versions:  
     (4)    4.8.4-r4 4.8.4-r5 ~4.8.5 **4.8.9999[1]
     (5)    (~)5.2.0_beta1[1] **5.2.9999[1] **5.9999[1]
       {aqua c++0x debug +exceptions +glib iconv icu pch qt3support ssl test}
     Installed versions:  4.8.4-r5(4)(14:07:06 03.11.2013)(exceptions glib iconv icu qt3support ssl -aqua -c++0x -debug -pch) 5.2.0_beta1(5)[1](14:10:41 03.11.2013)(glib icu -debug -test)
     Homepage:            http://qt-project.org/ http://qt.digia.com/
     Description:         The Qt toolkit is a comprehensive C++ application development framework

[1] "qt" /var/repositories/qt

[14:22] $ eix -e cmake
[U] dev-util/cmake
     Available versions:  2.8.10.2-r2 2.8.11.2 (~)2.8.12 {emacs ncurses qt4 qt5 test vim-syntax}
     Installed versions:  2.8.11.2(08:22:10 31.10.2013)(ncurses qt4 -emacs -qt5 -test -vim-syntax)
     Homepage:            http://www.cmake.org/
     Description:         Cross platform Make
Comment 2 Daniel Scharrer 2013-11-04 01:23:29 UTC
I get this as well with dev-qt/qtcore-5.2.0_beta1 - used to work fine with dev-qt/qtcore-5.1.1 but that has been removed from the overlay along with the version bump in commit d97e6d5d354e7d73a941c66340b9dfe75ee257f0.

Interestingly, this prevents emerging =dev-utils/cmake-2.8.12 even with USE='-qt4 -qt5'.

Relevant diff between qtcore-5.1.1 and 5.2.0_beta1
--- /usr/lib64/cmake/Qt5Core/Qt5CoreConfig.cmake        2013-11-04 02:02:05.000000000 +0100
+++ /usr/lib64/cmake/Qt5Core/Qt5CoreConfig.cmake        2013-11-04 01:50:11.414779903 +0100
@@ -9,7 +9,7 @@
 get_filename_component(_realCurr "${_IMPORT_PREFIX}" REALPATH)
 get_filename_component(_realOrig "/usr/lib64/cmake/Qt5Core" REALPATH)
 if(_realCurr STREQUAL _realOrig)
-    get_filename_component(_qt5Core_install_prefix "/usr/lib64" PATH)
+    get_filename_component(_qt5Core_install_prefix "/usr/lib64/../" ABSOLUTE)
 else()
     get_filename_component(_qt5Core_install_prefix "${CMAKE_CURRENT_LIST_DIR}/../../../" ABSOLUTE)
 endif()
@@ -18,7 +18,7 @@
 unset(_IMPORT_PREFIX)
 
 # For backwards compatibility only. Use Qt5Core_VERSION instead.
-set(Qt5Core_VERSION_STRING 5.1.1)
+set(Qt5Core_VERSION_STRING 5.2.0)
 
 set(Qt5Core_LIBRARIES Qt5::Core)
 
@@ -43,9 +43,11 @@
     set(imported_location "${_qt5Core_install_prefix}/lib64/${LIB_LOCATION}")
     _qt5_Core_check_file_exists(${imported_location})
     set_target_properties(Qt5::Core PROPERTIES
-        "IMPORTED_LINK_INTERFACE_LIBRARIES_${Configuration}" "${_Qt5Core_LIB_DEPENDENCIES}"
+        "INTERFACE_LINK_LIBRARIES" "${_Qt5Core_LIB_DEPENDENCIES}"
         "IMPORTED_LOCATION_${Configuration}" ${imported_location}
         "IMPORTED_SONAME_${Configuration}" "libQt5Core.so.5"
+        # For backward compatibility with CMake < 2.8.12
+        "IMPORTED_LINK_INTERFACE_LIBRARIES_${Configuration}" "${_Qt5Core_LIB_DEPENDENCIES}"
     )
 
 endmacro()
@@ -53,10 +55,8 @@
 if (NOT TARGET Qt5::Core)
 
     set(_Qt5Core_OWN_INCLUDE_DIRS "${_qt5Core_install_prefix}/include/qt5/" "${_qt5Core_install_prefix}/include/qt5/QtCore")
-    set(Qt5Core_PRIVATE_INCLUDE_DIRS
-        "${_qt5Core_install_prefix}/include/qt5/QtCore/5.1.1"
-        "${_qt5Core_install_prefix}/include/qt5/QtCore/5.1.1/QtCore"
-    )
+    set(Qt5Core_PRIVATE_INCLUDE_DIRS)
+    include("${CMAKE_CURRENT_LIST_DIR}/ExtraSourceIncludes.cmake" OPTIONAL)
 
     foreach(_dir ${_Qt5Core_OWN_INCLUDE_DIRS})
         _qt5_Core_check_file_exists(${_dir})
@@ -94,7 +94,7 @@
     foreach(_module_dep ${_Qt5Core_MODULE_DEPENDENCIES})
         if (NOT Qt5${_module_dep}_FOUND)
             find_package(Qt5${_module_dep}
-                5.1.1 ${_Qt5Core_FIND_VERSION_EXACT}
+                5.2.0 ${_Qt5Core_FIND_VERSION_EXACT}
                 ${_Qt5Core_DEPENDENCIES_FIND_QUIET}
                 ${_Qt5Core_FIND_DEPENDENCIES_REQUIRED}
                 PATHS "${CMAKE_CURRENT_LIST_DIR}/.." NO_DEFAULT_PATH
@@ -129,7 +129,8 @@
     set_property(TARGET Qt5::Core PROPERTY
       INTERFACE_COMPILE_DEFINITIONS QT_CORE_LIB)
 
-    _populate_Core_target_properties(RELEASE "libQt5Core.so.5.1.1" "" )
+    _populate_Core_target_properties(RELEASE "libQt5Core.so.5.2.0" "" )
+
 
 
 
Responsible commit: https://qt.gitorious.org/qt/qtbase/commit/786b278f91aa4d5f1ff8fa10555bf6c8741c96a0
Upsteam fix: https://qt.gitorious.org/qt/qtbase/commit/c0e826e244632d340d4bd4892ba450d19a70fca2
Comment 3 Franz Trischberger 2013-11-04 07:59:26 UTC
Thx for the research! I applied the upstream fix and cmake now runs without an error.
Comment 4 Davide Pesavento (RETIRED) gentoo-dev 2013-11-06 18:55:54 UTC
Already fixed upstream for 5.2.0_rc1