Can't start: Failed to load shared library [solved]

EDIT: the solution:

Confirm before instructing the first command (apt remove) to continue that only kicad and libocct* libraries are being removed. If it says that other packages are being removed, either don’t execute it or be prepared to reinstall those packages afterwards:

$ sudo apt remove "libocct*"
$ sudo apt install kicad

EDIT2: after upgrade to 24.10, after re-adding the PPA and apt-get update’ing, I tried to install and it did not work:

Unsatisfied dependencies:
 libocct-visualization-7.8 : Depends: occt-misc (= 7.8.1+dfsg1-2) but 1:7.6.3+dfsg1-8~ubuntu24.04.1 is to be installed

What I needed to do:

$ sudo apt remove "libocct*"
$ sudo apt-get autoremove
$ sudo apt-get install kicad

(note that you need to be aware of what this may do on your particular system.)

Original post:

Hi – Kicad 8.0.4 on Kubuntu 24.04, installed via kicad PPA. Kicad has been working fine the last year or so, but with a recent update I can no longer open any PCB projects. (Schematics open fine.)

I see “Application cannot start” with:

Failed to load shared library ‘/usr/bin/_pcbnew.kiface’: libTKBO.so.7: cannot open shared object file: No such file or directory

Any ideas what might be going on?

Version info:

Application: KiCad x86_64 on x86_64

Version: 8.0.4-8.0.4-0~ubuntu24.04.1, release build

Libraries:
wxWidgets 3.2.4
FreeType 2.13.2
HarfBuzz 8.3.0
FontConfig 2.15.0
libcurl/8.5.0 OpenSSL/3.0.13 zlib/1.3 brotli/1.1.0 zstd/1.5.5 libidn2/2.3.7 libpsl/0.21.2 (+libidn2/2.3.7) libssh/0.10.6/openssl/zlib nghttp2/1.59.0 librtmp/2.3 OpenLDAP/2.6.7

Platform: Ubuntu 24.04 LTS, 64 bit, Little endian, wxGTK, X11, KDE, x11

Build Info:
Date: Jul 17 2024 01:36:30
wxWidgets: 3.2.4 (wchar_t,wx containers) GTK+ 3.24
Boost: 1.83.0
OCC: 7.6.3
Curl: 8.5.0
ngspice: 42
Compiler: GCC 13.2.0 with C++ ABI 1018

Build settings:

Thanks!

Do you also have FreeCAD daily build installed from PPA? If so, this is probably the problem, they have moved to a newer version of OpenCASCADE than KiCad and both can’t coexist at the moment on Ubuntu 24.04

1 Like

Hmmm, interesting thanks. I do not have FreeCAD installed via ppa. I do use it, but I use the appimage because AFAIK there is no maintained package for 24.04.

Is there something else that might be installed that is using OpenCASCADE? Looking here I don’t see anything I use… but I did have FreeCAD installed via ppa (IIRC) under 23.10 so maybe there are lingering incompatible libraries? Any tips on how to investigate?

Edit: looks like Open CASCADE version 7.6 is installed, judging by the package manager… what version should be installed?

I also have OCC 7.6.3

Application: KiCad x86_64 on x86_64

Version: 8.0.4-8.0.4-0~ubuntu20.04.1, release build

Libraries:
	wxWidgets 3.2.2
	FreeType 2.10.1
	HarfBuzz 2.6.4
	FontConfig 2.13.1
	libcurl/7.68.0 OpenSSL/1.1.1f zlib/1.2.11 brotli/1.0.7 libidn2/2.2.0 libpsl/0.21.0 (+libidn2/2.2.0) libssh/0.9.3/openssl/zlib nghttp2/1.40.0 librtmp/2.3

Platform: Linux Mint 20.3, 64 bit, Little endian, wxGTK, X11, xfce, x11

Build Info:
	Date: Jul 17 2024 01:37:21
	wxWidgets: 3.2.1 (wchar_t,wx containers) GTK+ 3.24
	Boost: 1.71.0
	OCC: 7.6.3
	Curl: 7.68.0
	ngspice: 42
	Compiler: GCC 9.4.0 with C++ ABI 1013

Build settings:

1 Like

Thanks, Paul – and KiCad is working for you?

Try doing:

sudo apt update
sudo apt upgrade

Thanks @dsa-t – all up to date.

Some further info: there is apparently no libTKBO.so anywhere on my system.

If I run /usr/bin/_pcbnew.kiface directly I get a segfault.

The output of ldd /usr/bin/_pcbnew.kiface is at the end of this post – seems like a lot of missing stuff there – not sure what should be concerning, but notably libTKBO is the first listed as not found. Also, all the “not found” entries start with “libTK”.

I found this thread where a user (comment here) installs libocct-modeling-algorithms-7.6t64 because the installed libocct-modeling-algorithms-7.6 doesn’t actually include any .so files… I see that with my installed libocct-modeling-algorithms-7.6 package that does seem to be the case:

$ dpkg -L libocct-modeling-algorithms-7.6

