Ask Your Question
0

I am trying to executing cross compiled c++ program(removeRedEye) in riscv linux,but i am getting errors

asked 2018-07-27 03:53:20 -0600

I have cross compiled OpenCV application(removeRedEye) statically for RISCV architecture,now i am executing application in riscv-linux root file system,but when i am executing executable i am getting errors.Please help me in this.

Error:--

/removeRedEyes

/removeRedEyes terminate called after throwing an instance of 'cv::Exception' what(): OpenCV(3.4.2) /home/billa/Downloads/opencv-3.4.2/modules/highgui/src/window.cpp:698: error: (-2:Unspecified error) The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Carbon support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script in function 'cvWaitKey'

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2018-07-27 04:08:29 -0600

berak gravatar image

since you did not compile in any gui support (e.g. from gtk or qt), you cannot use any opencv gui functions, like imshow(), namedWindow(), waitKey()

edit flag offensive delete link more

Comments

Then what is the solution,i mean what i want to do now.

Billa Surendra gravatar imageBilla Surendra ( 2018-07-27 04:22:47 -0600 )edit

IF you need any gui, you either have to find a prebuild risc gtk or qt package, or cross-compile it from src.

(then rerun cmake & rebuild the opencv libs)

berak gravatar imageberak ( 2018-07-27 04:44:03 -0600 )edit

I have cross compiled OpenCV library statically by using -DWITH_GTK_2_X=ON -DWITH_QT=ON flags and i did re run cmake,but still i am getting same error.Please help me regarding this error.

Billa Surendra gravatar imageBilla Surendra ( 2018-07-31 04:50:18 -0600 )edit

By using this command i am cross compiling Opencv library
cmake -DCMAKE_TOOLCHAIN_FILE=../riscv.toolchain.cmake ../../.. -DWITH_PNG=OFF -DBUILD_SHARED_LIBS=OFF -DBUILD_ZLIB=ON -DBUILD_opencv_dnn=OFF -DBUILD_EXAMPLES=ON -DWITH_OPENEXR=OFF -DWITH_GTK_2_X=ON -DWITH_QT=ON -DCMAKE_EXE_LINKER_FLAGS="-static" and after that i have cross compiled Opencv Application and finally i am running executable in riscv linux i am getting Error like this way

Error :--

/removeRedEyes terminate called after throwing an instance of 'cv::Exception' what(): OpenCV(3.4.2) /home/billa/Downloads/opencv-3.4.2/modules/highgui/src/window.cpp:698: error: (-2:Unspecified error) The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Carbon support. If you are on Ubuntu or Debian, install lib

Billa Surendra gravatar imageBilla Surendra ( 2018-07-31 05:03:34 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2018-07-27 03:53:20 -0600

Seen: 536 times

Last updated: Jul 27 '18