Skip to the text
KDOS
Menu
kdos.dev KDOS from Scratch KDOS 0.2 · 4dd4a10 · 2026-11-30 Contents Index

338.6. kicad-10.0.6

Schematic capture, PCB layout, Gerber viewer and SPICE simulation for electronics design

Version 10.0.6, release 1
Shelf eda — Electronics: schematic and PCB, circuit simulation, antenna modelling, FPGA synthesis and simulation, logic analysers and bench instruments
Phase 44_apps (Applications), 73 of 422 in build order
Licence GPL-3.0-or-later
Homepage https://www.kicad.org/
Build time 74.4 SBU
Installed size 533.7 MiB in 949 files
Recipe ports/core/eda/kicad/kpkgbuild

About

KiCad is the full electronics design suite: schematic capture (Eeschema), board layout (Pcbnew), the Gerber viewer, the footprint and symbol editors, a SPICE simulator front end driving ngspice, and kicad-cli for plotting and exporting from scripts. It is built on wxwidgets with GTK 3. The symbol, footprint and template libraries are ports of their own, kicad-symbols, kicad-footprints and kicad-templates.

Sources

Dependencies

Depends on: cmake, ninja, pkgconf, swig, python3, python3-wxpython, wxwidgets, gtk3, webkitgtk, glib, cairo, pixman, freetype2, harfbuzz, fontconfig, mesa, libglvnd, glu, wayland, libsecret, poppler, glm, zlib, zstd, curl, boost, libgit2, libspnav, ngspice, opencascade, protobuf, abseil-cpp, nng, unixodbc.

Required by: no port names it.

Patches

build.sh applies these; kpkg applies nothing by itself.

Installation

From the repository root, inside the build container, this is the line kdosbuild runs for the port:

script/chroot/exec.sh bash -c 'source script/phases/44_apps/phase.env && kpkg install kicad'

What kpkg does

kpkg runs these steps, in this order, as root inside the chroot. The port directory is /ports/core/eda/kicad.

1. Verify every declared source. Each file a sha256 = line names, found in the port directory or in /var/cache/kpkg/sources, must hash to its line; a mismatch stops the build before anything is unpacked.

cd /ports/core/eda/kicad
echo '528788c342461536bee3331998a8aa609975723f07b816287146ab8d4d9af3cb  kicad-10.0.6.tar.gz' | sha256sum -c -

2. Unpack. The work directory is emptied and the first source is unpacked into $SRC with its top directory stripped; any later tarball lands unstripped beside it in $SRC_ROOT, and a file that is not a tarball is copied into $SRC.

SRC_ROOT=/var/cache/kpkg/work/kicad
SRC=$SRC_ROOT/kicad-10.0.6
PKG=$SRC_ROOT/pkg
rm -rf "$SRC_ROOT"
mkdir -p "$SRC" "$PKG"
tar --no-same-permissions --warning=no-unknown-keyword -xf kicad-10.0.6.tar.gz -C "$SRC" --strip-components=1

Every config.guess and config.sub older than automake’s is then replaced with automake’s, so a configure script recognises the musl target.

3. Build. build.sh is sourced in a subshell under set -e, from $SRC, with name, version, release and the five paths PKGNAME, PORT_SRC, SRC_ROOT, SRC and PKG set as shell variables. Its body, verbatim:

patch -p1 -i "$PORT_SRC/fix-swig-iterator-next.patch"
patch -p1 -i "$PORT_SRC/app-id.patch"
patch -p1 -i "$PORT_SRC/startwizard-no-update-check.patch"

