Ubuntu 20.04 and KiCad

Hello, I installed the new Ubuuntu 20.04 version today, and I reinstalled kicad 5.15, but I found there is no modules directory in the kicad directory. I used follow step which is provided by kicad.org

$sudo add-apt-repository --yes ppa:js-reynaud/kicad-5.1
$sudo apt update
$sudo apt install --install-recommends kicad
$sudo apt install kicad-demo

After install completed, there are only four directory in /usr/share/kicad, they are
demos, plugins, scripting, template

And then I have tried to use manual install again, by use these

$sudo apt install --no-install-recommends kicad
$sudo apt install kicad-symbols
$sudo apt install kicad-templates
$sudo apt install kicad-footprints
$sudo apt install kicad-packages3d

So far evethins is OK.
but I got the follow error message when I was tring to install KiCad library.

$ sudo apt install 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.

What am I suppose to do? Any information will be appreciated.

Check this: https://launchpad.net/~js-reynaud/+archive/ubuntu/kicad-5.1?field.series_filter=focal

Thereā€™s no ā€œkicad-librariesā€ metapackage there, but ā€œkicad-library-allā€.

Make also sure you donā€™t have other kicad ppa archives active if you have used them before.

I still donā€™t understand. I just tried installing ā€˜kicad-library-allā€™, but it didnā€™t work either. I have emptied the /var/cache/apt/archives directory, and emptied /etc/apt/sources.list.d, then I re-installed by use the official method, and there is still no libraries directory and files.

Thatā€™s not correct! Of course there is a package kicad-libraries, this is a metapackage that is depending on all libraries related to KiCad as described within the package description (if people would just read it).

Please distinguish between the official Ubuntu packages and other possible packages provided by PPAs! And by this how packages and the dependency resolver can act. The packages that are provided by rs-reynaud and Ubuntu doesnā€™t have always suitable values to solve package versions correctly every time. Doing this ā€œrightā€ is the hard thing in packaging software.

O.k. now looking at the issue.
Ubuntu 20.04 is the new LTS version of Ubuntu. Ubuntu is pulling most of itā€™s packages from Debian testing. The soure package site for KiCad in Ubuntu is here:

https://launchpad.net/ubuntu/+source/kicad

Looking at the binary package site for Focal Fossa (aka 20.04) you see the current provided versions for KiCad.

https://launchpad.net/ubuntu/focal/+source/kicad

And these versions are equal to the version in Debian testing (except for the appendix build2), and also equal to the latest official release of KiCad, this is right now is 5.1.5. So you normally doesnā€™t need to enable the PPA from js-renaud as long you want to use the stable version. Seems to me people just blindly do c&p without really thinking about they doing.

This step is useless, as written above, kicad-libraries is a metapackage that is depending on all the packages you have installed previously. Currently you donā€™t need to do anything.
Even on Ubuntu with no added PPA from js-reynaud itā€™s enough to just call sudo apt install kicad. No need to use --no-install-recommends on a desktop system! The kicad binary package has a recommends on kicad-libraries and kicad-demos, the latter is a binary package which you requested to install, kicad-libraries itself has dependencies on kicad-footprints, kicad-symbols, kicad-templates and these are also the real binary packages you have requested to install.

$ apt show kicad
...
Recommends: kicad-libraries, kicad-demos, xsltproc
...

$ apt show kicad-libraries
...
Depends: kicad-footprints, kicad-symbols, kicad-templates
...

Itā€™s extremely helpful to understand how the package system is working and how to read the various information you can get from it. PPAs can provide really a great user experience and enhance the core system of Ubuntu, but you need to know and understand how they are designed to work.

And please donā€™t touch anything in /var/{cache,lib}/apt if you not really know what you doing, this can damage your system completely!

1 Like

Hi, tijuca:

Thank you very much for your patience to answer, which completely uncovered my doubts and was very helpful.

Can you provide me some instruction about how the system is packaged? I want to know more about it. Thanks again.

1 Like

Looking at the bottom of that page thereā€™s no package ā€œkicad-librariesā€, just ā€œkicad-library-allā€. But looking at the package details, it says ā€œkicad-libraryā€ .deb package. Thatā€™s of course confusing.

