Re: [javacv] /libjniavutil.so: libavutil.so.52: cannot open shared object file: No such file or directory

311 views
Skip to first unread message

Samuel Audet

unread,
Apr 14, 2013, 7:06:12 AM4/14/13
to jav...@googlegroups.com
On 04/11/2013 09:41 PM, Robby Balona wrote:
> I cant seem to find the libavutil.so.52 that java is looking for. If
> anyone can point me in the right direction I will be very happy . I am
> running Ubuntu 12.04 with Eclipse and Java 1.7.0_15

Try to use the "CPPJARs" files from here as indicated in the README.txt
file:
http://code.google.com/p/javacv/downloads/list

Samuel

Robby Balona

unread,
Apr 22, 2013, 4:31:44 AM4/22/13
to jav...@googlegroups.com
Ok Gonna try that thanks!!!

Robby Balona

unread,
Apr 22, 2013, 5:37:43 AM4/22/13
to jav...@googlegroups.com
No Didnt get it right.. not sure where the jar are after following the readme.txt build



On Thursday, 11 April 2013 14:41:50 UTC+2, Robby Balona wrote:
Hi All


I am new to java and javacv and I am trying to stream video in my java application and I get the following error.

/tmp/javacpp8423165394140/libjniavutil.so: libavutil.so.52: cannot open shared object file: No such file or directory

I built the the latest ffmpeg from their git server and when i run ffmpeg I get,

ffmpeg version N-51892-gf1e606c Copyright (c) 2000-2013 the FFmpeg developers
  built on Apr 11 2013 13:53:06 with gcc 4.7 (Ubuntu/Linaro 4.7.2-2ubuntu1)
  configuration: --disable-yasm
  libavutil      52. 26.100 / 52. 26.100
  libavcodec     55.  2.100 / 55.  2.100
  libavformat    55.  2.100 / 55.  2.100
  libavdevice    55.  0.100 / 55.  0.100
  libavfilter     3. 52.101 /  3. 52.101
  libswscale      2.  2.100 /  2.  2.100
  libswresample   0. 17.102 /  0. 17.102
Hyper fast Audio and Video encoder
usage: ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}...

I cant seem to find the libavutil.so.52 that java is looking for. If anyone can point me in the right direction I will be very happy . I am running Ubuntu 12.04 with Eclipse and Java 1.7.0_15
Here is what my code looks like

import com.googlecode.javacv.CanvasFrame;
import com.googlecode.javacv.FFmpegFrameGrabber;
import com.googlecode.javacv.FrameGrabber;
import com.googlecode.javacv.cpp.opencv_core.IplImage;

public class Main {

public static void main(String[] args) throws Exception {

FrameGrabber grabber = new FFmpegFrameGrabber("http://10.1.1.189/video2.mjpg");

grabber.setFormat("mjpeg");
grabber.start();

IplImage frame = grabber.grab();
CanvasFrame canvasFrame = new CanvasFrame("Camera");
canvasFrame.setCanvasSize(frame.width(), frame.height());
while (canvasFrame.isVisible() && (frame = grabber.grab()) != null) {
canvasFrame.showImage(frame);
}
grabber.stop();
canvasFrame.dispose();
System.exit(0);

}
}


Many Thanks for the help

Samuel Audet

unread,
Apr 27, 2013, 9:13:00 PM4/27/13
to jav...@googlegroups.com
On 04/22/2013 06:37 PM, Robby Balona wrote:
> No Didnt get it right.. not sure where the jar are after following the readme.txt build

I see plenty of JAR files in this file:
http://javacv.googlecode.com/files/javacv-0.5-cppjars.zip
Just put them all in your CLASSPATH as explained in the README.txt file:
http://code.google.com/p/javacv/#Quick_Start_for_OpenCV_and_FFmpeg

Samuel
Reply all
Reply to author
Forward
0 new messages