Kicad souce build wont open eeschema / pcbnew from the right directory from project manager:

I build kicad from source using the following:

sudo cmake -DKICAD_USE_CMAKE_FINDPROTOBUF=ON ../../

sudo make
sudo make install

sudo ldconfig

and when running kicad from:
'/usr/local/kicad/build/release/kicad/kicad`
and trying to open an eeschema file i get the following:

Failed to load shared library '/usr/local/kicad/build/release/kicad/_eeschema.kiface': /usr/local/kicad/build/release/kicad/_eeschema.kiface: cannot open shared object file: No such file or directory

but _eeschema.kiface is located in: “/usr/local/kicad/build/release/eeschema/_eeschema.kiface”
thus it is looking for it in the wrong directory same story with pcbnew,
but i am able to open eechema with bash command:
/usr/local/kicad/build/release/eeschema/eeschema
so individually this was built correctly.

Any idea how to rectify that?

You are trying to start from the build directory, while on linux it’s installed under /usr/local/ by default.

Set the KICAD_RUN_FROM_BUILD_DIR env var if you want to test it without installing

Since you ran make install you should run the installed copy as eelik says.

1 Like

Adding export KICAD_RUN_FROM_BUILD_DIR to “~/.bashrc” fixed the problem thanks!
Unfortunately it’s hard to comeby from google even with the term KICAD_RUN_FROM_BUILD_DIR.
Luckily there are great good guys on the forum :smiley:

If you insist running from the build dir, you don’t have to use make install. Just plain make is enough and saves some seconds and some megabytes of hard disk. :slight_smile:

But installing is simple on *nix, running from build folder is more useful on Windows.

1 Like

I guess I would like to run it from the home dir or what ever is the default directory for running kicad in linux.
but since I know is creates the executeable in ‘/usr/local/kicad/build/release/kicad/kicad’
I just run it with
/usr/local/kicad/build/release/kicad/kicad
am I doing anything out of the ordinary?

By default it should install to /usr/local/, which means it that the main binaries go to /usr/local/bin/, the libraries /usr/local/lib/, etc. The Windows installation replicates more or less the same hierarchy:

Replace “9.0” in that screenshot with “/usr/local” and you see the similar hierarchy. Having “build” in the installation hierarchy tells it’s not the default installation.

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