I’ve been fighting with setting up the Windows build environment until today. Now I’m fighting with the same on Ubuntu!
On the plus side, it’s gone way more smoothly until the very last step - actually running KiCad…
When I try to run with kicad at the prompt, I get: kicad: error while loading shared libraries: libkigal.so.8.99.0: cannot open shared object file: no such file or directory
/usr/local/bin/kicad has the same result.
If I run kicad from kicad/build/release/kicad, it runs but the components of the software can’t be invoked.
I did previously have KiCad 7.0.something installed via apt-get… but I apt-get removed it. Could some leftover from this be interfering? How would I cleanup such interference?
Thanks for the lightning fast answer : D But it doesn’t seem to have helped.
I gather I should set the env variable in the terminal like so: $ KICAD_RUN_FROM_BUILD_DIR=1
thereafter $ echo $KICAD_RUN_FROM_BUILD_DIR shows it is set to 1.
However (continuing in the same terminal), $ kicad
still throws the shared object error.
$ kicad/build/release/kicad/kicad
executes, but still cannot launch the individual components of KiCad
and if I sudo make uninstall (which I thought I’d try in case the installed binaries were being called when they shouldn’t be) I’m in a worse situation!
That is because you presumably have a regular installation of kicad that you didn’t build from source, and your shell is preferring that from your PATH when you don’t give it an explicit relative path to run.
Ok - so shared libraries are placed in /usr/local/lib when running $ make install.
This is the wrong way to do it! Correct way is $ sudo ldconfig For Ubuntu to find these, I need to modify /etc/environment so… $ sudo nano /etc/environment
Under PATH, add the line LD_LIBRARY_PATH=“/usr/local/lib”
Ctrl+X, and save
reboot
and yaay : D
And I’ve just spotted your post, which probably would have solved my problem the easy way lol
ldconfig rings a bell… I’ve definitely used it before when I was doing a lot of development in Ubuntu for a project many years ago…
Just to say - I didn’t have a leftover installation - I only had the version I compiled myself (that I had run $ make install on after compiling. But without ldconfig it couldn’t find the shared objects. Also, thanks for your massive help - I feel like I’ve learned enough to be ever so slightly less dangerous!