ryanfrancesconi/spfk-taglib
TagLib packaged for Swift Package Manager.
Overview
spfk-taglib is an independent SPM repackaging of taglib/taglib, the C++ audio metadata library. The source tree mirrors upstream TagLib's directory layout — headers live alongside their .cpp files in format-specific subdirectories — making syncs with upstream a straightforward directory-level diff.
The current upstream base is TagLib 2.3.1 (tracked via SPFK_TAGLIB_UPSTREAM_VERSION in taglib_config.h).
Structure
Public headers are colocated with their implementations (matching upstream) and exposed to SPM via symlinks in include/taglib/. A module.modulemap defines the taglib and taglib_c modules. Run scripts/update-symlinks.sh after adding or removing public headers.
Syncing with Upstream
The directory layout mirrors upstream TagLib, so syncing is a bulk mirror of upstream's taglib/ directory into Sources/taglib/ via rsync --delete, preserving the SPM-specific paths (include/, utfcpp/, toolkit/taglib_config.h) and stripping build-system files (CMakeLists.txt, *.cmake, etc.).
For new format modules introduced upstream, add the corresponding headerSearchPath entries to Package.swift, add public headers to module.modulemap, and run scripts/update-symlinks.sh.
On tagged upstream releases, bump SPFK_TAGLIB_UPSTREAM_VERSION in Sources/taglib/toolkit/taglib_config.h and the version line in this README.
Versioning
This package uses its own semantic versioning starting at 1.0.0, independent of upstream TagLib version numbers. The upstream TagLib revision is tracked in taglib_config.h.
Usage
Add to your Package.swift:
dependencies: [
.package(url: "https://github.com/ryanfrancesconi/spfk-taglib", from: "1.0.0"),
],
targets: [
.target(
name: "YourTarget",
dependencies: [
.product(name: "taglib", package: "spfk-taglib"),
]
),
]Swift Bindings
Swift bindings and higher-level metadata functionality are provided by SPFKMetadata, which wraps spfk-taglib's C++ API in a native Swift interface.
License
About
Spongefork is the personal software projects of musician and developer Ryan Francesconi. Dedicated to creative sound manipulation, his first application, Spongefork, was released in 1999 for macOS 8. From 2026, Spongefork returns as his software container for more musical experimentation. In addition to software releases, open source components can be found on his GitHub page.
Package Metadata
Repository: ryanfrancesconi/spfk-taglib
Default branch: main
README: README.md