318.4. kwave-26.08.2
KDE sound editor — record, cut, filter and convert WAV, FLAC, MP3, Ogg Vorbis and Opus
| Version | 26.08.2, release 1 |
| Shelf | studio — Music production: DAWs, audio editors, trackers, drum machines and notation |
| Phase | 44_apps (Applications), 374 of 422 in build order |
| Licence | GPL-2.0-or-later |
| Homepage | https://apps.kde.org/kwave/ |
| Build time | 15.8 SBU |
| Installed size | 7.8 MiB in 101 files |
| Recipe | ports/core/studio/kwave/kpkgbuild |
About
Kwave is KDE’s sound editor. It records, cuts, pastes and filters sound, and reads and writes WAV, FLAC, MP3, Ogg Vorbis and Ogg Opus files; audiofile handles WAV and the other uncompressed formats. It is a Qt 6 and KDE Frameworks program.
Sources
kwave-26.08.2.tar.xz(6.3 MiB)
sha256d4ff633303e870e0e9c59eb7adfc4b2f5ad82b6cfb34a4b36de6548c70845a78
upstream: https://download.kde.org/stable/release-service/26.08.2/src/kwave-26.08.2.tar.xz
archive copy: sources-4/studio--kwave-26.08.2.tar.xz
Dependencies
Depends on: cmake, ninja, extra-cmake-modules, gettext, librsvg, qt6-qtbase, qt6-qtmultimedia, qt6-qtwayland, karchive, kcompletion, kconfig, kconfigwidgets, kcoreaddons, kcrash, kdbusaddons, kdoctools, ki18n, kiconthemes, kio, kservice, ktextwidgets, kwidgetsaddons, kxmlgui, audiofile, libsamplerate, fftw, flac, libogg, libvorbis, opus, alsa-lib, libpulse, id3lib, libmad, lame.
Required by (1): kde-gear-multimedia.
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 kwave'
What kpkg does
kpkg runs these steps, in this order, as root inside the chroot. The port directory is /ports/core/studio/kwave.
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/kwave
echo 'd4ff633303e870e0e9c59eb7adfc4b2f5ad82b6cfb34a4b36de6548c70845a78 kwave-26.08.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/kwave
SRC=$SRC_ROOT/kwave-26.08.2
PKG=$SRC_ROOT/pkg
rm -rf "$SRC_ROOT"
mkdir -p "$SRC" "$PKG"
tar --no-same-permissions --warning=no-unknown-keyword -xf kwave-26.08.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:
cmake -S . -B build -G Ninja \
-D CMAKE_INSTALL_PREFIX=/usr \
-D KDE_INSTALL_LIBDIR=lib \
-D CMAKE_BUILD_TYPE=Release \
-D KDE_INSTALL_USE_QT_SYS_PATHS=ON \
-D BUILD_TESTING=OFF \
-D KF_SKIP_PO_PROCESSING=ON \
-D WITH_DOC=ON \
-D WITH_ALSA=ON \
-D WITH_PULSEAUDIO=ON \
-D WITH_QT_AUDIO=ON \
-D WITH_OSS=OFF \
-D WITH_FLAC=ON \
-D WITH_OGG_OPUS=ON \
-D WITH_OGG_VORBIS=ON \
-D WITH_MP3=ON \
-D DEBUG=OFF \
-Wno-dev
cmake --build build
DESTDIR=$PKG cmake --install build
for _size in 32 48 64 128; do
install -d "$PKG/usr/share/icons/hicolor/${_size}x${_size}/apps"
rsvg-convert -w "$_size" -h "$_size" \
-o "$PKG/usr/share/icons/hicolor/${_size}x${_size}/apps/org.kde.kwave.png" \
"$PKG/usr/share/icons/hicolor/scalable/apps/org.kde.kwave.svg"
done
cat > "$PKG/usr/share/applications/org.kde.kwave.desktop" <<'DESKTOP'
[Desktop Entry]
Type=Application
Name=Kwave
GenericName=Sound Editor
Comment=Record, edit and convert sound files
TryExec=kwave
Exec=kwave %F
Icon=org.kde.kwave
Terminal=false
StartupWMClass=org.kde.kwave
X-DBUS-StartupType=Unique
X-DocPath=kwave/index.html
Categories=Qt;KDE;AudioVideo;Audio;AudioVideoEditing;Recorder;
Keywords=sound;audio;editor;wave;record;recorder;cut;kwave;
DESKTOP
chmod 644 "$PKG/usr/share/applications/org.kde.kwave.desktop"
The switches, and why each is set:
-D KF_SKIP_PO_PROCESSING=ON— compile none of the translation catalogues inpo/; the package is English only under the size and language policy, so this only saves build time.-D WITH_DOC=ON— build Kwave’s handbook with kdoctools. On by default upstream.-D WITH_ALSA=ON— With-D WITH_PULSEAUDIO=ONand-D WITH_QT_AUDIO=ON: playback and recording through ALSA and PulseAudio, both of which PipeWire serves on KDOS, and playback through Qt Multimedia (qt6-qtmultimedia).-D WITH_OSS=OFF— no playback or recording through the OSS device interface, which upstream builds by default.-D WITH_FLAC=ON— With-D WITH_OGG_OPUS=ONand-D WITH_OGG_VORBIS=ON: the FLAC, Opus and Vorbis codecs. Each switch makes its library aREQUIREDpkg-config check, so a missing library stops the configure instead of dropping the format.-D WITH_MP3=ON— MP3 support: decoding through libmad, tags through id3lib, bothREQUIREDonce the switch is on, and encoding by running an externallameprogram, which is why lame is independs.-D DEBUG=OFF— leave the debug plugin out of the menu. This is upstream’s default.
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/kwave, 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 kwave-26.08.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/kwave, and runs the triggers its paths call for.
Contents
Installed programs: kwave.
Installed libraries: libkwave.so, libkwavegui.so.
Installed directories: /usr/lib/qt6/plugins/kwave, /usr/share/doc/HTML/en/kwave, /usr/share/kwave, /usr/share/licenses/kwave.
Notes
Upstream installs its icon as SVG only, which the panel does not draw, so the recipe rasterises org.kde.kwave.svg to PNGs from 32 to 128 pixels. It also writes its own org.kde.kwave.desktop: KAboutData sets the desktop file name, so the Wayland app id is org.kde.kwave, which the entry names in StartupWMClass. The entry has no MimeType line, so Kwave is offered as the opener of no file type.