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

Ubertooth package and module #87750

Merged
merged 5 commits into from Apr 2, 2021
Merged

Ubertooth package and module #87750

merged 5 commits into from Apr 2, 2021

Conversation

oxzi
Copy link
Member

@oxzi oxzi commented May 13, 2020

Motivation for this change

Add the host driver for an Ubertooth as a package and a module. Therefore, the required libbtbb is added first.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • 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 nixpkgs-review --run "nixpkgs-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)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

@Mic92
Copy link
Member

Mic92 commented May 26, 2020

@GrahamcOfBorg build ubertooth

@Mic92
Copy link
Member

Mic92 commented May 26, 2020

Result of nixpkgs-review pr 87750 1

1 package blacklisted:
- tests.nixos-functions.nixos-test
2 packages built:
- libbtbb
- ubertooth

@oxzi
Copy link
Member Author

oxzi commented Jul 19, 2020

I updated this PR and made it Linux-exclusive. I would be very happy to see this one merged and to deal with further PRs regarding macOS compatibility.

Copy link
Member

@mweinelt mweinelt left a comment

Choose a reason for hiding this comment

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

I'm not sure about the group option. The rest looks okay.

Result of nixpkgs-review pr 87750 1

1 package blacklisted:
- tests.nixos-functions.nixos-test
2 packages built:
- libbtbb
- ubertooth

options.hardware.ubertooth = {
enable = mkEnableOption "Enable the Ubertooth software and its udev rules.";

group = mkOption {
Copy link
Member

Choose a reason for hiding this comment

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

I'm not sure the group option provides much value, when users need to add themselves to the group manually anyway, which in turn would also create the group.

users.groups.ubertooth.members = [ "me" ];

A better option would IMO be one to specify users that will be added to the ubertooth group.

Copy link
Member Author

Choose a reason for hiding this comment

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

On the one hand this is probably true, however, I have tried to adapt to other hardware modules. Most modules are just specifying a fixed group (e.g. acpilight, bladeRF, brillo). However, some modules are making this group configurable, e.g., nitrokey.

Specifying a list of users would be a third way in which the use of different modules differs even more. So I wouldn't find it so appropriate. Should I just configure a fixed group then?

@oxzi
Copy link
Member Author

oxzi commented Jan 8, 2021

I have updated both ubertooth and libbtbb to their latest release and rebased this branch against master.

@tgunnoe
Copy link
Contributor

tgunnoe commented Apr 2, 2021

LGTM

@mweinelt mweinelt merged commit 54d2863 into NixOS:master Apr 2, 2021
@@ -0,0 +1,34 @@
{ stdenv, lib, fetchFromGitHub, cmake, pkgconfig, libbtbb, libpcap , libusb1, bluez
Copy link
Member

Choose a reason for hiding this comment

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

pkgconfig -> pkg-config, fixed in #118330

@oxzi oxzi deleted the ubertooth branch April 3, 2021 14:20
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