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

Deadbeef 0.7.2 → 1.8.0 #59187

Merged
merged 3 commits into from Apr 13, 2019
Merged

Deadbeef 0.7.2 → 1.8.0 #59187

merged 3 commits into from Apr 13, 2019

Conversation

jtojnar
Copy link
Contributor

@jtojnar jtojnar commented Apr 8, 2019

Motivation for this change

http://deadbeef.sourceforge.net/posts/deadbeef_1.8.0_is_out.html

Added native opus support

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option 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 nix-review --run "nix-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Assured whether relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@jtojnar
Copy link
Contributor Author

jtojnar commented Apr 8, 2019

At the moment wildmidi plug-in is broken:

dlopen error: /nix/store/ad41yrj56xm27mzhzlkgmxks1z2g3y7s-deadbeef-with-plugins-1.8.0/lib/deadbeef/wildmidi.so: undefined symbol: X
trying /nix/store/ad41yrj56xm27mzhzlkgmxks1z2g3y7s-deadbeef-with-plugins-1.8.0/lib/deadbeef/wildmidi.fallback.so...
plugin wildmidi.so not found or failed to load

@bobvanderlinden
Copy link
Member

This also failed in the previous version, but it never showed a dialog box for this:

dlopen error: /nix/store/nxp9nlqs9d0x79yx3s08n87z61jxdgsx-deadbeef-0.7.2/lib/deadbeef/wildmidi.so: undefined symbol: X
trying /nix/store/nxp9nlqs9d0x79yx3s08n87z61jxdgsx-deadbeef-0.7.2/lib/deadbeef/wildmidi.fallback.so...
plugin not found or failed to load

@jtojnar
Copy link
Contributor Author

jtojnar commented Apr 13, 2019

Replacing our wildmidi.so with wildmidi.so from upstream fixed it.

So did the one built using the following command in nix-shell -A deadbeef:

unpackPhase
cd source
cd plugins/wildmidi
gcc -shared -Iinclude -DWILDMIDI_VERSION=\"0.2.2\" -DWILDMIDILIB_VERSION=\"0.2.2\" -DTIMIDITY_CFG=\"/etc/timidity.conf\" -fPIC wildmidiplug.c src/wildmidi_lib.c include/wildmidi_lib.h -o wildmidi.so -lm

If we build deadbeef with debugging info using nix-build -E 'with import <nixpkgs> {}; enableDebugging deadbeef' where the symbol comes from:

$ nm -A -D -l result/lib/deadbeef/wildmidi.so
result/lib/deadbeef/wildmidi.so:0000000000018080 B X	/build/source/plugins/wildmidi/src/wildmidi_lib.c:399

Apparently, it is from this global variable:

https://github.com/DeaDBeeF-Player/deadbeef/blob/7ac83fb204fc3c8a35486ef8f9550cd98cec674e/plugins/wildmidi/src/wildmidi_lib.c#L399

But its name is b, not X.

I tried hardeningDisable = ["all"]; but that did not help. What else could be renaming the symbol?

- Add native opus support
- Remove wildmidi dependency, deadbeef uses its own fork
opus support is now built into deadbeef
@bobvanderlinden
Copy link
Member

bobvanderlinden commented Apr 13, 2019

The installPhase seemed to be messing things up. Using dontPatchELF = true; resolves the issue for me. With that the warning did not show up. Not sure what consequences this has for the other elf-files.

EDIT: Ah, didn't notice you pushed a new version. Your patch is much cleaner than using dontPatchELF!

@bobvanderlinden
Copy link
Member

Confirmed to be working with the patch. 👍 Thank you!

@jtojnar
Copy link
Contributor Author

jtojnar commented Apr 13, 2019

I can reproduce it with nix run -f . patchelfUnstable -c patchelf --shrink-rpath wildmidi.so. Will open an issue with patchelf.

@jtojnar jtojnar merged commit 14a008d into NixOS:master Apr 13, 2019
@jtojnar jtojnar deleted the deadbeef-1.8.0 branch April 13, 2019 15:50
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

3 participants