Ask Your Question

mossi's profile - activity

2013-11-20 04:37:50 -0500 commented answer I can not run the Java using Opencv on Linux, 64bit

Just now, I could run the program, thank you for your advise. Actually, the Java on my machine was 32bit, not 64bit. So I installed the java for 64bit, then I could run the program. I spent three days for solving this problem, but I am relieved to run the program. Thank you.

2013-11-19 23:47:02 -0500 commented answer I can not run the Java using Opencv on Linux, 64bit

Thank you for your answer. But it didn't work. I can compile my java file, but when I try to run, it did't work.

The command I input is below.

tar zxvf opencv-2.4.7

cd opencv-2.4.7

mkdir build

cd build

cmake -DBUILD_SHARED_LIBS=OFF ..

sudo make -j4

javac -cp bin/opencv-247.jar Main.java

java -Djava.library.path=lib Main

Then I got the error below /mnt/sdc/yu/opencv-2.4.7/build/lib/libopencv_java247.so: /mnt/sdc/yu/opencv-2.4.7/build/lib/libopencv_java247.so: wrong ELF class: ELFCLASS64 (Possible cause: architecture word width mismatch)

Does anyone have any idea what should I do? I'm looking forward to hearing from you. Sincerely.

2013-11-18 21:26:46 -0500 asked a question I can not run the Java using Opencv on Linux, 64bit

Hi. I want to develop Java Program using OpenCv on Linux, 64bit. So I can install the OpenCv,2.4.4 for Linux. And I can compile the Sample Program using OpenCv. But When I try to run the program, I got the following error message. Exception in thread "main" java.lang.UnsatisfiedLinkError: /mnt/sdc/yu/opencv-2.4.4/build/bin/libopencv_java244.so: /mnt/sdc/yu/opencv-2.4.4/build/bin/libopencv_java244.so: wrong ELF class: ELFCLASS64 (Possible cause: architecture word width mismatch)

I think this error means the OpenCv Library is for 32bit PC, but I am running the program on 64bit PC. I want to run the program on 64bit. What should I do? I look forward to hearing from you. Sincerely.