Is it dependent on the 8.0.8 branch? Or should I not wait and try to build it myself?
I assumed that within the framework of version 8 the update will happen for all platforms
ngspice is an independent project from KiCad.
On Linux systems, the norm (unless you are using something like Flatpak) is that libraries and applications are updated independently and not synchronized to release at the same time.
On Windows and macOS, KiCad bundles ngspice, so we control what version is released. But the same is not true on most Linux systems.
I don’t really understand what independent means if it is inside the code and the kicad itself. How can I update this module on Linux inside kicad? As I understand it, I shouldn’t use PPA but compile everything myself from the source code, specifying the required library versions?
It’s not inside the code and KiCad itself. KiCad uses it as an external library.
At the interface level of the scheme there is integration with the simulator and direct access. Otherwise it is not there and in windows the library is used from one developer. It turns out that depending on the platform it is updated or not and not because of its absence or presence in the code of the kicad?
Yes. This is a key principle of Linux that is worth understanding if you are coming to Linux from Windows or macOS. Ngspice is used by KiCad as a shared library, meaning it is not directly built in to KiCad. And on Linux, shared libraries from different projects are packaged and updated separately. This means that updating KiCad does not update ngspice and vice versa.
You need to wait for your Linux distribution to update Ngspice, or else you need to build it from source.
Alternatively, you can use something like FlatPak, where the shared libraries can be updated faster.
It looks to be in ‘backports’ for Debian Bookworm.
ngspice is distributed in two flavours:
ngspice (Linux, macOS) or ngspice.exe (Windows) is the standard executable.
libnspice0.so (Linux), libngspice0.dylib (macOS) or libngspice.dll (Windows) is the shared library version of ngspice.
In addition both ngspice standard or shared need some additional files like the code models (analog.cm, digital.cm etc.).
KiCad uses the shared library version of ngspice. In Debian this is Debian -- Details of package libngspice0 in bookworm-backports.
However the code models are distributed only with the standard executable in Debian -- Details of package ngspice in bookworm-backports.
So you need to install both.
is there a deb package 8.0.8 with ngspice 44?
why can’t all this be sent at once, for example, to a ppa? for what reason is it in a flat pack or other form, but not in the native deb or pp? This is not a complaint, I’m just curious. Anything is a snap flat pack, a portable version, but not a deb or pp. This applies not only to kikad, for example, and freecad does the same PPA for KiCad: 8.0 releases : “KiCad” team
I cannot reproduce that Debian. Here it installs 44.2 by default:
- check the package versions: kicad - Debian Package Tracker
→ you’ll find that for kicad version 8.0.8 you’ll need debian sid (unstable) - I installed a fresh Debian and upgraded to sid
- I then ran
apt install kicad
Launching kicad and checking the ngspice version: Help → About KiCad → Version shows ngspice 44.2:
So I’d say on Debian it works out-of-the-box.
It makes no sense to build the Ngspice library into the KiCad package, KiCad is working in principle also without any file from ngspice. And, ngspice is a own project!
Thinking the other way around would mean, if I need or want to use some functions from ngspice like a simulation outside KiCad (e.g. done on CLI) I would be needed to have installed the rather big package of kicad. There is a reason why Linux system have a bit smarter dependency checking than Windows. We have hard dependencies which are really needed as the software wouldn’t be usable, next groups are additional recommended packages that add extra functionality which are for users mostly very practical, and then also packages that are just suggested and not really needed for the functionality. E.g. documentation or some very specific AddOn which is a corner case.
Think about in bigger scenarios, even on a home server you mostly don’t want to have installed every possible software and package for a certain package. For example you want to install libreoffice without any UI stuff as you will not run an X server, but want or need to have core function usable like PDF creation from any LO formats.
ngspice 44.2 will be shortly available in bookworm-backports.
This approach creates many problems for users. If you do not embed the library, then the dependencies break, you have to compile them yourself in a separate non-system folder or use the entire zoo of various packages in the form of flat packs, snaps, etc. Here is a more detailed description of what is happening
The user has no choice when installing Kicad from the PPA repository to install the simulator library or not. There is no simple and clear way to update it separately after installing Kicad. Compiling it yourself is apparently the only way out at the moment.This is one of the many ancient problems of Kicad that has not been solved for years and honestly it irritates me knowing that I will have to do this on several machines for the normal operation of the simulator and it is repeated every time you just need to update the library
This approach creates many problems for users. If you do not embed the library, then the dependencies break, you have to compile them yourself in a separate non-system folder or use the entire zoo of various packages in the form of flat packs, snaps, etc.
No it does not as long as you walk on the way that is intended. And the intended way is to use the package manager of the distro you use together with the right archive resources.
For Ubuntu various PPAs are available, but if you use these you are out of the official distribution! These are not a core part of an Ubuntu release! PPA is an abbreviation for Private Package Archive. You need to understand basically how PPAs do work and what downside this can bring in.
The issue you mention by linking to #4 is a typical packaging issue, it’s up to the maintainer of a package to set the correct restrictions and dependencies. Welcome to the world of PPAs.
In this case, the packaging problem is not directly related to the installation from the PPA. Conditionally, if I take two ready-made deb packages, a similar situation will occur with the dependence on the simulator library (conflict). The question is in installing a common simulator library for all programs. Or each program has its own built-in isolated library or it is common for all. Now we get into the crotch if you want to use Kicad then you will not be able to use its library for other simulators. When installing Kicad with a built-in library, I cannot use this library as a common one, I think the idea is clear, but this is already a repetition)
The easiest way, as it seems to me, would be to split the PPA into 2 independent kicad and a simulator, where kicad uses the simulator’s system library, and not, as it is now, integrated into its PPA IMHO
Here is an example of this approach Install package home:ra3xdh / qucs-s
Do you know who maintains the Kiсad PPA repository? Where can I write a request? Git Lab Git Hub Forum? Is there a chance that the escort will see this? Or has he already seen it?)
I tried the option on a virtual machine, yes it was updated, but it pulled all the other libraries not related to kicad, as a result half of what worked before broke
That’s not supposed to happen. And it doesn’t do that on my system. Kicad pulls in around 20-40 packages – all related to kicad. You can install with
apt install --no-install-recommends kicad
then fewer packages are installed and only the strictly required dependencies are pulled in. Or maybe your system is configured to also install the suggested packages. A vanilla Debian installation doesn’t do that. So that’s unrelated to kicad and OT with regards to this thread.
That’s not a very specific description of what went wrong. If installing a package from the stock respositories breaks stuff, report a bug to the Debian bug tracker. That’s all I can say.
BTW: Kicad 8.0.8 (and libngspice0 44.2 for that matter) are available now in all distributions (stable-backports, testing and sid).
Not true. 8.0.8 does not contain/install ngspice 44 for Linux.
As others have mentioned, kicad uses the ngspice shared library (libngspice0). If you look at the availability of libngspice0 44 in Debian, you’ll see that it’s available on testing and sid and backports. So installing kicad 8.0.8 e.g. on testing or sid will pull in libngspice0 44.2 by default. See my screenshot posted earlier.