mirror of
https://github.com/NixOS/nixos-hardware
synced 2024-11-08 12:09:40 +01:00
6cb18a6649
In larger installations nixpkgs.overlays adds significant overhead because it's harder to share nixpkgs between different NixOS machines i.e. using nixpkgs.pkgs
18 lines
573 B
Nix
18 lines
573 B
Nix
{ config, lib, pkgs, ... }:
|
|
{
|
|
config = lib.mkIf config.hardware.librem5.audio {
|
|
assertions = [{
|
|
assertion = config.hardware.pulseaudio.enable;
|
|
message = "Call audio on Librem5 requires pulse audio to be enabled through `hardware.pulseaudio.enable`.";
|
|
}];
|
|
hardware.pulseaudio = {
|
|
enable = true;
|
|
# this is required to correctly configure the modem as PA source/sink
|
|
extraConfig = ''
|
|
.include ${config.hardware.librem5.package}/etc/pulse/librem5.pa
|
|
'';
|
|
};
|
|
|
|
services.dbus.packages = [ pkgs.callaudiod ];
|
|
};
|
|
}
|