Unverified Commit 91df0dc2 authored by Tristan Ross's avatar Tristan Ross Committed by GitHub
Browse files

alsa-lib: fix building with llvm (#374462)

parents 1351cf8b 666e3267
Loading
Loading
Loading
Loading
+19 −7
Original line number Diff line number Diff line
@@ -2,6 +2,7 @@
  lib,
  stdenv,
  fetchurl,
  fetchpatch,
  alsa-topology-conf,
  alsa-ucm-conf,
  testers,
@@ -16,13 +17,24 @@ stdenv.mkDerivation (finalAttrs: {
    hash = "sha256-jE/zdVPL6JYY4Yfkx3n3GpuyqLJ7kfh+1AmHzJIz2PY=";
  };

  patches = [
  patches =
    [
      # Add a "libs" field to the syntax recognized in the /etc/asound.conf file.
      # The nixos modules for pulseaudio, jack, and pipewire are leveraging this
      # "libs" field to declare locations for both native and 32bit plugins, in
      # order to support apps with 32bit sound running on x86_64 architecture.
      ./alsa-plugin-conf-multilib.patch
  ];
    ]
    ++ lib.optional (stdenv.hostPlatform.useLLVM or false)
      # Fixes version script under LLVM, should be fixed in the next update.
      # Check if "pkgsLLVM.alsa-lib" builds on next version bump and remove this
      # if it succeeds.
      (
        fetchurl {
          url = "https://github.com/alsa-project/alsa-lib/commit/76edab4e595bd5f3f4c636cccc8d7976d3c519d6.patch";
          hash = "sha256-WCOXfe0/PPZRMXdNa29Jn28S2r0PQ7iTsabsxZVSwnk=";
        }
      );

  enableParallelBuilding = true;