/.
/usr
/usr/lib
/usr/lib/x86_64-linux-gnu
/usr/share
/usr/share/doc
/usr/share/doc/libocct-modeling-algorithms-7.6
/usr/share/doc/libocct-modeling-algorithms-7.6/changelog.Debian.gz
/usr/share/doc/libocct-modeling-algorithms-7.6/copyright
/usr/share/lintian
/usr/share/lintian/overrides
/usr/share/lintian/overrides/libocct-modeling-algorithms-7.6

…no .so files or other files of use in there??

So it would seem like maybe I need to install the “t64” package, and that perhaps there is a bug in the package dependencies for kicad? Does anyone have any insight here? Apparently the t64 package is the 2038-bug-ready version of a package, but I’m not clear why one package would have .so files in it and the other would not, unless there was a packaging mistake?

Edit to add: output of ldd /usr/bin/_pcbnew.kiface:

	linux-vdso.so.1 (0x00007ffc907b1000)
	libwx_gtk3u_gl-3.2.so.0 => /lib/x86_64-linux-gnu/libwx_gtk3u_gl-3.2.so.0 (0x0000770d493bc000)
	libwx_gtk3u_aui-3.2.so.0 => /lib/x86_64-linux-gnu/libwx_gtk3u_aui-3.2.so.0 (0x0000770d49318000)
	libwx_gtk3u_html-3.2.so.0 => /lib/x86_64-linux-gnu/libwx_gtk3u_html-3.2.so.0 (0x0000770d4924b000)
	libwx_gtk3u_core-3.2.so.0 => /lib/x86_64-linux-gnu/libwx_gtk3u_core-3.2.so.0 (0x0000770d46c00000)
	libwx_baseu_net-3.2.so.0 => /lib/x86_64-linux-gnu/libwx_baseu_net-3.2.so.0 (0x0000770d475a9000)
	libwx_baseu-3.2.so.0 => /lib/x86_64-linux-gnu/libwx_baseu-3.2.so.0 (0x0000770d46800000)
	libwx_gtk3u_propgrid-3.2.so.0 => /lib/x86_64-linux-gnu/libwx_gtk3u_propgrid-3.2.so.0 (0x0000770d474a1000)
	libwx_baseu_xml-3.2.so.0 => /lib/x86_64-linux-gnu/libwx_baseu_xml-3.2.so.0 (0x0000770d49235000)
	libwx_gtk3u_stc-3.2.so.0 => /lib/x86_64-linux-gnu/libwx_gtk3u_stc-3.2.so.0 (0x0000770d46622000)
	libpython3.12.so.1.0 => /lib/x86_64-linux-gnu/libpython3.12.so.1.0 (0x0000770d45c00000)
	libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x0000770d47485000)
	libTKBO.so.7 => not found
	libTKBRep.so.7 => not found
	libTKCDF.so.7 => /lib/x86_64-linux-gnu/libTKCDF.so.7 (0x0000770d46bab000)
	libTKernel.so.7 => not found
	libTKG3d.so.7 => not found
	libTKGeomBase.so.7 => not found
	libTKLCAF.so.7 => /lib/x86_64-linux-gnu/libTKLCAF.so.7 (0x0000770d46add000)
	libTKMath.so.7 => not found
	libTKMesh.so.7 => not found
	libTKPrim.so.7 => not found
	libTKRWMesh.so.7 => /lib/x86_64-linux-gnu/libTKRWMesh.so.7 (0x0000770d46a5c000)
	libTKShHealing.so.7 => not found
	libTKTopAlgo.so.7 => not found
	libTKXCAF.so.7 => /lib/x86_64-linux-gnu/libTKXCAF.so.7 (0x0000770d46559000)
	libTKXSBase.so.7 => /lib/x86_64-linux-gnu/libTKXSBase.so.7 (0x0000770d45800000)
	libTKIGES.so.7 => /lib/x86_64-linux-gnu/libTKIGES.so.7 (0x0000770d45400000)
	libTKSTEP.so.7 => /lib/x86_64-linux-gnu/libTKSTEP.so.7 (0x0000770d45000000)
	libTKXDEIGES.so.7 => /lib/x86_64-linux-gnu/libTKXDEIGES.so.7 (0x0000770d4746c000)
	libTKXDESTEP.so.7 => /lib/x86_64-linux-gnu/libTKXDESTEP.so.7 (0x0000770d45b48000)
	libkicad_3dsg.so.2.0.0 => /lib/x86_64-linux-gnu/libkicad_3dsg.so.2.0.0 (0x0000770d4650f000)
	libkigal.so.8.0.4 => /lib/x86_64-linux-gnu/libkigal.so.8.0.4 (0x0000770d44a00000)
	libGLEW.so.2.2 => /lib/x86_64-linux-gnu/libGLEW.so.2.2 (0x0000770d45a8a000)
	libGL.so.1 => /lib/x86_64-linux-gnu/libGL.so.1 (0x0000770d45779000)
	libGLU.so.1 => /lib/x86_64-linux-gnu/libGLU.so.1 (0x0000770d464b6000)
	libkicommon.so.8.0.4 => /lib/x86_64-linux-gnu/libkicommon.so.8.0.4 (0x0000770d44400000)
	libgtk-3.so.0 => /lib/x86_64-linux-gnu/libgtk-3.so.0 (0x0000770d43c00000)
	libgdk-3.so.0 => /lib/x86_64-linux-gnu/libgdk-3.so.0 (0x0000770d44f05000)
	libgobject-2.0.so.0 => /lib/x86_64-linux-gnu/libgobject-2.0.so.0 (0x0000770d4539d000)
	libglib-2.0.so.0 => /lib/x86_64-linux-gnu/libglib-2.0.so.0 (0x0000770d43ab7000)
	libgit2.so.1.7 => /lib/x86_64-linux-gnu/libgit2.so.1.7 (0x0000770d43991000)
	libstdc++.so.6 => /lib/x86_64-linux-gnu/libstdc++.so.6 (0x0000770d43600000)
	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x0000770d438a8000)
	libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x0000770d4743f000)
	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x0000770d43200000)
	/lib64/ld-linux-x86-64.so.2 (0x0000770d493ff000)
	libX11.so.6 => /lib/x86_64-linux-gnu/libX11.so.6 (0x0000770d434c3000)
	libpangocairo-1.0.so.0 => /lib/x86_64-linux-gnu/libpangocairo-1.0.so.0 (0x0000770d46a4b000)
	libpango-1.0.so.0 => /lib/x86_64-linux-gnu/libpango-1.0.so.0 (0x0000770d44e9a000)
	libcairo.so.2 => /lib/x86_64-linux-gnu/libcairo.so.2 (0x0000770d430bc000)
	libgdk_pixbuf-2.0.so.0 => /lib/x86_64-linux-gnu/libgdk_pixbuf-2.0.so.0 (0x0000770d45a5c000)
	libgio-2.0.so.0 => /lib/x86_64-linux-gnu/libgio-2.0.so.0 (0x0000770d42eec000)
	libSM.so.6 => /lib/x86_64-linux-gnu/libSM.so.6 (0x0000770d47435000)
	libxkbcommon.so.0 => /lib/x86_64-linux-gnu/libxkbcommon.so.0 (0x0000770d45354000)
	libnotify.so.4 => /lib/x86_64-linux-gnu/libnotify.so.4 (0x0000770d464a8000)
	libXtst.so.6 => /lib/x86_64-linux-gnu/libXtst.so.6 (0x0000770d45a54000)
	libpangoft2-1.0.so.0 => /lib/x86_64-linux-gnu/libpangoft2-1.0.so.0 (0x0000770d45339000)
	libfontconfig.so.1 => /lib/x86_64-linux-gnu/libfontconfig.so.1 (0x0000770d43472000)
	libpng16.so.16 => /lib/x86_64-linux-gnu/libpng16.so.16 (0x0000770d443c8000)
	libjpeg.so.8 => /lib/x86_64-linux-gnu/libjpeg.so.8 (0x0000770d42e69000)
	libtiff.so.6 => /lib/x86_64-linux-gnu/libtiff.so.6 (0x0000770d42ddc000)
	libcurl.so.4 => /lib/x86_64-linux-gnu/libcurl.so.4 (0x0000770d42d1b000)
	liblzma.so.5 => /lib/x86_64-linux-gnu/liblzma.so.5 (0x0000770d449ce000)
	libpcre2-32.so.0 => /lib/x86_64-linux-gnu/libpcre2-32.so.0 (0x0000770d42c96000)
	libexpat.so.1 => /lib/x86_64-linux-gnu/libexpat.so.1 (0x0000770d44e6f000)
	libTKernel.so.7 => not found
	libTKernel.so.7 => not found
	libTKMesh.so.7 => not found
	libTKService.so.7 => /lib/x86_64-linux-gnu/libTKService.so.7 (0x0000770d42b64000)
	libTKBRep.so.7 => not found
	libTKG3d.so.7 => not found
	libTKMath.so.7 => not found
	libTKernel.so.7 => not found
	libTKVCAF.so.7 => /lib/x86_64-linux-gnu/libTKVCAF.so.7 (0x0000770d43439000)
	libTKV3d.so.7 => /lib/x86_64-linux-gnu/libTKV3d.so.7 (0x0000770d42800000)
	libTKCAF.so.7 => /lib/x86_64-linux-gnu/libTKCAF.so.7 (0x0000770d42ae7000)
	libTKTopAlgo.so.7 => not found
	libTKBRep.so.7 => not found
	libTKG3d.so.7 => not found
	libTKMath.so.7 => not found
	libTKernel.so.7 => not found
	libTKShHealing.so.7 => not found
	libTKTopAlgo.so.7 => not found
	libTKBRep.so.7 => not found
	libTKG3d.so.7 => not found
	libTKG2d.so.7 => not found
	libTKMath.so.7 => not found
	libTKernel.so.7 => not found
	libTKBool.so.7 => not found
	libTKPrim.so.7 => not found
	libTKShHealing.so.7 => not found
	libTKTopAlgo.so.7 => not found
	libTKGeomAlgo.so.7 => not found
	libTKBRep.so.7 => not found
	libTKGeomBase.so.7 => not found
	libTKG3d.so.7 => not found
	libTKG2d.so.7 => not found
	libTKMath.so.7 => not found
	libTKernel.so.7 => not found
	libTKSTEPAttr.so.7 => /lib/x86_64-linux-gnu/libTKSTEPAttr.so.7 (0x0000770d42675000)
	libTKSTEP209.so.7 => /lib/x86_64-linux-gnu/libTKSTEP209.so.7 (0x0000770d425de000)
	libTKSTEPBase.so.7 => /lib/x86_64-linux-gnu/libTKSTEPBase.so.7 (0x0000770d42200000)
	libTKShHealing.so.7 => not found
	libTKTopAlgo.so.7 => not found
	libTKBRep.so.7 => not found
	libTKGeomBase.so.7 => not found
	libTKG3d.so.7 => not found
	libTKG2d.so.7 => not found
	libTKMath.so.7 => not found
	libTKernel.so.7 => not found
	libTKBRep.so.7 => not found
	libTKMath.so.7 => not found
	libTKernel.so.7 => not found
	libTKShHealing.so.7 => not found
	libTKTopAlgo.so.7 => not found
	libTKBRep.so.7 => not found
	libTKG3d.so.7 => not found
	libTKMath.so.7 => not found
	libTKernel.so.7 => not found
	libfreetype.so.6 => /lib/x86_64-linux-gnu/libfreetype.so.6 (0x0000770d42512000)
	libharfbuzz.so.0 => /lib/x86_64-linux-gnu/libharfbuzz.so.0 (0x0000770d420f3000)
	libGLdispatch.so.0 => /lib/x86_64-linux-gnu/libGLdispatch.so.0 (0x0000770d4245a000)
	libGLX.so.0 => /lib/x86_64-linux-gnu/libGLX.so.0 (0x0000770d420c0000)
	libOpenGL.so.0 => /lib/x86_64-linux-gnu/libOpenGL.so.0 (0x0000770d4387d000)
	libgmodule-2.0.so.0 => /lib/x86_64-linux-gnu/libgmodule-2.0.so.0 (0x0000770d45770000)
	libfribidi.so.0 => /lib/x86_64-linux-gnu/libfribidi.so.0 (0x0000770d4341b000)
	libcairo-gobject.so.2 => /lib/x86_64-linux-gnu/libcairo-gobject.so.2 (0x0000770d42adb000)
	libatk-1.0.so.0 => /lib/x86_64-linux-gnu/libatk-1.0.so.0 (0x0000770d42096000)
	libepoxy.so.0 => /lib/x86_64-linux-gnu/libepoxy.so.0 (0x0000770d41f73000)
	libXi.so.6 => /lib/x86_64-linux-gnu/libXi.so.6 (0x0000770d42447000)
	libatk-bridge-2.0.so.0 => /lib/x86_64-linux-gnu/libatk-bridge-2.0.so.0 (0x0000770d41f37000)
	libXfixes.so.3 => /lib/x86_64-linux-gnu/libXfixes.so.3 (0x0000770d45766000)
	libwayland-client.so.0 => /lib/x86_64-linux-gnu/libwayland-client.so.0 (0x0000770d41f27000)
	libwayland-cursor.so.0 => /lib/x86_64-linux-gnu/libwayland-cursor.so.0 (0x0000770d41f1d000)
	libwayland-egl.so.1 => /lib/x86_64-linux-gnu/libwayland-egl.so.1 (0x0000770d43416000)
	libXext.so.6 => /lib/x86_64-linux-gnu/libXext.so.6 (0x0000770d41f09000)
	libXcursor.so.1 => /lib/x86_64-linux-gnu/libXcursor.so.1 (0x0000770d41efd000)
	libXdamage.so.1 => /lib/x86_64-linux-gnu/libXdamage.so.1 (0x0000770d42ad6000)
	libXcomposite.so.1 => /lib/x86_64-linux-gnu/libXcomposite.so.1 (0x0000770d41ef8000)
	libXrandr.so.2 => /lib/x86_64-linux-gnu/libXrandr.so.2 (0x0000770d41eeb000)
	libXinerama.so.1 => /lib/x86_64-linux-gnu/libXinerama.so.1 (0x0000770d41ee6000)
	libffi.so.8 => /lib/x86_64-linux-gnu/libffi.so.8 (0x0000770d41eda000)
	libpcre2-8.so.0 => /lib/x86_64-linux-gnu/libpcre2-8.so.0 (0x0000770d41e40000)
	libgssapi_krb5.so.2 => /lib/x86_64-linux-gnu/libgssapi_krb5.so.2 (0x0000770d41dec000)
	libssl.so.3 => /lib/x86_64-linux-gnu/libssl.so.3 (0x0000770d41d42000)
	libcrypto.so.3 => /lib/x86_64-linux-gnu/libcrypto.so.3 (0x0000770d41800000)
	libhttp_parser.so.2.9 => /lib/x86_64-linux-gnu/libhttp_parser.so.2.9 (0x0000770d41d37000)
	libssh2.so.1 => /lib/x86_64-linux-gnu/libssh2.so.1 (0x0000770d417b8000)
	libxcb.so.1 => /lib/x86_64-linux-gnu/libxcb.so.1 (0x0000770d4178f000)
	libthai.so.0 => /lib/x86_64-linux-gnu/libthai.so.0 (0x0000770d41d2c000)
	libXrender.so.1 => /lib/x86_64-linux-gnu/libXrender.so.1 (0x0000770d41d20000)
	libxcb-render.so.0 => /lib/x86_64-linux-gnu/libxcb-render.so.0 (0x0000770d41780000)
	libxcb-shm.so.0 => /lib/x86_64-linux-gnu/libxcb-shm.so.0 (0x0000770d41d1b000)
	libpixman-1.so.0 => /lib/x86_64-linux-gnu/libpixman-1.so.0 (0x0000770d416d1000)
	libmount.so.1 => /lib/x86_64-linux-gnu/libmount.so.1 (0x0000770d41684000)
	libselinux.so.1 => /lib/x86_64-linux-gnu/libselinux.so.1 (0x0000770d41657000)
	libICE.so.6 => /lib/x86_64-linux-gnu/libICE.so.6 (0x0000770d4163b000)
	libuuid.so.1 => /lib/x86_64-linux-gnu/libuuid.so.1 (0x0000770d41631000)
	libwebp.so.7 => /lib/x86_64-linux-gnu/libwebp.so.7 (0x0000770d415b6000)
	libzstd.so.1 => /lib/x86_64-linux-gnu/libzstd.so.1 (0x0000770d414fc000)
	libLerc.so.4 => /lib/x86_64-linux-gnu/libLerc.so.4 (0x0000770d41475000)
	libjbig.so.0 => /lib/x86_64-linux-gnu/libjbig.so.0 (0x0000770d41465000)
	libdeflate.so.0 => /lib/x86_64-linux-gnu/libdeflate.so.0 (0x0000770d41452000)
	libnghttp2.so.14 => /lib/x86_64-linux-gnu/libnghttp2.so.14 (0x0000770d41427000)
	libidn2.so.0 => /lib/x86_64-linux-gnu/libidn2.so.0 (0x0000770d41405000)
	librtmp.so.1 => /lib/x86_64-linux-gnu/librtmp.so.1 (0x0000770d413e7000)
	libssh.so.4 => /lib/x86_64-linux-gnu/libssh.so.4 (0x0000770d41376000)
	libpsl.so.5 => /lib/x86_64-linux-gnu/libpsl.so.5 (0x0000770d41362000)
	libldap.so.2 => /lib/x86_64-linux-gnu/libldap.so.2 (0x0000770d41305000)
	liblber.so.2 => /lib/x86_64-linux-gnu/liblber.so.2 (0x0000770d412f5000)
	libbrotlidec.so.1 => /lib/x86_64-linux-gnu/libbrotlidec.so.1 (0x0000770d412e7000)
	libTKMath.so.7 => not found
	libfreeimage.so.3 => /lib/x86_64-linux-gnu/libfreeimage.so.3 (0x0000770d4122e000)
	libTKernel.so.7 => not found
	libTKTopAlgo.so.7 => not found
	libTKBRep.so.7 => not found
	libTKGeomBase.so.7 => not found
	libTKG3d.so.7 => not found
	libTKMath.so.7 => not found
	libTKernel.so.7 => not found
	libTKMesh.so.7 => not found
	libTKHLR.so.7 => not found
	libTKTopAlgo.so.7 => not found
	libTKGeomAlgo.so.7 => not found
	libTKBRep.so.7 => not found
	libTKGeomBase.so.7 => not found
	libTKG3d.so.7 => not found
	libTKG2d.so.7 => not found
	libTKMath.so.7 => not found
	libTKernel.so.7 => not found
	libTKBO.so.7 => not found
	libTKTopAlgo.so.7 => not found
	libTKBRep.so.7 => not found
	libTKGeomBase.so.7 => not found
	libTKG3d.so.7 => not found
	libTKMath.so.7 => not found
	libTKernel.so.7 => not found
	libTKernel.so.7 => not found
	libTKernel.so.7 => not found
	libTKernel.so.7 => not found
	libbz2.so.1.0 => /lib/x86_64-linux-gnu/libbz2.so.1.0 (0x0000770d4121a000)
	libgraphite2.so.3 => /lib/x86_64-linux-gnu/libgraphite2.so.3 (0x0000770d411f4000)
	libatspi.so.0 => /lib/x86_64-linux-gnu/libatspi.so.0 (0x0000770d411ba000)
	libdbus-1.so.3 => /lib/x86_64-linux-gnu/libdbus-1.so.3 (0x0000770d4116b000)
	libkrb5.so.3 => /lib/x86_64-linux-gnu/libkrb5.so.3 (0x0000770d410a0000)
	libk5crypto.so.3 => /lib/x86_64-linux-gnu/libk5crypto.so.3 (0x0000770d41074000)
	libcom_err.so.2 => /lib/x86_64-linux-gnu/libcom_err.so.2 (0x0000770d4106e000)
	libkrb5support.so.0 => /lib/x86_64-linux-gnu/libkrb5support.so.0 (0x0000770d41061000)
	libXau.so.6 => /lib/x86_64-linux-gnu/libXau.so.6 (0x0000770d4105b000)
	libXdmcp.so.6 => /lib/x86_64-linux-gnu/libXdmcp.so.6 (0x0000770d41051000)
	libdatrie.so.1 => /lib/x86_64-linux-gnu/libdatrie.so.1 (0x0000770d41048000)
	libblkid.so.1 => /lib/x86_64-linux-gnu/libblkid.so.1 (0x0000770d4100d000)
	libbsd.so.0 => /lib/x86_64-linux-gnu/libbsd.so.0 (0x0000770d40ff7000)
	libsharpyuv.so.0 => /lib/x86_64-linux-gnu/libsharpyuv.so.0 (0x0000770d40fef000)
	libunistring.so.5 => /lib/x86_64-linux-gnu/libunistring.so.5 (0x0000770d40e40000)
	libgnutls.so.30 => /lib/x86_64-linux-gnu/libgnutls.so.30 (0x0000770d40c46000)
	libhogweed.so.6 => /lib/x86_64-linux-gnu/libhogweed.so.6 (0x0000770d40bfe000)
	libnettle.so.8 => /lib/x86_64-linux-gnu/libnettle.so.8 (0x0000770d40ba9000)
	libgmp.so.10 => /lib/x86_64-linux-gnu/libgmp.so.10 (0x0000770d40b25000)
	libsasl2.so.2 => /lib/x86_64-linux-gnu/libsasl2.so.2 (0x0000770d40b09000)
	libbrotlicommon.so.1 => /lib/x86_64-linux-gnu/libbrotlicommon.so.1 (0x0000770d40ae6000)
	libjxrglue.so.0 => /lib/x86_64-linux-gnu/libjxrglue.so.0 (0x0000770d40ac3000)
	libopenjp2.so.7 => /lib/x86_64-linux-gnu/libopenjp2.so.7 (0x0000770d40a62000)
	libraw.so.23 => /lib/x86_64-linux-gnu/libraw.so.23 (0x0000770d40949000)
	libwebpmux.so.3 => /lib/x86_64-linux-gnu/libwebpmux.so.3 (0x0000770d40939000)
	libOpenEXR-3_1.so.30 => /lib/x86_64-linux-gnu/libOpenEXR-3_1.so.30 (0x0000770d40600000)
	libIex-3_1.so.30 => /lib/x86_64-linux-gnu/libIex-3_1.so.30 (0x0000770d4057d000)
	libImath-3_1.so.29 => /lib/x86_64-linux-gnu/libImath-3_1.so.29 (0x0000770d4052f000)
	libsystemd.so.0 => /lib/x86_64-linux-gnu/libsystemd.so.0 (0x0000770d4044f000)
	libkeyutils.so.1 => /lib/x86_64-linux-gnu/libkeyutils.so.1 (0x0000770d40930000)
	libresolv.so.2 => /lib/x86_64-linux-gnu/libresolv.so.2 (0x0000770d4091d000)
	libmd.so.0 => /lib/x86_64-linux-gnu/libmd.so.0 (0x0000770d4090e000)
	libp11-kit.so.0 => /lib/x86_64-linux-gnu/libp11-kit.so.0 (0x0000770d402ab000)
	libtasn1.so.6 => /lib/x86_64-linux-gnu/libtasn1.so.6 (0x0000770d40295000)
	libjpegxr.so.0 => /lib/x86_64-linux-gnu/libjpegxr.so.0 (0x0000770d4025a000)
	liblcms2.so.2 => /lib/x86_64-linux-gnu/liblcms2.so.2 (0x0000770d401f8000)
	libgomp.so.1 => /lib/x86_64-linux-gnu/libgomp.so.1 (0x0000770d401a1000)
	libIlmThread-3_1.so.30 => /lib/x86_64-linux-gnu/libIlmThread-3_1.so.30 (0x0000770d40197000)
	libcap.so.2 => /lib/x86_64-linux-gnu/libcap.so.2 (0x0000770d4018a000)
	libgcrypt.so.20 => /lib/x86_64-linux-gnu/libgcrypt.so.20 (0x0000770d40042000)
	liblz4.so.1 => /lib/x86_64-linux-gnu/liblz4.so.1 (0x0000770d40020000)
	libgpg-error.so.0 => /lib/x86_64-linux-gnu/libgpg-error.so.0 (0x0000770d3fffb000)

