0

I am compiling Open CV library on Raspbian jessie. I get below error .

>   -- Check for working CXX compiler: /usr/bin/g++ -- broken
>     CMake Error at /usr/share/cmake-3.6/Modules/CMakeTestCXXCompiler.cmake:54 (message):
>       The C++ compiler "/usr/bin/g++" is not able to compile a simple test
>       program.

I pointed it to g++-4.9 as well. Still I face the same issue. Any suggestions ?

  • Try using /usr/bin/g++ to compile a "Hello world" program. If it doesn't work, delete it and re-install. Check type g++ in Terminal. – Mark Setchell Jul 24 '18 at 11:48
  • Thanks!I tried with g++ . But I do not see any change . It still pops up the same error. I actually do not need c++. All I am concentrating is on C. So is there any way I can skip this and build my OpenCV? – pranathi Jul 24 '18 at 12:47
1

Here is what I found. I had two versions g++ and g++-4.9. I uninstalled both of them .Just installed g++4.9 and changed the path to /usr/bin/g++4.9. It solved the problem!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.