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

318.7. lmms-1.2.2

Pattern-based music production: sequencer, synthesizers, samples and LADSPA effects (Qt 5)

Version 1.2.2, release 1
Shelf studio — Music production: DAWs, audio editors, trackers, drum machines and notation
Phase 44_apps (Applications), 377 of 422 in build order
Licence GPL-2.0-or-later
Homepage https://lmms.io/
Build time 4.7 SBU
Installed size 32.4 MiB in 3085 files
Recipe ports/core/studio/lmms/kpkgbuild

About

LMMS is a pattern-based music production program: a song editor, beat and bassline patterns, a piano roll and a mixer, with built-in synthesizers (among them ZynAddSubFX, an emulated NES, SID and OPL2), a sampler, and LADSPA effects. It is built against Qt 5. The bundled ZynAddSubFX editor is drawn with FLTK.

Sources

Dependencies

Depends on: cmake, ninja, pkgconf, qt5-qtbase, qt5-qttools, qt5-qtwayland, libsndfile, libsamplerate, fftw, alsa-lib, libpulse, pipewire, portaudio, lame, libvorbis, libogg, fluidsynth, libgig, stk, libsoundio, sdl12-compat, fltk, cairo, zlib, perl.

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 lmms'

What kpkg does

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

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/studio/lmms
echo 'b185507fb64ecfd8e31145135b58ab244b637f9efc09c4176caf70aa3cbaae1e  lmms-1.2.2.tar.xz' | 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/lmms
SRC=$SRC_ROOT/lmms-1.2.2
PKG=$SRC_ROOT/pkg
rm -rf "$SRC_ROOT"
mkdir -p "$SRC" "$PKG"
tar --no-same-permissions --warning=no-unknown-keyword -xf lmms-1.2.2.tar.xz -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-cmake-policy.patch"

cmake -S . -B build -G Ninja \
	-DCMAKE_POLICY_VERSION_MINIMUM=3.5 \
	-DCMAKE_BUILD_TYPE=Release \
	-DCMAKE_INSTALL_PREFIX=/usr \
	-DCMAKE_INSTALL_LIBDIR=lib \
	-DCMAKE_CXX_FLAGS="$CXXFLAGS -Wno-deprecated-declarations $(pkg-config --cflags cairo)" \
	-DFORCE_VERSION=$version \
	-DBASHCOMP_PKG_PATH="$PKG/usr/share/bash-completion/completions" \
	-DWANT_QT5=ON \
	-DWANT_ALSA=ON \
	-DWANT_PULSEAUDIO=ON \
	-DWANT_PORTAUDIO=ON \
	-DWANT_JACK=ON \
	-DWANT_WEAKJACK=OFF \
	-DWANT_CARLA=OFF \
	-DWANT_VST=OFF \
	-DWANT_SDL=ON \
	-DWANT_SNDIO=OFF \
	-DWANT_SOUNDIO=ON \
	-DWANT_GIG=ON \
	-DWANT_STK=ON \
	-DWANT_SF2=ON \
	-DWANT_MP3LAME=ON \
	-DWANT_OGGVORBIS=ON \
	-DWANT_CALF=ON \
	-DWANT_CAPS=ON \
	-DWANT_CMT=ON \
	-DWANT_SWH=ON \
	-DWANT_TAP=ON

for _h in LMMS_HAVE_ALSA LMMS_HAVE_PULSEAUDIO LMMS_HAVE_PORTAUDIO LMMS_HAVE_JACK \
	LMMS_HAVE_SOUNDIO LMMS_HAVE_SDL LMMS_HAVE_STK; do
	grep -qx "#define $_h" build/lmmsconfig.h
done

cmake --build build
DESTDIR=$PKG cmake --install build

cat > "$PKG/usr/share/applications/lmms.desktop" <<'DESKTOP'
[Desktop Entry]
Type=Application
Name=LMMS
GenericName=Music Production
Comment=Compose music with a pattern sequencer, synthesizers, samples and effects
Exec=lmms %f
Icon=lmms
Terminal=false
StartupWMClass=lmms
Categories=Qt;AudioVideo;Audio;Midi;Sequencer;
MimeType=application/x-lmms-project;
Keywords=music;daw;sequencer;synthesizer;beat;midi;sample;
DESKTOP
chmod 644 "$PKG/usr/share/applications/lmms.desktop"

test -e "$PKG/usr/lib/lmms/libmalletsstk.so"
test -e "$PKG/usr/lib/lmms/libgigplayer.so"
test -f "$PKG/usr/share/bash-completion/completions/lmms"

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/lmms, 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 lmms-1.2.2-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/lmms, and runs the triggers its paths call for.

Contents

Installed programs: lmms.

Installed directories: /usr/include/lmms, /usr/lib/lmms, /usr/share/licenses/lmms, /usr/share/lmms.

Short descriptions

lmms software for easy music production

Notes

Each WANT_* switch asks for its library and, when the library is not found, drops the feature with a status line only. So after the configure, build.sh checks that build/lmmsconfig.h defines LMMS_HAVE_ALSA, LMMS_HAVE_PULSEAUDIO, LMMS_HAVE_PORTAUDIO, LMMS_HAVE_JACK, LMMS_HAVE_SOUNDIO, LMMS_HAVE_SDL and LMMS_HAVE_STK, and after the install that the Mallets and GIG player plugins were installed, so a missing library fails the build. Qt takes the Wayland app id from the program name, lmms, which the recipe’s desktop entry repeats in StartupWMClass.