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

nrsc5: init at 20171129 #32926

Merged
merged 3 commits into from Dec 25, 2017
Merged

nrsc5: init at 20171129 #32926

merged 3 commits into from Dec 25, 2017

Conversation

markuskowa
Copy link
Member

Motivation for this change

NRSC5 is a comand line tool to receive HD-Radio (digital radio in North America) with
a RTL-SDR radio device.

Things done

Tested with a RTL-SDR USB stick.

  • 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.

@@ -0,0 +1,644 @@
From 176e496b2a5461af122e20054079887b0b3d46a8 Mon Sep 17 00:00:00 2001
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this an upstream patch to the project?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, so this feature is basically derived from this fork? https://github.com/dsvensson/faad2

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The patch is from the nrsc5 package itself, which pulls from https://github.com/dsvensson/faad2
during the build process and applies the patch. An alternative solution would be
to add a separate package faad2-hdc, which is build from dsvensson faad2 branch.

@@ -12,8 +13,11 @@ stdenv.mkDerivation rec {
sha256 = "1db37ydb6mxhshbayvirm5vz6j361bjim4nkpwjyhmy4ddfinmhl";
};

patches = [ optional hdcSupport ./faad2-hdc-support.patch ];
Copy link
Member

@grahamc grahamc Dec 21, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is making an array of three things:

  1. the optional function
  2. the value of hdcSupport
  3. the patch

To make it do what you expect, you'll need:

patches = optional hdcSupport ./faad2-hdc-support.patch;

since optional returns an array:

  optional = cond: elem: if cond then [elem] else [];

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the hint

@markuskowa
Copy link
Member Author

markuskowa commented Dec 22, 2017

Thanks for your feedback. I rewrote the expression. The new solution is now self contained,
less invasive, and does not create an unnecessary cross dependence to the faad2 package.

@joachifm joachifm merged commit 31637d0 into NixOS:master Dec 25, 2017
@markuskowa markuskowa deleted the nrsc5 branch January 19, 2018 07:19
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

5 participants