Ask Your Question

Compile opencv on Mac OS X 10.10 Yosemite

asked 2014-12-27 12:46:06 -0500

I'm trying to compile opencv in Mac Yosemite. I have tried a lot of versions of opencv but none has ended correctly. I obtain errors like this:

[ 36%] Building CXX object modules/core/CMakeFiles/opencv_perf_core.dir/perf/perf_dot.cpp.o

[ 36%] Building CXX object modules/core/CMakeFiles/opencv_perf_core.dir/perf/perf_inRange.cpp.o [ 37%] Building CXX object modules/core/CMakeFiles/opencv_perf_core.dir/perf/perf_main.cpp.o /Users/denis/Cpp/opencv- error: multiple unsequenced modifications to 'argc' [-Werror,-Wunsequenced] CV_PERF_TEST_MAIN(core) ^~~~~~~~~~~~~~~~~~~~~~~ /Users/denis/Cpp/opencv- note: expanded from macro 'CV_PERF_TEST_MAIN' CV_PERF_TEST_MAIN_INTERNALS(modulename, plain_only, __VA_ARGS__)\ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /Users/denis/Cpp/opencv- note: expanded from macro 'CV_PERF_TEST_MAIN_INTERNALS' while (++argc >= (--argc,-1)) {__VA_ARGS__; break;} /this ugly construction is needed for VS 2005/\ ^ ~~ 1 error generated. make[2]: * [modules/core/CMakeFiles/opencv_perf_core.dir/perf/perf_main.cpp.o] Error 1 make[1]: [modules/core/CMakeFiles/opencv_perf_core.dir/all] Error 2 make: ** [all] Error 2 Mac-mini-di-Denis:opencv- denis$

In Mac OS SX 10.7 Lion all ends correctly. Is there anybody that has compiled opencv correctly in Yosemite?

edit retag flag offensive close merge delete

4 answers

Sort by ยป oldest newest most voted

answered 2014-12-27 17:37:44 -0500

It looks to me like a test is failing. Try compiling with tests disabled in CMake.

The clearest tutorial I've found for compiling under OS X is this one. I haven't tried with Yosemite yet, but this worked for me with opencv3.0.0-beta under Mavericks.

edit flag offensive delete link more

answered 2014-12-29 13:30:08 -0500

Doesn't work. Already tried this tutorial: In the past I had a Mavericks mac and I hadn't got any problem with all opencv releases but, by surfing, I have found other people that can't compile opencv on Yosemite. Another question: Why I have to wait a day to can replay?

edit flag offensive delete link more

answered 2015-02-17 15:21:30 -0500

spmallick gravatar image

I recently compiled and installed OpenCV 3 on Yosemite, and documented the process. You can check it out here

edit flag offensive delete link more

answered 2015-02-04 06:50:11 -0500

ROMBA gravatar image

do you know which compiler you are using?. It did compile successfully on my mac (yosemite)

edit flag offensive delete link more

Question Tools

1 follower


Asked: 2014-12-27 12:46:06 -0500

Seen: 1,946 times

Last updated: Dec 27 '14