KiCAD on Ubuntu 20.04 has broken packages

I tried to install kicad with kicad-libraries in Ubuntu 20.04 but there are dependency errors

-----------------------------------------------------------------
sudo apt-get install --install-recommends kicad kicad-libraries 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 kicad-libraries : Depends: kicad-footprints but it is not going to be installed
                   Depends: kicad-symbols but it is not going to be installed
                   Depends: kicad-templates but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
-----------------------------------------------------------------

so I tried to install them, but kicad-common has conflicts

-------------------------------------------------------------------------
sudo apt-get install kicad-libraries kicad-footprints kicad-symbols kicad-templates 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 kicad-footprints : Conflicts: kicad-common
 kicad-symbols : Conflicts: kicad-common
 kicad-templates : Conflicts: kicad-common
                   Recommends: kicad-libraries (>= 1:0.1) but 5.1.5+dfsg1-2build2 is to be installed
E: Unable to correct problems, you have held broken packages.

It just install kicad but don’t install libraries, symbols, templates.

On my machine kicad-common is not installed. Description says “This is a transitional package. It can be safely removed.”

My machine has kicad, kicad-libraries (depends on kicad-footprints, kicad-symbols, kicad-templates), kicad-packages3d, kicad-doc-en, and kicad-demos

Do you get your packages from here? I install from source on Debian so I don’t know what the package structure is. If you added that repository then you could have TWO instances to choose from.

If the question is to me, the answer is no. I used the PPA in 18.04, but on update all PPAs are inactivated. I was expecting to re-activate the PPA, but there is no need just now. In my case the packages are from the distro, just now.

There are multiple threads alrady about that “problem”, please have a look into the referenced answer from me and start at:

O.k. now looking at the issue.
…

1 Like

That thread is long and hard to follow, but yes, the answer is there. I thought I’d just give a brief answer, but perhaps it was too brief.

(If you are on stock Ubuntu 20.04, and do not plan to use the PPA of js-reynaud, perform

sudo apt remove kicad-common; sudo apt install kicad kicad-libraries

If you want the 3D models, also perform

sudo apt install kicad-packages3d

(last edit: ensure kicad itself is installed))

1 Like

One final comment: Ubuntu kicad-libraries tells me “Breaks: kicad-common (<< 5.0.0~rc1+dfsg1-1~)” but seems to break all versions of kicad-common. This is why it needs to be removed manually. I’ll report this to Ubuntu if it is not done already.

I’m not sure what you trying to say.

It’s the intended behavior that the package kicad-common is getting a breaks from kicad-libaries.

kicad-common is a old arch-independent real package that was available before kicad 5.0.0. The content of this old package was split off into new packages (all the library stuff).
User must get installed the newly introduced packages automatically once they get the usual update via the archive. Debian and also Ubuntu is using for this the variables Replace in combination with Breaks. So kicad-common has a Depends on kicad-libraries that than pulls in all the depending libraries. Have a look at the graphic from Debian wiki site for KiCad to see an overview of the dependencies:

But there is no automatic way (while updating the installed packages) we get the now transitional package kicad-common removed at later time. So users need to remove such transitional packages in most cases by themselves. You can use aptitude or also apt-get to detect transitional packages that are not depending an anything left and let them remove afterwards.

It’s no problem if the transitional packages stay installed, they don’t cost any notable space. So don’t care much about this.

All other issues maybe seen are packaging or configuration issues regarding version dependencies. As written in the other post, PPAs have ups and downs. Jean-Samuel and myself staying in contact to keep version conflicts if possible away from users. But I do not follow the work of JS in detail, but sometimes I see some incompatibilities within the versions within the PPAs or Ubuntu is using the pinning mechanism not or not correctly.

Normally a user will just get installed the greatest available version and this should be possible here as JS and myself have agreed on the same package structure in Debian and native Ubuntu on one side and on JS PPAs on the other side.
The archive management system within apt is allowing more criteria than just to decide to install a package from an archive that has the highest version number. You can also chose to prefer packages from on specific repo over some other repo, but this requires always a successful solution of version dependencies. But this must be reviewed in detail then.

I do understand package structure, “Dependencies”, “Breaks”, and “Replaces”. Long posts about the package system are perhaps informative but not all that useful.

In this particular case, I can no longer reproduce the issue, there is no conflict between kicad-libraries and kicad-common within 20.04 itself. Your long posts boil down to the claim that there is a well thought out structure of the packages, and yes, within 20.04 that seems to be the case.

But the problem did occur, for me in an update from Ubuntu 18.04 to 20.04. The kicad installation did break going from one LTS to another. After update, no footprints, symbols, or templates are installed. See the top post here. I can fix this easily, others may not.

This needs to be fixed before 20.04 goes live “for real”, this summer. Otherwise you will have a storm of “problems” when that happens. If you are the Ubuntu package manager, then I would suggest you do something about the upgrade process.

Question: Perhaps this occurs in the upgrade if the PPA is active in 18.04 (and deactivated in the upgrade)?

If this is the case, can you amend the PPA so that that upgrade path is handled gracefully? Or the packages in Ubuntu 20.04?

I’m not involved what Ubuntu is doing, Ubuntu is pulling most of their packages from Debian testing without there are specific maintainers responsible for anything. And in the end there is in most cases no need for that. Updates are just working as designed. The release manager of Ubuntu taking care that the new release is working as it’s wanted.

The problem you seems to had is indeed introduced by this or an other PPA, but also you are responsible for the behavior of your system on your own (not Ubuntu) if you using additional PPAs. You have added the foreign archive sources, not Ubuntu.

If you have problems with an PPA get please in touch with it’s maintainer.

Your answer is not helpful, this time either, “you are responsible for the behavior of your system”, really? I can take care of my system. I am trying to help others. The jury is still out on your contributions. Long explanations of the packaging system are not helpful to this issue. Neither is rereading them.

In conclusion I repeat: if there are troubles when updating to 20.04, and you do not plan to use the PPA of js-reynaud just now, perform

sudo apt remove kicad-common; sudo apt install kicad kicad-libraries

If you want the 3D models, also perform

sudo apt install kicad-packages3d

This will probably fix your issue.

you’re pretty mouthy for someone complaining about a hypothetical problem that

The problem isn’t hypothetical.

I can’t reproduce the issue on my machine as it is now. I could reproduce the issue by doing a clean install of 18.04, installing kicad from the PPA, and then upgrading to 20.04. But enough is enough.

Quite many people have now had a problem with KiCad installation after upgrading to 20.04. It’s not hypothetical.

I use mostly self-compiled KiCad on Kubuntu, so I don’t have much to say about packaging. But, for the record, I have used Debian and later Kubuntu since 90’s. When I used Debian I drifted from stable to testing. So I’m not a newbie in these things, altough not very active either. But I can agree with Jan-Åke that tijuca’s answers have been difficult to understand walls of text. In this case users need just simple solutions, not explanations or excuses why this or that party is or isn’t guilty.

I first installed a linux machine early '95. (I’ve seen worse than this: I once had the program “mount” disappear in a system upgrade before Depends was invented, because a packager split off mount to its own package. Reboots are difficult if you cannot mount the disk. Solution: boot from a floppy (!) and bring the system back by hand.)

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.