spandsp: fix url and patch UB on ppc64be - #499147
Open
amaanq wants to merge 3 commits into
Open
Conversation
amaanq
force-pushed
the
spandsp-fix-url-and-ub
branch
from
March 12, 2026 04:52
9b3d560 to
7dbd640
Compare
This comment was marked as resolved.
This comment was marked as resolved.
nixpkgs-ci
Bot
requested review from
Prince213,
eljamm,
ethancedwards8,
misuzu,
phanirithvij and
wegank
March 12, 2026 05:32
The LPC-10 test checks decoded audio against a reference WAV generated on x86. On POWER, small float rounding differences in the encoder accumulate over hundreds of frames and eventually produce different output, even though the codec itself works correctly.
OPNA2608
reviewed
Mar 24, 2026
| @@ -7,7 +7,7 @@ | |||
| (callPackage ./common.nix { }) rec { | |||
| version = "0.0.6"; | |||
| src = fetchurl { | |||
| url = "https://www.soft-switch.org/downloads/spandsp/spandsp-${version}.tar.gz"; | |||
| url = "https://src.fedoraproject.org/lookaside/pkgs/spandsp/spandsp-${version}.tar.gz/897d839516a6d4edb20397d4757a7ca3/spandsp-${version}.tar.gz"; | |||
Contributor
There was a problem hiding this comment.
Why not the Internet Archive? There's a capture from Feb 2026: https://web.archive.org/web/20260205180948/https://www.soft-switch.org/downloads/spandsp/spandsp-0.0.6.tar.gz
As an aside, finding the commit that corresponds to that version and fetching it from GitHub would be nice, but upstream doesn't believe in Git tags :(. 7b6d33a is dated Sep 2, 2014, so that might help with digging through the history to find the commit.
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.
Things done
The upstream source at
soft-switch.orgis permanently down. This PR switches to the Fedora lookaside cache mirror, which should hopefully never go down.This PR also adds a patch fixing undefined behavior in
bit_operations_testswhere1U << -1, which caused spurious test failures on ppc64be. I've submitted the fix upstream as freeswitch/spandsp#116.Lastly, lpc10_tests is disabled on ppc64, since it compares decoded LPC-10 audio against an x86-generated reference file, and (assumingly) POWER's FPU produces different enough float intermediates that the output diverges after a few hundred frames, even though the codec works correctly.
passthru.tests.nixpkgs-reviewon this PR. See nixpkgs-review usage../result/bin/.