Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mpv: Add openal support #37745

Merged
merged 1 commit into from Mar 26, 2018
Merged

mpv: Add openal support #37745

merged 1 commit into from Mar 26, 2018

Conversation

Baughn
Copy link
Contributor

@Baughn Baughn commented Mar 24, 2018

Motivation for this change

mpv no longer has HRTF support, which means it can't collapse positional (e.g. 5.1) audio to stereo (for headphones) while maintaining the surround effect. The recommended workaround is to use -ao openal, which does know how to do this.

(Assuming you put hrtf = true in ~/.alsoftrc.)

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

@Mic92
Copy link
Member

Mic92 commented Mar 25, 2018

@GrahamcOfBorg build mpv

@GrahamcOfBorg
Copy link

Success on x86_64-linux (full log)

Attempted: mpv

Partial log (click to expand)

post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2
shrinking /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2/bin/.mpv-wrapped
shrinking /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2/lib/libmpv.so.1.25.0
gzipping man pages under /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2/share/man/
strip is /nix/store/fzcs0fn6bb04m82frhlb78nc03ny3w55-binutils-2.28.1/bin/strip
stripping (with command strip and flags -S) in /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2/lib  /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2/bin
patching script interpreter paths in /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2
checking for references to /tmp/nix-build-mpv-0.27.2.drv-0 in /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2...
/nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2

@GrahamcOfBorg
Copy link

Failure on x86_64-darwin (full log)

Attempted: mpv

Partial log (click to expand)

AudioGetHostClockMinimumTimeDelta()                                                                 __OSX_AVAILABLE_STARTING(__MAC_10_0, __IPHONE_2_0);
                                 ^
                                  void
17 warnings generated.

Waf: Leaving directory `/private/tmp/nix-build-mpv-0.27.2.drv-0/source/build'
Build failed
 -> task in 'mpv' failed with exit status 1 (run with -v to display more information)
builder for '/nix/store/8bn6war5bnb3lxhnjawdz46qnm9rkvxr-mpv-0.27.2.drv' failed with exit code 1
�[31;1merror:�[0m build of '/nix/store/8bn6war5bnb3lxhnjawdz46qnm9rkvxr-mpv-0.27.2.drv' failed

@GrahamcOfBorg
Copy link

Success on aarch64-linux (full log)

Attempted: mpv

Partial log (click to expand)

post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2
shrinking /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2/bin/.mpv-wrapped
shrinking /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2/lib/libmpv.so.1.25.0
gzipping man pages under /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2/share/man/
strip is /nix/store/3zq400fri5dv7d30lpxlqm2v9y1iis6j-binutils-2.28.1/bin/strip
stripping (with command strip and flags -S) in /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2/lib  /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2/bin
patching script interpreter paths in /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2
checking for references to /build in /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2...
/nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2

@Mic92
Copy link
Member

Mic92 commented Mar 25, 2018

Can you disable openal on macOS?

@knedlsepp
Copy link
Member

knedlsepp commented Mar 25, 2018

This fixes the darwin build for me:

    ++ optional (openalSupport && stdenv.isDarwin) darwin.apple_sdk.frameworks.OpenAL

@Baughn
Copy link
Contributor Author

Baughn commented Mar 26, 2018

@GrahamcOfBorg build mpv

1 similar comment
@Mic92
Copy link
Member

Mic92 commented Mar 26, 2018

@GrahamcOfBorg build mpv

@GrahamcOfBorg
Copy link

Success on x86_64-linux (full log)

Attempted: mpv

Partial log (click to expand)

post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2
shrinking /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2/lib/libmpv.so.1.25.0
shrinking /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2/bin/.mpv-wrapped
gzipping man pages under /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2/share/man/
strip is /nix/store/fzcs0fn6bb04m82frhlb78nc03ny3w55-binutils-2.28.1/bin/strip
stripping (with command strip and flags -S) in /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2/lib  /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2/bin
patching script interpreter paths in /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2
checking for references to /build in /nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2...
/nix/store/b8jsgzk7n95635c5wxncmcxkjnha8c8w-mpv-0.27.2

@GrahamcOfBorg
Copy link

Success on x86_64-darwin (full log)

Attempted: mpv

Partial log (click to expand)

/nix/store/49x13j2fbb4iv455mxdf0kbhw54r2fpy-mpv-0.27.2/lib/libmpv.1.25.0.dylib: fixing dylib
/nix/store/49x13j2fbb4iv455mxdf0kbhw54r2fpy-mpv-0.27.2/lib/libmpv.1.25.0.dylib: fixing dylib
/nix/store/49x13j2fbb4iv455mxdf0kbhw54r2fpy-mpv-0.27.2/lib/libmpv.1.25.0.dylib: fixing dylib
/nix/store/49x13j2fbb4iv455mxdf0kbhw54r2fpy-mpv-0.27.2/lib/libmpv.1.25.0.dylib: fixing dylib
/nix/store/49x13j2fbb4iv455mxdf0kbhw54r2fpy-mpv-0.27.2/lib/libmpv.1.25.0.dylib: fixing dylib
/nix/store/49x13j2fbb4iv455mxdf0kbhw54r2fpy-mpv-0.27.2/lib/libmpv.1.25.0.dylib: fixing dylib
/nix/store/49x13j2fbb4iv455mxdf0kbhw54r2fpy-mpv-0.27.2/lib/libmpv.1.25.0.dylib: fixing dylib
/nix/store/49x13j2fbb4iv455mxdf0kbhw54r2fpy-mpv-0.27.2/lib/libmpv.1.25.0.dylib: fixing dylib
/nix/store/49x13j2fbb4iv455mxdf0kbhw54r2fpy-mpv-0.27.2/lib/libmpv.1.25.0.dylib: fixing dylib
/nix/store/49x13j2fbb4iv455mxdf0kbhw54r2fpy-mpv-0.27.2

@GrahamcOfBorg
Copy link

Success on aarch64-linux (full log)

Attempted: mpv

Partial log (click to expand)

post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2
shrinking /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2/bin/.mpv-wrapped
shrinking /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2/lib/libmpv.so.1.25.0
gzipping man pages under /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2/share/man/
strip is /nix/store/3zq400fri5dv7d30lpxlqm2v9y1iis6j-binutils-2.28.1/bin/strip
stripping (with command strip and flags -S) in /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2/lib  /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2/bin
patching script interpreter paths in /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2
checking for references to /build in /nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2...
/nix/store/y08v6s8qs5ibpah8x8wyh8hgic0c2n8j-mpv-0.27.2

@Mic92 Mic92 merged commit 4720520 into NixOS:master Mar 26, 2018
@Baughn Baughn deleted the mpv-openal branch March 26, 2018 18:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants