Ask Your Question

Revision history [back]

I explicitly specified the following option in CMake command. As a result, CMake could find Qt.

-D Qt5Concurrent_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5Concurrent" ^
-D Qt5Core_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5Core" ^
-D Qt5Gui_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5Gui" ^
-D Qt5OpenGL_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5OpenGL" ^
-D Qt5Test_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5Test" ^
-D Qt5Widgets_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5Widgets" ^

I tried the following environment.

  • OpenCV 2.4.9
  • VS2012 Win32
  • Qt5.4.0

I explicitly specified the following option in CMake command. As a result, CMake could find Qt.

-D Qt5Concurrent_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5Concurrent" ^
-D Qt5Core_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5Core" ^
-D Qt5Gui_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5Gui" ^
-D Qt5OpenGL_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5OpenGL" ^
-D Qt5Test_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5Test" ^
-D Qt5Widgets_DIR="C:\Qt\Qt5.4.0\5.4\msvc2012_opengl\lib\cmake\Qt5Widgets" ^

I tried the following environment.

  • OpenCV 2.4.9
  • VS2012 Win32
  • Qt5.4.0
  • Windows 8.1 Pro

On the other hand, CMake can find Qt without this specify in Ubuntu14.10(https://gist.github.com/atinfinity/259249a2ef787e358e72) . So, could you please teach the result of following command?

dpkg -l | grep libqt