docs: how to build native MLow audio on macOS/Linux (+ build script)#12
Closed
felipesartori wants to merge 1 commit into
Closed
docs: how to build native MLow audio on macOS/Linux (+ build script)#12felipesartori wants to merge 1 commit into
felipesartori wants to merge 1 commit into
Conversation
Add a macOS/Linux section to the README explaining how to build the native MLow codec into native/libopus_mlow.a and run with CGO_ENABLED=1 -tags mlow, plus scripts/build-mlow.sh which clones and builds edgardmessias/opus_mlow into native/. The .a is intentionally NOT committed: it is architecture-specific, and a stray .a in native/ would be picked by the Windows linker ahead of opus_mlow.dll (GNU ld searches lib<name>.a before <name>.dll), breaking the Windows -tags mlow build. So native/*.a is git-ignored and built locally per platform. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
0f81214 to
ab20f9c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Make native (live-audio) builds work on macOS/Linux, which previously only had Windows instructions.
native/libopus_mlow.a, how to build it, and theCGO_ENABLED=1 go run -tags mlow …command. Requirements updated accordingly.scripts/build-mlow.sh: clones and buildsedgardmessias/opus_mlowand copies the static lib intonative/..gitignore: ignoresnative/*.a.Why the
.ais not committedA compiled
.ais architecture-specific. Worse, a straynative/libopus_mlow.awould break the Windows build: for-lopus_mlow, GNU ld searcheslibopus_mlow.abeforeopus_mlow.dll, so on Windows it would try to link the wrong-arch archive instead of the bundled DLL. So the library is built locally per platform and git-ignored; Windows keeps using the committed.dlls untouched.Without the matching lib (or without
-tags mlow) the server still runs in signaling-only mode.🤖 Generated with Claude Code