apt shows only an old version of the package - linux

I am trying to install ffmpeg on my sistem, but for some reason when I do sudo apt install ffmpeg I only get the version 4.1.10-0+deb10u1. This is an issue because one of my apps requires at least version 4.2.7. When running apt list --all-versions ffmpeg I get the following output:
ffmpeg/oldstable,now 7:4.1.10-0+deb10u1 amd64 [installed]
ffmpeg/oldstable 7:4.1.9-0+deb10u1 amd64
I have run sudo apt update and sudo apt upgrade beforehand just in case, but it seems that the only options I have are those. I use Debian GNU/Linux 10 (buster), so I checked on their website and found that there is a stable version 4.3.5 available here. Maybe there Is something I need to update to see this version?

So it seems that adding a new source fixes the issue.
You basically need to add these two lines in the /etc/apt/sources.list file:
deb http://deb.debian.org/debian/ stable main
deb-src http://deb.debian.org/debian/ stable main
After that apt list --all-versions ffmpeg gave me the desired output:
ffmpeg/stable 7:4.3.5-0+deb11u1 amd64
ffmpeg/oldstable 7:4.1.10-0+deb10u1 amd64
ffmpeg/oldstable 7:4.1.9-0+deb10u1 amd64

Related

Debian Buster: 'E: Unable to locate package'

I have a new install of Debian Buster, I downloaded the ProtonVPN CLI package and went to install and got the errors:
E: Unable to locate package protonvpn-stable-release_1.0.0-1_all.deb
E: Couldn't find any package by glob 'protonvpn-stable-release_1.0.0-1_all.deb'
E: Couldn't find any package by regex 'protonvpn-stable-release_1.0.0-1_all.deb'
my /etc/apt/sources.list file looks like this:
#deb cdrom:[Debian GNU/Linux 10.10.0 _Buster_ - Official amd64 NETINST 20210619-16:11]/ buster main
#deb cdrom:[Debian GNU/Linux 10.10.0 _Buster_ - Official amd64 NETINST 20210619-16:11]/ buster main
deb http://deb.debian.org/debian/ buster main
deb-src http://deb.debian.org/debian/ buster main
deb http://security.debian.org.debian-security buster/updates main
deb-src http://security.debian.org.debian-security buster/updates main
deb http://deb.debian.org/debian/ buster-updates main
deb-src http://deb.debian.org/debian/ buster main
I was able to apt-get install wget as well as update and upgrdade. I even tried uncommenting the cdrom lines at the top. I reran apt-get update and apt-get upgrade.
Still, when I try to install the ProtonVPN package I get the above errors.
Note I understand that this is not strictly programming related. If there is a more appropriate stack, please let me know in comments and I will close and post there.
To install manually downloaded Debian package, use dpkg:
dpkg -i protonvpn-stable-release_1.0.0-1_all.deb
If dpkg is complaining about missing dependencies, then use apt-get -f install after running dpkg

How to install GCC 5.4 on ubuntu 17.10 (Downgrade)?

I have ubuntu 17.10.
gcc version 7.2.0 (Ubuntu 7.2.0-8ubuntu3.2)
I have to get GCC 5.4. I've tried:
sudo apt-get install gcc-5.4
sudo apt-get install gcc-5.4 g++-5.4
But i'm receiving :
E: Unable to locate package gcc-5.4
E: Couldn't find any package by glob 'gcc-5.4'
E: Couldn't find any package by regex 'gcc-5.4'
At apt-get install gcc I receive
gcc is already the newest version (4:7.2.0-1ubuntu1).
I have to downgrade to 5.4,
How can I solve it? Thanks
You can go to the packages.ubuntu.com page for gcc-5 and you will see that eg xenial still has it: https://packages.ubuntu.com/xenial/gcc-5
Now it may just be a matter of adding the xenial repo info back into /etc/sources.list (or maybe /etc/sources.list.d/xenial.conf to easily uncomment later), run apt-get update and apt-get install gcc-5.
Another alternative is to use Docker and just run in a xenial container...
I work it
https://packages.ubuntu.com/bionic/amd64/gcc-5/download
in
/etc/apt/sources.list
deb http://cz.archive.ubuntu.com/ubuntu bionic main universe

Install qmake in debian 7.11

I'm using debian 7.11.
I is said qt5 is not supported by apt-get.
$apt-get install qt4-qmake
it works.
However,
$apt-get install qt5-qmake
E: Unable to locate package qt5-qmake
Is there any work-around way to install qt5 in debian 7?
These are my sources.list
$less /etc/apt/sources.list
deb http://apt.readynas.com/packages/readynasos 6.5.1 updates apps main
deb http://mirrors.kernel.org/debian wheezy main
deb http://security.debian.org/ wheezy/updates main
deb http://egnyte-cdn.egnyte.com/storagesync/netgear6/en-us 6.5 egnyte
deb ftp://ftp.nerim.net/debian-marillat/ stable main
Take a look at this gist:
https://gist.github.com/iginosilva/fff315ff3072045e9819b6a268b4fdf2
sudo apt-get install qt5-default
It worked for Ubuntu 16 xenial
qmake --version
QMake version 3.0
Using Qt version 5.6.1 in /usr/lib/x86_64-linux-gnu
Which I think that is the correct qmake. you can check the build input on GitHub:
https://github.com/qt/qtbase/tree/5.6/qmake
At present the latest Qt version seems to be something like 5.11 or better. However one must acknowledge that released packages will (needs be) lag the bleeding edge.
If I saw things correctly, Qt 5 is available in the Jessie repositories
You should either install a debian based on Jessie (so you only use packages from it) or add the repositories from Jessie in your sources.list (copy the lines from stable and change the target to testing), sync and install Qt 5
Change Wheezy example:
deb http://http.debian.net/debian wheezy main
to Jessie:
deb http://http.debian.net/debian jessie main
Hope it helps