In the full package list for 24.04, I see:

libocct-modeling-algorithms-7.6 (= 7.6.3+dfsg1-7.1build1) virtual package provided by libocct-modeling-algorithms-7.6t64
libocct-modeling-algorithms-7.6t64 (7.6.3+dfsg1-7.1build1) [universe] Open CASCADE Technology geometrical & topological algorithms module

…so it would appear that I have the libocct-modeling-algorithms-7.6 virtual package installed, even though no such package is directly offered by 24.04, and that virtual package AFAIK is no longer actually satisfied by any package installed on my machine (e.g. the non-installed t64 package that actually has the .so files in it). Perhaps this was installed under 23.10 and somewhere along the line the chain of dependencies has broken and didn’t trigger an install of the t64 package?

So I’m tempted to install the “real” t64 package, and I’ll do so unless someone tells me to hold off.

I’m confused why I need to and what I can do (if anything) to help resolve the issue for others going forward (e.g. where to report a bug).

Looking at Packages in “PPA for KiCad: 8.0 releases” : PPA for KiCad: 8.0 releases : “KiCad” team (launchpad.net)

you should have version 1:7.6.3+dfsg1-8~ubuntu24.04.1 of libocct-modeling-algorithms-7.6.

Try specifying the version explicitly:

sudo apt install libocct-modeling-algorithms-7.6=1:7.6.3+dfsg1-8~ubuntu24.04.1

