Ask Your Question
0

CMake Error at cmake/OpenCVDetectCXXCompiler.cmake

asked 2015-07-04 04:18:03 -0600

mbsariyildiz gravatar image

Hello everyone! This is my first post. I'm having trouble with compiling OpenCV in openSUSE Tumbleweed. I get an error when I try to configure with both cmake-gui and cmake. Error is:

CMake Error at cmake/OpenCVDetectCXXCompiler.cmake:85 (list):
  list GET given empty list
Call Stack (most recent call first):
  CMakeLists.txt:109 (include)


CMake Error at cmake/OpenCVDetectCXXCompiler.cmake:86 (list):
  list GET given empty list
Call Stack (most recent call first):
  CMakeLists.txt:109 (include)


CMake Error at cmake/OpenCVDetectCXXCompiler.cmake:89 (math):
  math cannot parse the expression: "*100 + ": syntax error, unexpected
  exp_TIMES, expecting exp_OPENPARENT or exp_NUMBER (1)
Call Stack (most recent call first):
  CMakeLists.txt:109 (include)

Following line after the error is that:

Detected version of GNU GCC:  ()

Is it meaning that something is wrong with the GCC, because there should be version written inside the brackets?

I don't know much about cmake to solve this problem, so unfortunately I'm stuck.

cmake version 3.2.3 gcc version 5.1.1 20150622 [gcc-5-branch revision 224722] (SUSE Linux) Itried both opencv-3.0.0 and opencv-master but got same error.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2018-06-20 10:14:32 -0600

https://github.com/opencv/opencv/pull...

sir, this error puzzled me for some hours and i found this github page. i will take OpenCV2.4.13 as example, in file opencv2.4.13/cmake/ OpenCVDetectCXXCompiler.cmake, u have to change "dumpversion" to "dumpfullversion"

explanation is that in gcc with higher version, dumpversion function can't get true full version number of compiler so that cmake progress will fail.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2015-07-04 04:18:03 -0600

Seen: 7,819 times

Last updated: Jun 20 '18