Problem upgrading v6 to self-compiled v7 on Ubuntu 22.04

I have a similar error while opening a Kicad-6 project after I upgraded Kicad to the latest v7:

07:48:12: Failed to load shared library '/usr/bin/_eeschema.kiface': /usr/bin/_eeschema.kiface: undefined symbol: _ZNK13wxGLCanvasX1115IsShownOnScreenEv, version WXU_3.2
07:48:12: Failed to load kiface library '/usr/bin/_eeschema.kiface'.
07:48:12: Error loading editor.
07:48:12: Application failed to load.

The problem is that I have built the latest wxWidgets (v3.2.2.1) from sources - I need that library for other projects installed on my PC, Ubuntu 22.04 LTS. Is it possible to use Kicad with newer versions of wxWidgets lib? Or I should remove it as suggested elsewhere in this discussion and stick only to the one shipped with Kicad 7?

$ ldd /usr/bin/_eeschema.kiface | grep wx
	libwx_gtk3u_gl-3.2.so.0 => /usr/local/lib/libwx_gtk3u_gl-3.2.so.0 (0x00007f552ef44000)
	libwx_gtk3u_aui-3.2.so.0 => /usr/local/lib/libwx_gtk3u_aui-3.2.so.0 (0x00007f552d556000)
	libwx_gtk3u_html-3.2.so.0 => /usr/local/lib/libwx_gtk3u_html-3.2.so.0 (0x00007f552d475000)
	libwx_gtk3u_core-3.2.so.0 => /usr/local/lib/libwx_gtk3u_core-3.2.so.0 (0x00007f552ca00000)
	libwx_baseu_net-3.2.so.0 => /usr/local/lib/libwx_baseu_net-3.2.so.0 (0x00007f552eedc000)
	libwx_baseu-3.2.so.0 => /usr/local/lib/libwx_baseu-3.2.so.0 (0x00007f552c600000)
	libwx_gtk3u_propgrid-3.2.so.0 => /usr/local/lib/libwx_gtk3u_propgrid-3.2.so.0 (0x00007f552d35e000)
	libwx_baseu_xml-3.2.so.0 => /usr/local/lib/libwx_baseu_xml-3.2.so.0 (0x00007f552d349000)
	libwx_gtk3u_stc-3.2.so.0 => /usr/local/lib/libwx_gtk3u_stc-3.2.so.0 (0x00007f552c200000)

I’ve moved your question to a new thread. Please do not append to that old thread, particularly as it was marked [Solved] and was for Ubuntu 22.10, not 22.04 LTS which is what you have, as you are less likely to get your question noticed. Forum threads are not in short supply despite supply chain issues.

1 Like

It is but you should compile kicad against it. Also if you want plugins to work, compile wxpython against it (matching version), before you compile kicad.

Alternatively use flatpack version of kicad.

1 Like

Does flatpak add command line tools to launch Kicad and it’s friends from the command line as default?

I don’t think so, can’t say for sure, don’t use it myself.

4 posts were split to a new topic: About linux software packaging philosophy

You’ve hit one problem of shared libraries. If you install a newer version of the library, you affect all the applications that depend on it. That’s why distros are conservative and don’t touch the library versions that were current when the particular distro version was released. Or at least update to only ABI compatible versions. It’s the reason why people discover that distro versions are “stuck” at older versions of apps, and the reason why KiCad had to provide its own versions of wx libraries. Now the shoe is on the other foot in your case.

So if you update the shared library you have to recompile KiCad. It might also be possible to use some LD_LIBRARY_PATH magic to make KiCad only load its version of the shared libraries, but that’s a hairy endeavour with no guarantee of success.

1 Like

All right, compiling Kicad and wxPython will be too much for me.

Do you use a custom/modified version of wxWidgets in Kicad? Can I add a PPA repo with the wxWidgets used in Kicad to my package manager? I don’t want to add “ppa:kicad/kicad-7.0-releases” to other projects because it’s too specific to Kicad. For example, if you pull ligwxgtk from some general repository, I can use this one as the root for my other projects (I’m trying to cut down extra work of setting up each and every libwxgtk version per project - some more or less version of wxwidgets should work for all projects I’m using including Kicad).

Also, I cannot mark any of your replies as the answer.

Don’t worry, this forum is not like one of those *stack sites where people nominate or vote for answers.

I can’t say for certain that kicad uses unmodified version of wxwidgets on linux, I know at least on mac it compiles the lib with some bugfixes. On windows it doesn’t (uses vcpkg provided lib directly). But if there are modification you can be fairly certain that they are bugfixes in wxwidgets itself and 99.9% will not break compatibility.