Thanks again @dsa-t – I already do have that version (of the virtual package) installed. (Above where I said “In the full package list for 24.04, I see” I meant in the ubuntu repo, not my current system.)

The situation seems to be that kicad depends on libocct-modeling-algorithms-7.6 (>= 1:7.6.3+dfsg1), which is a virtual package which is only provided by the t64 package:

$ aptitude search '?provides(^libocct-modeling-algorithms)'
p   libocct-modeling-algorithms-7.6t64                                                                                             - Open CASCADE Technology geometrical & topological algorithms module

…and for some reason my system has the virtual package installed but not the actual t64 package. This is the confusing part to me – I did an upgrade from 23.10 recently so presumably something shifted and the system failed to satisfy this issue. I’m currently trying to research the best way to remedy. It seems clear that I can install the t64 package and get past it, but there are possibly others in the same state, etc. Trying to figure out the smart way… I’ll report here if I figure it out. :slight_smile:

sudo apt reinstall libocct-modeling-algorithms-7.6 did not fix the issue…

libocct-modeling-algorithms-7.6 shouldn’t be a virtual package.

What does

apt show libocct-modeling-algorithms-7.6

say?


Try:

sudo apt remove libocct-modeling-algorithms-7.6
sudo apt install libocct-modeling-algorithms-7.6=1:7.6.3+dfsg1-8~ubuntu24.04.1

