Skip to content

Commit

Permalink
alsa-utils: do not sed info script (#97841)
Browse files Browse the repository at this point in the history
The script contains lspci.log file names and the overeager replacement breaks it.
  • Loading branch information
jtojnar committed Sep 12, 2020
1 parent 8d25f83 commit 272e427
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions pkgs/os-specific/linux/alsa-utils/default.nix
@@ -1,4 +1,4 @@
{stdenv, fetchurl, alsaLib, gettext, ncurses, libsamplerate, pciutils, fftw}:
{stdenv, fetchurl, alsaLib, gettext, makeWrapper, ncurses, libsamplerate, pciutils, which, fftw}:

stdenv.mkDerivation rec {
pname = "alsa-utils";
Expand All @@ -9,18 +9,17 @@ stdenv.mkDerivation rec {
sha256 = "1ai1z4kf91b1m3qrpwqkc1af5vm2fkdkknqv95xdwf19q94aw6gz";
};

patchPhase = ''
substituteInPlace alsa-info/alsa-info.sh \
--replace "which" "type -p" \
--replace "lspci" "${pciutils}/bin/lspci"
'';
nativeBuildInputs = [ gettext ];
nativeBuildInputs = [ gettext makeWrapper ];
buildInputs = [ alsaLib ncurses libsamplerate fftw ];

configureFlags = [ "--disable-xmlto" "--with-udev-rules-dir=$(out)/lib/udev/rules.d" ];

installFlags = [ "ASOUND_STATE_DIR=$(TMPDIR)/dummy" ];

postFixup = ''
wrapProgram $out/bin/alsa-info.sh --prefix PATH : "${stdenv.lib.makeBinPath [ which pciutils ]}"
'';

meta = with stdenv.lib; {
homepage = "http://www.alsa-project.org/";
description = "ALSA, the Advanced Linux Sound Architecture utils";
Expand Down

0 comments on commit 272e427

Please sign in to comment.