Trying to install Motion - missing libs

Trying to install Motion MMAL on the greatest and latest official KODI OSMC.

(from papers like this http://www.codeproject.com/Articles/665518/Raspberry-Pi-as-low-cost-HD-surveillance-camera)

getting this lib missing libavformat.so.53, and probably more along the way.
tried apt-cache search, update, upgrade … what’s not.

any ideas where i can grab these libs ?

the following libs failed to install
E: Package ‘libjpeg62-dev’ has no installation candidate
E: Unable to locate package libavformat53
E: Unable to locate package libavcodec53
E: Unable to locate package libavutil51

thanks.

I just installed OSMC and I am trying to get Hyperion running but am having similar issues and cannot find a solution (though others have referenced the same type of problem) to missing libraries in apt-get.
Did you ever find a solution avnerg?

If anyone else can advise… is there a repo we need to add to sources.list?

My current sources.list…

osmc@osmc:~$ cat /etc/apt/sources.list
deb http://mirrordirector.raspbian.org/raspbian jessie main contrib non-free
deb http://apt.osmc.tv jessie main

Here is some sample output for apt-get install

osmc@osmc:~/Downloads$ sudo apt-get install top
Reading package lists… Done
Building dependency tree
Reading state information… Done
E: Unable to locate package top

osmc@osmc:~/Downloads$ sudo apt-get install htop
Reading package lists… Done
Building dependency tree
Reading state information… Done
E: Unable to locate package htop

osmc@osmc:~/Downloads$ sudo apt-get install locate

Reading package lists… Done
Building dependency tree
Reading state information… Done
Package locate is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package ‘locate’ has no installation candidate

osmc@osmc:~/Downloads$ sudo apt-get install busybox
Reading package lists… Done
Building dependency tree
Reading state information… Done
busybox is already the newest version.
busybox set to manually installed.
The following packages were automatically installed and are no longer required:
armv6l-libafpclient-osmc rbp1-image-3.18.13-1-osmc
Use ‘apt-get autoremove’ to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

Did you do a sudo apt-get update before?
Also is this on a pi 1, Pi 2 or on a vero?

mcobit16m
Did you do a sudo apt-get update before?
Also is this on a pi 1, Pi 2 or on a vero?

I can’t believe I am about to answer that question as ‘Probably Not’ though I would have sworn…

Just did… update/upgrade and reboot and now the Hyperion dependencies are installing.

osmc@osmc:~$ sudo apt-get install git libqtcore4 libqtgui4 libqt4-network libusb-1.0-0 libprotobuf9 ca-certificates
Reading package lists… Done
Building dependency tree
Reading state information… Done
ca-certificates is already the newest version.
ca-certificates set to manually installed.
The following extra packages will be installed:
fontconfig git-man libaudio2 liberror-perl libgdbm3 libice6 libjpeg8 libmng1 libqt4-xml libqtdbus4 libsm6 libxext6 libxrender1 libxt6 perl
perl-modules qtcore4-l10n x11-common

Many thanks for the prompt mcobit!
I hope this helps someone else and its on a Pi1

If you installed a new system and did not update it before trying to install something with apt, it could be that the apt cache is not populated.
Also it is always a a good idea to update the database before installing stuff :slight_smile:

Absolutely no arguement from me on that one!

And hey presto my leds just came on after another reboot.
I’m a happy man though I still have some work to do.

unfortunately, regardless everything i tried, and i tried, nothing helped.
Sam suggested i refresh the system cache etc which i did, but it seems that these libs are missing from the cloud database this build is looking at…

i think i will have to remove OSMC in favour of my Security Cam software (Motion), not that i care to use any similar else… but i just can get it working.

any advise from the forum would be highly appreciated.

So DID you do apt-get update?
Do you have a pi 1 or a pi 2?
Come on. Help us a bit here…

Try libavcodec56, libavformat56, libavutil54 and libjpeg-dev if you are on a pi2.

Edit: Debian jessie repositories might have different packages and versions than raspbian and as you want to build from source anyway as it seems you could try to use those newer packages.

Simulating (-s) the installation on Pi1 gives the following info

osmc@osmc:~$ sudo apt-get install libjpeg62-dev -s
Reading package lists… Done
Building dependency tree
Reading state information… Done
Package libjpeg62-dev is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
libjpeg9-dev libjpeg8-dev libjpeg62-turbo-dev

and simulating the installation of libavformat56 does a lot …

osmc@osmc:~$ sudo apt-get install libavformat56 -s
Reading package lists… Done
Building dependency tree
Reading state information… Done
The following extra packages will be installed:
libavcodec56 libavresample2 libavutil54 libgsm1 libmp3lame0 libopenjpeg5
libopus0 liborc-0.4-0 libschroedinger-1.0-0 libspeex1 libtheora0 libva1
libvpx1 libx264-142 libxvidcore4
Suggested packages:
opus-tools speex
Recommended packages:
va-driver-all va-driver
The following NEW packages will be installed:
libavcodec56 libavformat56 libavresample2 libavutil54 libgsm1 libmp3lame0
libopenjpeg5 libopus0 liborc-0.4-0 libschroedinger-1.0-0 libspeex1
libtheora0 libva1 libvpx1 libx264-142 libxvidcore4
0 upgraded, 16 newly installed, 0 to remove and 0 not upgraded.
Inst libavutil54 (6:11.4-1~deb8u1+rpi1 Raspbian:stable [armhf])
Inst libavresample2 (6:11.4-1~deb8u1+rpi1 Raspbian:stable [armhf])
Inst libgsm1 (1.0.13-4 Raspbian:stable [armhf])
Inst libmp3lame0 (3.99.5+repack1-7 Raspbian:stable [armhf])
Inst libopenjpeg5 (1:1.5.2-3 Raspbian:stable [armhf])
Inst libopus0 (1.1-2 Raspbian:stable [armhf])
Inst liborc-0.4-0 (1:0.4.22-1 Raspbian:stable [armhf])
Inst libschroedinger-1.0-0 (1.0.11-2.1 Raspbian:stable [armhf])
Inst libspeex1 (1.2~rc1.2-1 Raspbian:stable [armhf])
Inst libtheora0 (1.1.1+dfsg.1-6 Raspbian:stable [armhf])
Inst libva1 (1.4.1-1 Raspbian:stable [armhf])
Inst libvpx1 (1.3.0-3+rpi1 Raspbian:stable [armhf])
Inst libx264-142 (2:0.142.2431+gita5831aa-1+rpi1+b1 Raspbian:stable [armhf])
Inst libxvidcore4 (2:1.3.3-1 Raspbian:stable [armhf])
Inst libavcodec56 (6:11.4-1~deb8u1+rpi1 Raspbian:stable [armhf])
Inst libavformat56 (6:11.4-1~deb8u1+rpi1 Raspbian:stable [armhf])

So looks like it is worth trying the updated versions avnerg

thanks for trying to help:

i have RB 1 B+
did apt-get update, apt-get upgrade, apt-cache.

thanks.

So does it work now?

should have been apt-get dist-upgrade
Derek

I have same problem. Pi1 B+. Instaled motion, then motion mmal for rasp pi cam.
It was worked on older version, but with update/upgrade it does not. Motion is an old software. Not updated. So there are no libraries libavcodec.so.53 but libavcodec.so.56 and no libavutil.so51 but 54 and nod libavformat.so.53 but …56.
So question: is there an option to get somwhere from internet those files?

You could try to symlink the libraries to their old finames. If you are lucky it will work. If not, it will throw a lot of errors during compilation. But at least you tried. If you get libs from the internet, be sure that they use the same architecture. It might be best to get them from the raspbian repos if they contain them.

I did that, but did not work. that is reason asking where to find them. I solved it with installation of older version raspbian and hope to stay that way.

anything i tried failed.

i wish someone would have taken the challenge to migrate some security camera software to OSMC.

This is a very niche use case. If it’s available in the debian repos, there’s not really any reason why you shouldn’t be able to apt-get it.

If anyone is looking at this and needs a solution, I was able to get libavformat53 by adding the wheezy repo to my sources.list.
I hope this helps .

Just be sure to remove it again after installation!
Would be better to get the deb for that lib and its dev package only.