Thanks again! Hmmm… so, above where I show the output of dpkg -L libocct-modeling-algorithms-7.6, you can see that there are no .so files included. However, now when I run that command the .so files are shown. So it would seem that something I did fixed that – I did apt reinstall kicad and apt reinstall libocct-modeling-algorithms-7.6. I didn’t think it changed anything but clearly it did.

Now when I try to open a PCB the error is different, so perhaps we need to shift our attention to another library to debug this.

I said that it was a virtual package because I saw it in the all packages list for ubuntu:

libocct-modeling-algorithms-7.6 (= 7.6.3+dfsg1-7.1build1)
virtual package provided by libocct-modeling-algorithms-7.6t64
libocct-modeling-algorithms-7.6t64 (7.6.3+dfsg1-7.1build1) [universe]
Open CASCADE Technology geometrical & topological algorithms module

…and indeed, before I somehow “fixed” it there were no .so files installed, as you might expect for a virtual package.

At any rate, the same issue is now happening with libocct-modeling-data-7.6 and kicad is complaining about not finding TKBRep.so.7, which is provided by the analogous t64 package. libocct-modeling-data-7.6 is listed in the ubuntu packages list as a virtual package. Here are the files that package installed (note the lack of any .so files):

$ dpkg -L libocct-modeling-data-7.6
/.
/usr
/usr/lib
/usr/lib/x86_64-linux-gnu
/usr/share
/usr/share/doc
/usr/share/doc/libocct-modeling-data-7.6
/usr/share/doc/libocct-modeling-data-7.6/changelog.Debian.gz
/usr/share/doc/libocct-modeling-data-7.6/copyright
/usr/share/lintian
/usr/share/lintian/overrides
/usr/share/lintian/overrides/libocct-modeling-data-7.6
$ apt show libocct-modeling-data-7.6
Package: libocct-modeling-data-7.6
Version: 1:7.6.3+dfsg1-8~ubuntu24.04.1
Priority: optional
Section: libs
Source: opencascade
Maintainer: Debian Science Maintainers <debian-science-maintainers@lists.alioth.debian.org>
Installed-Size: 7,346 kB
Depends: libc6 (>= 2.38), libgcc-s1 (>= 3.3.1), libocct-foundation-7.6 (>= 1:7.6.3+dfsg1), libstdc++6 (>= 13.1)
Breaks: libocct-modeling-data-7.4, libocct-modeling-data-7.5
Replaces: libocct-modeling-data-7.4, libocct-modeling-data-7.5
Download-Size: 2,638 kB
APT-Manual-Installed: no
APT-Sources: https://ppa.launchpadcontent.net/kicad/kicad-8.0-releases/ubuntu noble/main amd64 Packages
Description: Open CASCADE Technology 2D/3D geometric primitives data structures
 Open CASCADE Technology is a suite for 3D surface and solid modeling,
 visualization, data exchange and rapid application development.  It is an
 excellent platform for development of numerical simulation software including
 CAD/CAM/CAE, AEC and GIS, as well as PDM applications.
 .
 This package supplies data structures to represent 2D and 3D geometric models.
 .
 This package contains the following shared libraries:
 TKG2d TKG3d TKGeomBase TKBRep