But more importantly, I doubt whatever else version of wxwidgets your other software needs requires specific patch level match. Kicad uses pretty much the latest wxwidgets there is, 3.2.x so most likely your other software will also just work.

Actually, it’s slightly slightly modified

I pulled wxwidgets into our registry because I got sick of dealing with the vcpkg upstream wanting me to make things work on every platform under the sun when I made a patch

I would try to see if you can use the wxWidgets 3.2.1 that come from the KiCad PPA with your other projects. It could be that you don’t need to build wxWidgets 3.2.2.1.

I’m seeing the exact error again although I’ve removed my custom wxWidgets lib from the system completely. Was there a recent update on kicad 7 that is broken ob ubuntu 22.04?

Tried kicad-nightly. Same story.

Application: KiCad x86_64 on x86_64

Version: 7.99.0-unknown-af71308184~172~ubuntu22.04.1, release build

Libraries:
	wxWidgets 3.2.2
	FreeType 2.11.1
	HarfBuzz 2.7.4
	FontConfig 2.13.1
	libcurl/7.81.0 OpenSSL/3.0.2 zlib/1.2.11 brotli/1.0.9 zstd/1.4.8 libidn2/2.3.2 libpsl/0.21.0 (+libidn2/2.3.2) libssh/0.9.6/openssl/zlib nghttp2/1.43.0 librtmp/2.3 OpenLDAP/2.5.14

Platform: Ubuntu 22.04.2 LTS, 64 bit, Little endian, wxGTK, ubuntu, x11

Build Info:
	Date: Jun 27 2023 16:03:33
	wxWidgets: 3.2.1 (wchar_t,wx containers) GTK+ 3.24
	Boost: 1.74.0
	OCC: 7.5.2
	Curl: 7.81.0
	ngspice: 40
	Compiler: GCC 11.3.0 with C++ ABI 1016

Build settings:
17:46:46: Failed to load shared library '/usr/lib/kicad-nightly/bin/_eeschema.kiface': /usr/lib/kicad-nightly/bin/_eeschema.kiface: undefined symbol: _ZNK13wxGLCanvasX1115IsShownOnScreenEv, version WXU_3.2
17:46:46: Failed to load kiface library '/usr/lib/kicad-nightly/bin/_eeschema.kiface'.
17:46:46: Error loading editor.
17:46:46: Application cannot start.

Dear diizcza,
I had in the past several troubles with KICAD and wx-widgets.
For your current problem you may try “ldd /usr/lib/kicad-nightly/bin/kicad”, which gives you a list of the selected libraries. I noticed in the past that there may be some different locations for the wx libs, especially when they are build by yourself. Maybe this can give some progress…

