Choosing Linux flavour for Kicad builds

Hello, everybody,

This question is for people who install (and preferably build from sources) their Kicad installations.
What Linux distribution is the most easy to install Kicad to? I am looking for a distro where Kicad can be easily built from sources (so the most up to date version is easy to obtain).
I am moderately fluent with Linux used as server software (mainly Enterprise Red Hat and its Oracle counterparts), but don’t know much about modern “user-friendly” distros.

I installed Ubuntu 14.04 on a virtual machine on my Mac (VMware) and it works great. The build was awkward at first, only because I didn’t have user permissions correct. I tried a second time using sudo (to insure I could install everything) and the build worked then. It wasn’t much more than following the directions on the KiCad site. However, it was not a user friendly process.

Ubuntu is Debian based and according to those instructions it should build on any derivative system. However, during the first round of Contextual Electronics many people had problems building on Mint (not sure if that was fixed).

Thank you for the info! Is your Ubuntu 32 or 64 bits?

I’ve built on both 64-bit Ubuntu 14.04 and 64-bit Debian 7.6 with little to no trouble. I wouldn’t expect 32-bit to cause a problem, either. KiCad doesn’t really have any exotic dependencies.

I’ll try Ubuntu then!

Well, just finished the build of bzr5113 on vanilla 64-bit Lubuntu (lightweight distribution based on lxde window manager). Installed in Oracle Virtualbox (on W7 host), almost everything went smoothly, I am rather surprised by how easy it was!
I just downloaded the automatic install shell and ran it. No manual actions were needed whatsoever.

Lessons learned:
1 (unrelated to kicad): install the latest version of virtualbox, without it (I had 2012 version) the vmbox guest additions won’t install on latest ubuntu distros. And working with vmbox without guest additions is painful: no easily shared folders, no screen resize on the fly, no shared clipboard,…

2: don’t attempt to build the kicad on a VM with 1024 Megs of RAM: the build will eat up all the memory and hang the vm. With 2 Gigs of ram the process went without hiccups. I reduced the memory back to 1 Gig later, it is enough to run Kicad on lubuntu apparently.

3: I had to add the following lines into /etc/profile.d/kicad.sh

export KIGITHUB=https://github.com/KiCad
export KISYSMOD=/usr/local/share/kicad/modules
export KISYS3DMOD=/usr/local/share/kicad/modules/packages3d

these make Kicad able to find component modules located locally or on github, and 3d models.

  1. lxde intercepts F11 (it toggles fullscreen mode), I’l have to figure out how to free this for Kicad (it’s supposed to toggle Open GL canvas mode in pcbnew)
1 Like

Here you are, F11 interception problem is solved: http://forum.lxde.org/viewtopic.php?f=8&t=1508

Thanks for that detailed post. I’ve been running KiCAD natively on Kubuntu mostly for the last few years, but I’d missed the introduction of that KISYS3DMOD environment variable, so I was sad to see the 3D renders didn’t have my extensive model collection any more and assumed it was a bug with my build. With that post I’ve got the models back again!

On the subject of VMs though, a colleague noticed that the default disk size (8GB?) for a Kubuntu guest OS running in VirtualBox isn’t sufficient for a full graphical install of 14.04 and tends to cause it to crash with an un-descriptive error. Something more like 20-30GB is probably needed.

I am glad to help! :slight_smile:

I typically run my VMs with disk auto-extention feature set so the virtual disks grow with the data. My lubuntu disk is 9 GB now after the build.

Man, I didn’t know about this either! I was all happy to show people about the fancy new 3D renders and then nothing showed up on top of the board. Thanks @Dolganoff!

I don’t even remember where did I find out about this variable! From yahoo kicad mail list maybe, not sure.

I have had little problem building on Mint (both LMDE and Mint Xfce). The build script didn’t work, so I used the step-by-step instructions, with the following exceptions:

  • I used apt-get to manually install each dependency, because sudo apt-get build-dep kicad didn’t work (not sure why). I couldn’t find the dependency list anywhere, so basically went through a couple cmake configuration cycles to get them all.
  • Creating the /etc/profile.d/kicad.sh file mentioned above was essential (remember to logoff/on to enable).
  • used cmake-gui .. instead of the given cmake step, since I wanted to enable python scripting.
  • eventually disabled the internal boost build, since mint’s latest boost package (1.54) works just fine. This shaves a lot of time off of the build.

I was half-expecting same kind of trouble, but Lubuntu was very kind to me, nothing of the sorts happened :slight_smile:

“apt-get build-dep” works based on the apt packaged version of KiCad. There is a version of KiCad available to just “apt-get install” but it is usually pretty old. When you ask apt to calculate the build dependencies it looks at the source package for the version of KiCad in the repository. There have been a lot of new and changed dependencies in the last year with improved graphics rendering and python scripting being added, which is why the dependencies of the old version in the Mint repository and the current source build do not match up.

It’s something else:

hum work # apt-get build-dep kicad
Reading package lists… Done
Building dependency tree
Reading state information… Done
E: You must put some ‘source’ URIs in your sources.list

Apparently Mint uses some other way to track apt sources, and that breaks this command. Both of my Mint machines have an empty /etc/apt/sources.list. [Edit] apt sources are stored in /etc/apt/sources.list.d as separate files. I’m guessing build-dep failure is a apt bug. In any case, an explicit list of dependencies would be preferable and less brittle since they will change occasionally.

The Arch Linux User Repository (AUR) has a nice kicad-bzr Package that builds the latest BZR version automatically. I found this to be an easy way to stay on a current build version.

https://aur.archlinux.org/packages/kicad-bzr/

https://www.archlinux.org/

Just a follow-up:
since my first post, I tried three different ubuntu distros: the “full” with Unity desktop and two lighter versions (Xubuntu and Lubuntu), then Mint, Debian, and CrunchBang. Ubuntu variants are definitely more easy to setup the kicad build, and I’ve settled on Lubuntu because it is the lightest on RAM and disk (important when run from virtual machine) and I like the simplicity of Openbox/LXDE desktop environment.

If anybody wants my prebuilt virtual machine image, feel free to ask :slight_smile:

Kicad installed more or less out-of-the-box on my Fedora 20 system.

Also have it installed on a Macbook Air running MacOS 10.9.5 This is install was a bit more involved and required patching the wxWidgets dependancy.

FYI about the environment variables, https://lists.launchpad.net/kicad-developers/msg16659.html

1 Like