cmake -S . -B build -G Ninja -Wno-dev \
	-DCMAKE_POLICY_VERSION_MINIMUM=3.5 \
	-DCMAKE_BUILD_TYPE=Release \
	-DCMAKE_INSTALL_PREFIX=/usr \
	-DCMAKE_INSTALL_LIBDIR=lib \
	-DKICAD_UPDATE_CHECK=OFF \
	-DKICAD_USE_SENTRY=OFF \
	-DKICAD_BUILD_I18N=OFF \
	-DKICAD_BUILD_QA_TESTS=OFF \
	-DKICAD_SPICE_QA=OFF \
	-DKICAD_SCRIPTING_WXPYTHON=ON \
	-DKICAD_WAYLAND=ON \
	-DKICAD_IPC_API=ON \
	-DKICAD_SIGNAL_INTEGRITY=ON \
	-DKICAD_IDF_TOOLS=ON \
	-DKICAD_INSTALL_DEMOS=ON \
	-DKICAD_BUILD_FLATPAK=OFF

cmake --build build --target common/pcb_lexer.h
cmake --build build
DESTDIR=$PKG cmake --install build

test -x "$PKG/usr/bin/kicad"
test -x "$PKG/usr/bin/kicad-cli"
test -f "$PKG/usr/share/applications/org.kicad.kicad.desktop"
test -f "$PKG/usr/share/icons/hicolor/48x48/apps/kicad.png"
ls "$PKG"/usr/lib/python3*/site-packages/_pcbnew.so >/dev/null

The switches, and why each is set:

The common switches of each build system are explained in the Flag glossary.

4. Package. kpkg removes libtool archives, the info directory index, mimeinfo.cache and every fonts.dir from $PKG, copies the source’s licence files into /usr/share/licenses/kicad, prunes what the image does not ship, lints the tree and rolls it reproducibly:

tar --sort=name --format=gnu --numeric-owner --owner=0 --group=0 \
    --mtime=@$SOURCE_DATE_EPOCH \
    --use-compress-program='xz -9 -T0 --block-size=32MiB --no-adjust' \
    -cf kicad-10.0.6-1.tar.xz -C "$PKG" .

5. Adopt. kpkgadd installs the package’s files over the root, refusing a path another package owns, records the file list in /var/lib/kpkg/db/kicad, and runs the triggers its paths call for.

Contents

Installed programs: _cvpcb.kiface, _eeschema.kiface, _gerbview.kiface, _kipython.kiface, _pcb_calculator.kiface, _pcbnew.kiface, _pl_editor.kiface, bitmap2component, dxf2idf, eeschema, gerbview, idf2vrml, idfcyl, idfrect, kicad, kicad-cli, pcb_calculator, pcbnew, pl_editor.

Installed libraries: libkiapi.so, libkicad_3dsg.so, libkicommon.so, libkigal.so.

Installed directories: /usr/lib/kicad, /usr/share/kicad/demos, /usr/share/kicad/plugins, /usr/share/kicad/resources, /usr/share/kicad/schemas, /usr/share/kicad/scripting, /usr/share/licenses/kicad.

Notes

build.sh builds the target common/pcb_lexer.h on its own before the full build. That generated header is not ordered before its first consumer, so a parallel build can compile a file that includes it before it exists.

SWIG from version 4.4 drops the Python 2 style .next() method of its iterators, which the pcbnew bindings call; fix-swig-iterator-next.patch, upstream’s merge request, calls Python 3’s next() instead. Without it a script that iterates over a board’s item or track lists (the std::deque<BOARD_ITEM *> and std::deque<PCB_TRACK *> wrappers in pcbnew/python/swig/board.i) fails with an AttributeError.

Each program’s Wayland app id is the name of its desktop entry, org.kicad.kicad, org.kicad.eeschema, org.kicad.pcbnew, org.kicad.gerbview, org.kicad.pcbcalculator and org.kicad.bitmap2component, which is the only name KWin looks a window’s icon up by. KiCad sets it through wxWidgets only from wxWidgets 3.3.1, and wxwidgets is 3.2, so app-id.patch sets GTK’s program name to the same id there; without it every window takes its executable’s name and shows the generic icon. An editor opened from the project manager runs in its process and takes org.kicad.kicad. The patch is to be offered upstream.

The plugin and content manager reads an online repository, so on a machine with no network it lists nothing.