$ ldd /usr/lib/kicad-nightly/bin/kicad
	linux-vdso.so.1 (0x00007ffc14b6b000)
	libwx_gtk3u_aui-3.2.so.0 => /usr/local/lib/libwx_gtk3u_aui-3.2.so.0 (0x00007eff5487d000)
	libwx_gtk3u_html-3.2.so.0 => /usr/local/lib/libwx_gtk3u_html-3.2.so.0 (0x00007eff5431f000)
	libwx_gtk3u_core-3.2.so.0 => /usr/local/lib/libwx_gtk3u_core-3.2.so.0 (0x00007eff53a00000)
	libwx_baseu_net-3.2.so.0 => /usr/local/lib/libwx_baseu_net-3.2.so.0 (0x00007eff53998000)
	libwx_baseu-3.2.so.0 => /usr/local/lib/libwx_baseu-3.2.so.0 (0x00007eff53600000)
	libwx_gtk3u_propgrid-3.2.so.0 => /usr/local/lib/libwx_gtk3u_propgrid-3.2.so.0 (0x00007eff534eb000)
	libwx_baseu_xml-3.2.so.0 => /usr/local/lib/libwx_baseu_xml-3.2.so.0 (0x00007eff5430a000)
	libwx_gtk3u_stc-3.2.so.0 => /usr/local/lib/libwx_gtk3u_stc-3.2.so.0 (0x00007eff53200000)
	libgtk-3.so.0 => /lib/x86_64-linux-gnu/libgtk-3.so.0 (0x00007eff52800000)
	libgdk-3.so.0 => /lib/x86_64-linux-gnu/libgdk-3.so.0 (0x00007eff530f9000)
	libharfbuzz.so.0 => /lib/x86_64-linux-gnu/libharfbuzz.so.0 (0x00007eff538c9000)
	libgio-2.0.so.0 => /lib/x86_64-linux-gnu/libgio-2.0.so.0 (0x00007eff52627000)
	libgobject-2.0.so.0 => /lib/x86_64-linux-gnu/libgobject-2.0.so.0 (0x00007eff5348b000)
	libglib-2.0.so.0 => /lib/x86_64-linux-gnu/libglib-2.0.so.0 (0x00007eff524ed000)
	libcurl.so.4 => /lib/x86_64-linux-gnu/libcurl.so.4 (0x00007eff53052000)
	libfreetype.so.6 => /lib/x86_64-linux-gnu/libfreetype.so.6 (0x00007eff52425000)
	libfontconfig.so.1 => /lib/x86_64-linux-gnu/libfontconfig.so.1 (0x00007eff523db000)
	libpython3.10.so.1.0 => /lib/x86_64-linux-gnu/libpython3.10.so.1.0 (0x00007eff51e00000)
	libstdc++.so.6 => /lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007eff51a00000)
	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007eff51d19000)
	libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007eff542ea000)
	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007eff51600000)
	libpangocairo-1.0.so.0 => /lib/x86_64-linux-gnu/libpangocairo-1.0.so.0 (0x00007eff542d8000)
	libpango-1.0.so.0 => /lib/x86_64-linux-gnu/libpango-1.0.so.0 (0x00007eff51cb2000)
	libcairo.so.2 => /lib/x86_64-linux-gnu/libcairo.so.2 (0x00007eff518d8000)
	libgdk_pixbuf-2.0.so.0 => /lib/x86_64-linux-gnu/libgdk_pixbuf-2.0.so.0 (0x00007eff51c82000)
	libX11.so.6 => /lib/x86_64-linux-gnu/libX11.so.6 (0x00007eff514c0000)
	libXxf86vm.so.1 => /lib/x86_64-linux-gnu/libXxf86vm.so.1 (0x00007eff5486e000)
	libSM.so.6 => /lib/x86_64-linux-gnu/libSM.so.6 (0x00007eff542cd000)
	libXtst.so.6 => /lib/x86_64-linux-gnu/libXtst.so.6 (0x00007eff5304a000)
	libpangoft2-1.0.so.0 => /lib/x86_64-linux-gnu/libpangoft2-1.0.so.0 (0x00007eff5302f000)
	libpng16.so.16 => /lib/x86_64-linux-gnu/libpng16.so.16 (0x00007eff51c47000)
	libjpeg.so.8 => /lib/x86_64-linux-gnu/libjpeg.so.8 (0x00007eff51857000)
	libtiff.so.5 => /lib/x86_64-linux-gnu/libtiff.so.5 (0x00007eff5143a000)
	libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007eff51c2b000)
	libpcre2-32.so.0 => /lib/x86_64-linux-gnu/libpcre2-32.so.0 (0x00007eff513b5000)
	libexpat.so.1 => /lib/x86_64-linux-gnu/libexpat.so.1 (0x00007eff51384000)
	libgmodule-2.0.so.0 => /lib/x86_64-linux-gnu/libgmodule-2.0.so.0 (0x00007eff53484000)
	libXi.so.6 => /lib/x86_64-linux-gnu/libXi.so.6 (0x00007eff51843000)
	libXfixes.so.3 => /lib/x86_64-linux-gnu/libXfixes.so.3 (0x00007eff5183b000)
	libcairo-gobject.so.2 => /lib/x86_64-linux-gnu/libcairo-gobject.so.2 (0x00007eff5182f000)
	libatk-1.0.so.0 => /lib/x86_64-linux-gnu/libatk-1.0.so.0 (0x00007eff5135a000)
	libatk-bridge-2.0.so.0 => /lib/x86_64-linux-gnu/libatk-bridge-2.0.so.0 (0x00007eff51322000)
	libepoxy.so.0 => /lib/x86_64-linux-gnu/libepoxy.so.0 (0x00007eff511ed000)
	libfribidi.so.0 => /lib/x86_64-linux-gnu/libfribidi.so.0 (0x00007eff511d1000)
	libXinerama.so.1 => /lib/x86_64-linux-gnu/libXinerama.so.1 (0x00007eff5182a000)
	libXrandr.so.2 => /lib/x86_64-linux-gnu/libXrandr.so.2 (0x00007eff511c4000)
	libXcursor.so.1 => /lib/x86_64-linux-gnu/libXcursor.so.1 (0x00007eff511b8000)
	libXcomposite.so.1 => /lib/x86_64-linux-gnu/libXcomposite.so.1 (0x00007eff511b3000)
	libXdamage.so.1 => /lib/x86_64-linux-gnu/libXdamage.so.1 (0x00007eff511ae000)
	libxkbcommon.so.0 => /lib/x86_64-linux-gnu/libxkbcommon.so.0 (0x00007eff51167000)
	libwayland-cursor.so.0 => /lib/x86_64-linux-gnu/libwayland-cursor.so.0 (0x00007eff5115d000)
	libwayland-egl.so.1 => /lib/x86_64-linux-gnu/libwayland-egl.so.1 (0x00007eff51158000)
	libwayland-client.so.0 => /lib/x86_64-linux-gnu/libwayland-client.so.0 (0x00007eff51147000)
	libXext.so.6 => /lib/x86_64-linux-gnu/libXext.so.6 (0x00007eff51132000)
	libgraphite2.so.3 => /lib/x86_64-linux-gnu/libgraphite2.so.3 (0x00007eff5110b000)
	libmount.so.1 => /lib/x86_64-linux-gnu/libmount.so.1 (0x00007eff510c7000)
	libselinux.so.1 => /lib/x86_64-linux-gnu/libselinux.so.1 (0x00007eff5109b000)
	libffi.so.8 => /lib/x86_64-linux-gnu/libffi.so.8 (0x00007eff5108e000)
	libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.3 (0x00007eff51018000)
	libnghttp2.so.14 => /lib/x86_64-linux-gnu/libnghttp2.so.14 (0x00007eff50fee000)
	libidn2.so.0 => /lib/x86_64-linux-gnu/libidn2.so.0 (0x00007eff50fcd000)
	librtmp.so.1 => /lib/x86_64-linux-gnu/librtmp.so.1 (0x00007eff50fae000)
	libssh.so.4 => /lib/x86_64-linux-gnu/libssh.so.4 (0x00007eff50f41000)
	libpsl.so.5 => /lib/x86_64-linux-gnu/libpsl.so.5 (0x00007eff50f2d000)
	libssl.so.3 => /lib/x86_64-linux-gnu/libssl.so.3 (0x00007eff50e89000)
	libcrypto.so.3 => /lib/x86_64-linux-gnu/libcrypto.so.3 (0x00007eff50a00000)
	libgssapi_krb5.so.2 => /lib/x86_64-linux-gnu/libgssapi_krb5.so.2 (0x00007eff509ac000)
	libldap-2.5.so.0 => /lib/x86_64-linux-gnu/libldap-2.5.so.0 (0x00007eff5094d000)
	liblber-2.5.so.0 => /lib/x86_64-linux-gnu/liblber-2.5.so.0 (0x00007eff50e76000)
	libzstd.so.1 => /lib/x86_64-linux-gnu/libzstd.so.1 (0x00007eff5087e000)
	libbrotlidec.so.1 => /lib/x86_64-linux-gnu/libbrotlidec.so.1 (0x00007eff50e68000)
	libuuid.so.1 => /lib/x86_64-linux-gnu/libuuid.so.1 (0x00007eff50e5f000)
	/lib64/ld-linux-x86-64.so.2 (0x00007eff5494f000)
	libthai.so.0 => /lib/x86_64-linux-gnu/libthai.so.0 (0x00007eff50e52000)
	libpixman-1.so.0 => /lib/x86_64-linux-gnu/libpixman-1.so.0 (0x00007eff507d3000)
	libxcb-shm.so.0 => /lib/x86_64-linux-gnu/libxcb-shm.so.0 (0x00007eff50e4d000)
	libxcb.so.1 => /lib/x86_64-linux-gnu/libxcb.so.1 (0x00007eff507a9000)
	libxcb-render.so.0 => /lib/x86_64-linux-gnu/libxcb-render.so.0 (0x00007eff5079a000)
	libXrender.so.1 => /lib/x86_64-linux-gnu/libXrender.so.1 (0x00007eff5078d000)
	libICE.so.6 => /lib/x86_64-linux-gnu/libICE.so.6 (0x00007eff50770000)
	libwebp.so.7 => /lib/x86_64-linux-gnu/libwebp.so.7 (0x00007eff50704000)
	liblzma.so.5 => /lib/x86_64-linux-gnu/liblzma.so.5 (0x00007eff506d9000)
	libjbig.so.0 => /lib/x86_64-linux-gnu/libjbig.so.0 (0x00007eff506c8000)
	libdeflate.so.0 => /lib/x86_64-linux-gnu/libdeflate.so.0 (0x00007eff506a4000)
	libdbus-1.so.3 => /lib/x86_64-linux-gnu/libdbus-1.so.3 (0x00007eff50656000)
	libatspi.so.0 => /lib/x86_64-linux-gnu/libatspi.so.0 (0x00007eff5061c000)
	libblkid.so.1 => /lib/x86_64-linux-gnu/libblkid.so.1 (0x00007eff505e5000)
	libpcre2-8.so.0 => /lib/x86_64-linux-gnu/libpcre2-8.so.0 (0x00007eff5054e000)
	libunistring.so.2 => /lib/x86_64-linux-gnu/libunistring.so.2 (0x00007eff503a4000)
	libgnutls.so.30 => /lib/x86_64-linux-gnu/libgnutls.so.30 (0x00007eff501b9000)
	libhogweed.so.6 => /lib/x86_64-linux-gnu/libhogweed.so.6 (0x00007eff50171000)
	libnettle.so.8 => /lib/x86_64-linux-gnu/libnettle.so.8 (0x00007eff5012b000)
	libgmp.so.10 => /lib/x86_64-linux-gnu/libgmp.so.10 (0x00007eff500a9000)
	libkrb5.so.3 => /lib/x86_64-linux-gnu/libkrb5.so.3 (0x00007eff4ffde000)
	libk5crypto.so.3 => /lib/x86_64-linux-gnu/libk5crypto.so.3 (0x00007eff4ffaf000)
	libcom_err.so.2 => /lib/x86_64-linux-gnu/libcom_err.so.2 (0x00007eff4ffa9000)
	libkrb5support.so.0 => /lib/x86_64-linux-gnu/libkrb5support.so.0 (0x00007eff4ff9b000)
	libsasl2.so.2 => /lib/x86_64-linux-gnu/libsasl2.so.2 (0x00007eff4ff80000)
	libbrotlicommon.so.1 => /lib/x86_64-linux-gnu/libbrotlicommon.so.1 (0x00007eff4ff5d000)
	libdatrie.so.1 => /lib/x86_64-linux-gnu/libdatrie.so.1 (0x00007eff4ff54000)
	libXau.so.6 => /lib/x86_64-linux-gnu/libXau.so.6 (0x00007eff4ff4e000)
	libXdmcp.so.6 => /lib/x86_64-linux-gnu/libXdmcp.so.6 (0x00007eff4ff46000)
	libbsd.so.0 => /lib/x86_64-linux-gnu/libbsd.so.0 (0x00007eff4ff2e000)
	libsystemd.so.0 => /lib/x86_64-linux-gnu/libsystemd.so.0 (0x00007eff4fe67000)
	libp11-kit.so.0 => /lib/x86_64-linux-gnu/libp11-kit.so.0 (0x00007eff4fd2a000)
	libtasn1.so.6 => /lib/x86_64-linux-gnu/libtasn1.so.6 (0x00007eff4fd12000)
	libkeyutils.so.1 => /lib/x86_64-linux-gnu/libkeyutils.so.1 (0x00007eff4fd0b000)
	libresolv.so.2 => /lib/x86_64-linux-gnu/libresolv.so.2 (0x00007eff4fcf7000)
	libmd.so.0 => /lib/x86_64-linux-gnu/libmd.so.0 (0x00007eff4fcea000)
	liblz4.so.1 => /lib/x86_64-linux-gnu/liblz4.so.1 (0x00007eff4fcc8000)
	libcap.so.2 => /lib/x86_64-linux-gnu/libcap.so.2 (0x00007eff4fcbd000)
	libgcrypt.so.20 => /lib/x86_64-linux-gnu/libgcrypt.so.20 (0x00007eff4fb7f000)
	libgpg-error.so.0 => /lib/x86_64-linux-gnu/libgpg-error.so.0 (0x00007eff4fb59000)

OK. So you can see, the program tries to load the WX libraries from /usr/local/lib. So two questions:

  1. Are you shure, that you completely deleted your custom wxWidget files? May it be possible that in this folder there are still residues from these files?
  2. The wxWidgets from the Ubuntu-Repositories are typically installed in a tree /lib/x86_64-linux-gnu/libwx_gtk3u_html… like most of the other libraries neccessary for KICAD. Would you please check if these libraries exists? In case of “yes”, I would suggest to make the files in the local lib temporarily inaccessible to check against the shipped libraries from the repositories.

if this doesn’t help, you may load the version 3.2.1 of wxWidgets from the repositories. You may have noticed, that the nightly build is generated using wx 3.2.1, while your libraries are claimed 3.2.2. This is only a small difference, but for my personal experience enough difference to fail…

@HOH you’re right. I thought that I’d removed custom wxWidgets while I didn’t.
After I uninstalled custom wxwidgets, Kicad launched without a problem.
Thanks.!

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