How to upgrade phpMyAdmin in Debian 7?

I installed some time ago phpMyAdmin on my Debian 7 server via apt-get install phpmyadmin and the version which has been installed was "3.4.11.1deb2". Current the latest version is 4.1.12 (I looked for that on the phpMyAdmin website).
My problem is, when I run the command apt-get update and apt-get upgrade it should normally update all installed packages but it doesn't update phpMyAdmin to the latest version. Do I have to do that manually and if yes, how do I to do that?
No, it behaves as expected.
Any release of Debian comes with the software versions that were considered "stable" at the time of the Debian release. Actually a "bit" earlier, as Debian goes to great lengths to make sure that the software in the release really is stable and that it plays together nicely with all other packages in that release (and there are quite a lot of packages too: iirc, Debian 7 comes with almost 50000 different software packages!).
Debian 7 (codename "wheezy") has been released on May 4th, 2013. At that time, there probably was no phpmyadmin-4.x available anywhere (not even on the harddisks of the phpmyadmin-developers). That's why Debian 7 comes with phpmyadmin-3.4.11.1.
Sometimes packages get updated after a Debian release. This is only to fix severe security problems, and never to just get a new "hot and fresh" version of a given package.
Whenever you do an aptitude update && aptitude upgrade, you will only upgrade packages in your chosen Debian release (automatically upgrading to a new release might involve downloading thousands of packages and surprise you with a completely new system the next time you look at it).
There's an online interface where you can check which version of a given package is in which (currently supported) Debian release.
So in order to get an up-to-date version of a given package you have the following options:
check whether somebody has backported a recent version of your favourite package to the Debian release you are using.
upgrade your Debian to a version that supports it
download/build the package yourself (preferably creating a proper Debian package, which you can share with other people)
You can leverage the Jessie repository to upgrade certain Wheezy packages, but all the usual admonitions apply. Testing this on a backup machine is a really good idea,
Copy /etc/apt/sources.list > /etc/apt/sources.list.wheezy
Edit the /etc/apt/sources.list file:
gedit /etc/apt/sources.list
and replace the contents of /etc/apt/sources.list
with the following lines:
deb h.t.t.p://ftp.de.debian.org/debian/ jessie main contrib non-free
deb-src h.t.t.p://ftp.de.debian.org/debian/ jessie main contrib non-free
deb h.t.t.p://httpredir.debian.org/debian jessie-updates main contrib non-free
deb-src h.t.t.p://httpredir.debian.org/debian jessie-updates main contrib non-free
deb h.t.t.p://security.debian.org/ jessie/updates main contrib non-free
deb-src h.t.t.p://security.debian.org/ jessie/updates main contrib non-free
(Change h.t.t.p > http. You can replace "de" with e.g. "us" or your country code, but it should make no difference).
Save the file and run the following command to update the sources database:
apt-get update
DO NOT RUN apt-get upgrade!
Next,
apt-get install phpmyadmin
choose your options. I didn't modify my config but did upgrade the database.
Then, just to be safe, I ran
php5enmod mcrypt
service php5-fpm restart
IMPORTANT!!! Change your repository back to wheezy!
Rename /etc/apt/sources.list to /etc/apt/sources.list.jessie
Rename /etc/apt/sources.list.wheezy to /etc/apt/sources.list
Run
apt-get update
You should be back on the Wheezy repositories.
That should do it.

How to force debian squeeze to use libqt4-dev from debian wheezy without upgrading all packages to debian wheezy?

I have a continuous integration server building some software that depends on a more recent version of libqt4-dev than the apt packages in debian squeeze provide. That version is available in debian wheezy. How can I tell apt to use libqt4-dev selectively from wheezy without upgrading all of the packages in my squeeze system to wheezy?
You can do this with apt's "preferences" functionality (man apt_preferences).
To add wheezy as a source of packages without installing anything from wheezy by default, add entries for wheezy to your sources.list, and add the following to /etc/apt/preferences (or to a file in preferences.d):
Package: *
Pin: release n=wheezy
Pin-Priority: 50
Once that is set up, you can install libqt4-dev with the following command:
apt-get install -t wheezy libqt4-dev
This will also install the dependencies of libqt4-dev, which may be numerous. Not being familiar with qt, I'm not sure whether the pinning solution here is the best way to get the newer version of qt onto a squeeze system. Another possibility is the backports repository, but I don't see qt4 in there. A third possibility is to build your own backported version using apt-get -b source.

Resources