I’m sure that if I installed the t64 package, or did the reinstall of the package as before, it would “fix” this, but it’d be nice to know what the heck is going on (and to have a more universal fix so I’m not just chasing dependencies…)

Edit to add: aptitude search '?virtual' | grep libocct returns nothing, so it seems like it really isn’t, but I can’t square that with the ubuntu package list calling it virtual, or the lack of installed .so files…

So I tried to get to the bottom of this but my ignorance of the details of packages has made that a losing game. Another person on the Kubuntu forums helped out a bit (here) but there are no conclusions.

Basic summary: my libocct-modeling-data-7.6 is installed from the kicad PPA but does not have any .so files associated with it (see dpkg -L above). I believe that reinstalling it will fix that (because the .deb file for that package from the kicad PPA does have the .so files in it), and I will do that next. (The main Ubuntu list of all 24.04 packages lists its own libocct-modeling-data-7.6 as a virtual package satisfied by the associated *t64 package, but if you search for it, it is not present in 24.04.) It just looks like somewhere along the line there was some kind of packaging or dependency bug, but whatever it is or was seems to be lost to the mists of time, so I will end my quest.

I’ll report back on success/failure.

Try:

sudo apt remove libocct*
sudo apt install kicad
apt show libocct-modeling-data-7.6
dpkg -L libocct-modeling-data-7.6

Thanks, @dsa-t – in theory (however unlikely), if other apps depend on a libocct* package that kicad doesn’t use, that might break them, right?

Would it be smarter to try sudo apt reinstall libocct-modeling-data-7.6 first?

apt will show what else it will remove.

Gotcha.

That worked:

The following packages will be REMOVED:
  kicad libocct-data-exchange-7.6 libocct-draw-7.6 libocct-foundation-7.6 libocct-modeling-algorithms-7.6 libocct-modeling-data-7.6 libocct-ocaf-7.6 libocct-visualization-7.6
$ ldd /usr/bin/_pcbnew.kiface | grep "not found"
$
$ apt show libocct-modeling-data-7.6
Package: libocct-modeling-data-7.6
Version: 1:7.6.3+dfsg1-8~ubuntu24.04.1
Priority: optional
Section: libs
Source: opencascade
Maintainer: Debian Science Maintainers <debian-science-maintainers@lists.alioth.debian.org>
Installed-Size: 7,346 kB
Depends: libc6 (>= 2.38), libgcc-s1 (>= 3.3.1), libocct-foundation-7.6 (>= 1:7.6.3+dfsg1), libstdc++6 (>= 13.1)
Breaks: libocct-modeling-data-7.4, libocct-modeling-data-7.5
Replaces: libocct-modeling-data-7.4, libocct-modeling-data-7.5
Download-Size: 2,638 kB
APT-Manual-Installed: no
APT-Sources: https://ppa.launchpadcontent.net/kicad/kicad-8.0-releases/ubuntu noble/main amd64 Packages
Description: Open CASCADE Technology 2D/3D geometric primitives data structures
 Open CASCADE Technology is a suite for 3D surface and solid modeling,
 visualization, data exchange and rapid application development.  It is an
 excellent platform for development of numerical simulation software including
 CAD/CAM/CAE, AEC and GIS, as well as PDM applications.
 .
 This package supplies data structures to represent 2D and 3D geometric models.
 .
 This package contains the following shared libraries:
 TKG2d TKG3d TKGeomBase TKBRep

