Unable to install libsdl2-dev due to unmet dependencies
Don't try this command:
sudo apt-get install 229-4ubuntu6
E: Unable to locate package 229-4ubuntu6
Because there isn't any package with 229-4ubuntu6
name in repositories.
The apt output says
libudev1 (= 229-4ubuntu4) but 229-4ubuntu6 is to be installed
That means , the 229-4ubuntu6
version of libudev1
has been installed yet but the 229-4ubuntu4
version is required.
And the other things is that, the last version of libudev1
for xenial
is 229-4ubuntu17
but your apt returns the last version is 229-4ubuntu6
. This issue is happened because of that, many Ubuntu's repositories is disabled on your system and your repositories is not updated.
So as the first step we try to enable all of your Ubuntu repositories with this commands:
sudo add-apt-repository main
sudo add-apt-repository universe
sudo add-apt-repository restricted
sudo add-apt-repository multiverse
Then update your repositories and your packages:
sudo apt update
sudo apt upgrade
Then try to fix broken packages:
sudo apt -f install
And as the last step try to install libsdl2-dev
package:
sudo apt install libsdl2-dev
Update: Please add this lines to your /etc/apt/sources.list
file:
deb http://archive.ubuntu.com/ubuntu xenial universe multiverse
deb-src http://archive.ubuntu.com/ubuntu xenial universe multiverse
deb http://us.archive.ubuntu.com/ubuntu/ xenial universe
deb-src http://us.archive.ubuntu.com/ubuntu/ xenial universe
deb http://us.archive.ubuntu.com/ubuntu/ xenial-updates universe
deb-src http://us.archive.ubuntu.com/ubuntu/ xenial-updates universe
deb http://us.archive.ubuntu.com/ubuntu/ xenial multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ xenial multiverse
deb http://us.archive.ubuntu.com/ubuntu/ xenial-updates multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ xenial-updates multiverse
deb http://security.ubuntu.com/ubuntu xenial-security universe
deb-src http://security.ubuntu.com/ubuntu xenial-security universe
deb http://security.ubuntu.com/ubuntu xenial-security multiverse
deb-src http://security.ubuntu.com/ubuntu xenial-security multiverse
And comment this lines:
deb http://ftp.belnet.be/ubuntu.com/ubuntu/ xenial multiverse restricted universe main
deb-src http://ftp.belnet.be/ubuntu.com/ubuntu/ xenial multiverse restricted universe main #Added by software-properties
And then try this commands to update repositories and packages:
sudo apt update
sudo apt upgrade
Then try to install it again:
sudo apt install libsdl2-dev