I had my Raspberry Pi running for a while and needed to uninstall all the junk I left behind for a project.

I used tmux before and it was a blessing. I am trying to install it again, but it doesn't work.

Since it's in german I'll try to translate the error messages for you:

$ sudo apt-get install tmux
Paketlisten werden gelesen... Fertig
Abhängigkeitsbaum wird aufgebaut.
Statusinformationen werden eingelesen.... Fertig
Probieren Sie »apt-get -f install«, um dies zu korrigieren:
Die folgenden Pakete haben unerfüllte Abhängigkeiten:
libavresample-dev : Hängt ab von: libavutil-dev (= 6:11.9-1~deb8u1+rpi1) soll aber nicht installiert werden
E: Unerfüllte Abhängigkeiten. Versuchen Sie »apt-get -f install« ohne Angabe eines Pakets (oder geben Sie eine Lösung an).


$ sudo apt-get install tmux
Reading package lists... Ready
Creating dependency tree.
Reading status informations... Ready
Try »apt-get -f install« to correct following:
The following packages have unfulfilled dependencies:
libavresample-dev : Depends on: libavutil-dev (= 6:11.9-1~deb8u1+rpi1) but shouldn't be installed
E: Unfulfilled dependencies. Try »apt-get -f install« without adding a package (or write a solution)

What do I have to do here? Installing the dependencies seems not to work aswell, Install Guides from the internet are not working, sudo apt-get -f install isn't working, ...

I don't know what to do :/

  • 1
    Have you tried installing from source. An additional benefit is that you will get an updated version compared to what is in the package repo. – Steve Robillard May 22 '17 at 19:26
  • well, I am not the best with unix - I don't know by myself what to do. I probably did try to install it from source: this is the link I used gist.github.com/VladSem/e706a7755873cccefa8d. The original tmux-2.0.tar.gz doesn't exist anymore it seems and at the bottom of the page is another link which downloads correctly, but the ./configure doesn't exist or work. Can you maybe explain what I have to enter or how I have to look up the correct source? – Rasalas May 22 '17 at 19:38
  • 1
    Try the instructions here github.com/tmux/tmux you will need git installed or try this post from our blog raspberrypise.tumblr.com/post/141348857424/… you can replace 2.1 with 2.4 – Steve Robillard May 22 '17 at 19:46
  • well, thank you for that. Problem is, that if I try to execute ./configure it tells me configure: error: "curses not found" after a while and the make command cant be executed because it can't find the control file make: *** No targets given and no »make« control file found. End. ....installing from git the autogen.sh won't execute with the error autogen.sh: 15: autogen.sh: aclocal: not cound aclocal failed – Rasalas May 22 '17 at 20:20
  • 2
    You appear to have screwed up your system while trying to remove stuff. I suggest you backup the important files and burn a new SD card and start fresh. – Steve Robillard May 22 '17 at 21:15

This can actually happen over time with innocent runs of sudo apt update or installing various packages that conflict rather indirectly. When it tells you there's a dependency like libavutil-dev that "is not going to be installed", try to install it alongside, i.e.:

sudo apt install libavutil-dev tmux

If it then gives a message about a third dependency that is "not going to be installed", you can extend the command further with even more required packages.

What often eventually happens it that it'll turn out that installing the set will require removing something else, indicated clearly by the message "The following packages will be REMOVED". As long as you don't run with the -y flag you need not worry about doing damage until you decide to select yes or no depending on whether the resulting packages are expendable.

As Steve suggested it is possible to be in a state such that your packages are truly broken, but the majority of the time the "not going to be installed" error is conveniently resolvable and certainly worth investigating.

As for building from source, that could still work too. Per your error messages and the tmux README you need to install at a minimum:

sudo apt install libncurses5-dev libevent-dev autoconf automake pkg-config

and possibly other requirements before running ./autogen.sh and configure. One downside is that you might end up in the same package conflict situation depending on what's required! At the very least it'll give you more insight into the true dependency conflicts at hand.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.