I havenā€™t upgraded to Kubuntu 20.04 so I canā€™t test myself. Very often I do test before answering, so hopefully this will be the last time I offer incorrect informationā€¦ :slight_smile:

I can just speak about the Debian packaging and nothing about the packaging JS Reynaud is doing. JS is doing basically the same like me, but some things are slightly different of course but we have agreed to use the equal package names as this make package upgrades on the user side more easily.
The Debian packaging is done by the Debian Electronics Team, doing the work is done basically by me as person but Iā€™m open for other contributors of course. Iā€™ve been contacted by just a few people who have interested in participating but no one was really responsive any more after one or two answering emails from me. :wink:
The KiCad packages are split of into various source and binary packages, they all live within the Debian GitLab instance called Salsa.

Some time ago I created a additional wiki site within the Debian wiki as pictures can explain things better than words mostly, itā€™s in between time a bit outdated. :frowning:

https://wiki.debian.org/KiCad

Have a look at the visualization at the bottom of that page, itā€™s show the relations of the various binary packages. As packages in the original Ubuntu package archive excatly the same it shows your current situation with 20.04 too.

You donā€™t say on which page you have found this so I canā€™t say anything useful. Of course the right thing is to avoid such confusions if there are any. Iā€™m using Ubuntu very very rarely so I canā€™t really contribute here. Iā€™m really unhappy that e.g. the Download page for Ubuntu on kicad.org is only reflecting the PPA provides by JS Reynaud, this is in my eyes just wrong. Users should get pointed to use the packages by their distribution first as this is the whole point of a distribution, users get all the stuff from one trustworthy site! And then as an addition show and guide interested users how to add and use JS PPA for newer versions with newer features.

1 Like

Thanks a lot. The wiki page is awesome.

I would say that there is something wrong.
I have previously been successful in installing KiCad + separate libraries for version 5.n.
Now, the official installation guide do not work with Ubuntu 20.04 LTS.


I have no clue whatā€™s wrong and I donā€™t claim to know.
There is also an issue when the libraries are not installed correctly where a modal window open with a grayed out import option and no way to close the window. If you get into that mode the only solution is to force quit / Kill KiCad.
If you follow the installation documentation that KiCad provides it should work. You should not need to know everything about Ubuntu package manager ins and out. This is not the development branch and a normal user should be able to install the stable version without a vast knowledge.
If someone has that knowledge maybe you could write an installation guide and update the official one that seems to fail?
Have tried to use Ubuntu Graphical Application Service as well from bash terminal on bare metal and in virtual machine.

Then please read the whole thread again from the beginning.

And yes, the documentation is wrong for the current LTS 20.04 of Ubuntu. All you need and want to know is written in detail above.

This wont work if the ā€œuserā€ isnā€™t willing to understand how their distribution is basically working.

I donā€™t think itā€™s too much to expect the instructions on official download page to just work. Users can not be expected to understand intricacies of package management, it may seem trivial and ā€œbasicsā€ of how distribution works for us, tech folks, but for many users itā€™s not.

On the other hand 20.04 is fairly new, documentation will catch up.

What is surprising to me is why instructions donā€™t work any more for this release. Is it just the fact that 20.04 already has kicad 5.1 and the instructions should just have an extra clause ā€œfor 20.04 just do apt-get install kicadā€ ?

1 Like

Fantastic tijuca this is great news.

Yes you got me I myself rate me as very stupid and a total noob that cant even read the instruction above to get it to work because I am not willing.
Fortunately for me and people with the same low comprehension you are here in this forum.
And if you just modify this official installation guide with the right steps it will work.


sudo add-apt-repository --yes ppa:js-reynaud/kicad-5.1
sudo apt update
sudo apt install --install-recommends kicad

This will perform a full installation.


You can test your installation commands in a virtual box before you submit it here.
But I donā€™t want you to waist time on testing it. (Surely you donā€™t have to as you are on top of this.) I can do the tedious part with downloading an ISO and start a virtual machine and verify that your improved installation commands works.

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