…and the dpkg -L now shows the .so files as being installed (and kicad works normally):

$ dpkg -L libocct-modeling-data-7.6
/.
/usr
/usr/lib
/usr/lib/x86_64-linux-gnu
/usr/lib/x86_64-linux-gnu/libTKBRep.so.7.6.3
/usr/lib/x86_64-linux-gnu/libTKG2d.so.7.6.3
/usr/lib/x86_64-linux-gnu/libTKG3d.so.7.6.3
/usr/lib/x86_64-linux-gnu/libTKGeomBase.so.7.6.3
/usr/share
/usr/share/doc
/usr/share/doc/libocct-modeling-data-7.6
/usr/share/doc/libocct-modeling-data-7.6/changelog.Debian.gz
/usr/share/doc/libocct-modeling-data-7.6/copyright
/usr/share/lintian
/usr/share/lintian/overrides
/usr/share/lintian/overrides/libocct-modeling-data-7.6
/usr/lib/x86_64-linux-gnu/libTKBRep.so.7
/usr/lib/x86_64-linux-gnu/libTKG2d.so.7
/usr/lib/x86_64-linux-gnu/libTKG3d.so.7
/usr/lib/x86_64-linux-gnu/libTKGeomBase.so.7

I’ll modify the first post to reflect the fix. Thanks for the help.

1 Like

Oops we want quotes around the expansion, yeah? I’ll modify my first post.

sudo apt remove "libocct*"

If you don’t have any files starting with libocct in the current directory, it doesn’t matter.

When this happened to me today, I did…

sudo apt-get update
sudo apt-get install -y libocct-modeling-algorithms-7.6t64

I’m not sure how the package dependency got broken, but I found this:

https://packages.ubuntu.com/search?searchon=contents&keywords=libTKBO.so.7&mode=exactfilename&suite=noble&arch=any

So, found the file I needed.

1 Like