Ask Your Question
0

Couldn't load native_sample: findLibrary returned null

asked 2013-01-21 11:41:01 -0600

Israelcp gravatar image

updated 2013-01-22 00:23:45 -0600

I downloaded opencv 2.4.3 to my ubuntu 12.04 and i tried to run the samples on my galaxy s II Adnroid 4.04. all the samples ran except ones using ndk.

I get this in console:

>**** Build of configuration Default for project OpenCV Tutorial 3 - Add Native OpenCV ****
>
>/home/icpavon/android-ndk-r8d/ndk-build 
>/home/icpavon/android-ndk-r8d/ndk-build: 1: /home/icpavon/android-ndk-r8d/ndk-build: dirname: not found
>/home/icpavon/android-ndk-r8d/ndk-build: 86: /home/icpavon/android-ndk-r8d/ndk-build: uname: not found
>ERROR: Unknown host operating system: 
>
>**** Build Finished ****

And this is the logcat:

>01-21 19:29:46.153: I/OCVSample::Activity(10322): Instantiated new class org.opencv.samples.tutorial3.Sample3Native
>01-21 19:29:46.153: I/OCVSample::Activity(10322): called onCreate
>01-21 19:29:46.163: D/CameraBridge(10322): Attr count: 3
>01-21 19:29:46.168: D/JavaCameraView(10322): Java camera view ctor
>01-21 19:29:46.178: D/OpenCVManager/Helper(10322): Service connection created
>01-21 19:29:46.178: D/OpenCVManager/Helper(10322): Trying to get library path
>01-21 19:29:46.438: D/OpenCVManager/Helper(10322): Trying to get library list
>01-21 19:29:46.713: D/OpenCVManager/Helper(10322): Library list: ""
>01-21 19:29:46.713: D/OpenCVManager/Helper(10322): First attempt to load libs
>01-21 19:29:46.713: D/OpenCVManager/Helper(10322): Trying to init OpenCV libs
>01-21 19:29:46.713: D/OpenCVManager/Helper(10322): Trying to load library /data/data/org.opencv.engine/lib/libopencv_java.so
>01-21 19:29:46.713: D/dalvikvm(10322): Trying to load lib /data/data/org.opencv.engine/lib/libopencv_java.so 0x41543fa0
>01-21 19:29:46.728: D/dalvikvm(10322): Added shared lib /data/data/org.opencv.engine/lib/libopencv_java.so 0x41543fa0
>01-21 19:29:46.728: D/OpenCVManager/Helper(10322): OpenCV libs init was ok!
>01-21 19:29:46.728: D/OpenCVManager/Helper(10322): First attempt to load libs is OK
>01-21 19:29:46.728: D/OpenCVManager/Helper(10322): Init finished with status 0
>01-21 19:30:41.783: I/Process(10414): Sending signal. PID: 10414 SIG: 9
>01-21 19:35:37.018: I/Process(10708): Sending signal. PID: 10708 SIG: 9
>01-21 19:35:44.698: I/OCVSample::Activity(11133): Instantiated new class org.opencv.samples.tutorial3.Sample3Native
>01-21 19:35:44.698: I/OCVSample::Activity(11133): called onCreate
>01-21 19:35:44.708: D/CameraBridge(11133): Attr count: 3
>01-21 19:35:44.708: D/JavaCameraView(11133): Java camera view ctor
>01-21 19:35:44.723: D/OpenCVManager/Helper(11133): Service connection created
>01-21 19:35:44.723: D/OpenCVManager/Helper(11133): Trying to get library path
>01-21 19:35:44.978: D/OpenCVManager/Helper(11133): Trying to get library list
>01-21 19:35:45.208: D/OpenCVManager/Helper(11133): Library list: ""
>01-21 19:35:45.208: D/OpenCVManager/Helper(11133): First attempt to load libs
>01-21 19:35:45.208: D/OpenCVManager/Helper(11133): Trying to init OpenCV libs
>01-21 19:35:45.208: D/OpenCVManager/Helper(11133): Trying to load library /data/data ...
(more)
edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2013-01-22 00:32:32 -0600

OpenCV Tutorial 3 - Add Native OpenCV is a sample with native C++ code. For C++ code built Android NDK is used. You have some problems with NDK or environment problems, i.e. insufficient permissions or invalid PATH variable. uname and dirname are standard Linux tools in /bin/ and /usr/bin/.

edit flag offensive delete link more

Comments

thank you for the help, but how can i fix that?

Israelcp gravatar imageIsraelcp ( 2013-01-22 02:27:33 -0600 )edit
1

Try sudo apt-get install ia32-libs

Andrey Pavlenko gravatar imageAndrey Pavlenko ( 2013-01-22 03:01:42 -0600 )edit
1

none of them worked.. any other suggestions?

Israelcp gravatar imageIsraelcp ( 2013-01-22 09:40:52 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2013-01-21 11:41:01 -0600

Seen: 1,730 times

Last updated: Jan 22 '13