nixpkgs-suyu/pkgs/development/libraries/openal-soft/default.nix

40 lines
1 KiB
Nix
Raw Normal View History

{ stdenv, fetchurl, cmake
2016-02-29 19:47:12 +01:00
, alsaSupport ? !stdenv.isDarwin, alsaLib ? null
, pulseSupport ? !stdenv.isDarwin, libpulseaudio ? null
, CoreServices, AudioUnit, AudioToolbox
}:
2015-02-21 00:43:40 +01:00
with stdenv.lib;
assert alsaSupport -> alsaLib != null;
assert pulseSupport -> libpulseaudio != null;
stdenv.mkDerivation rec {
2017-11-09 09:43:36 +01:00
version = "1.18.2";
2013-04-01 17:52:57 +02:00
name = "openal-soft-${version}";
src = fetchurl {
2013-04-01 17:52:57 +02:00
url = "http://kcat.strangesoft.net/openal-releases/${name}.tar.bz2";
2017-11-09 09:43:36 +01:00
sha256 = "10kydm8701a2kppiss9sdidn1820cmzhqgx1b2bsa5dsgzic32lz";
};
nativeBuildInputs = [ cmake ];
buildInputs = []
2015-02-21 00:43:40 +01:00
++ optional alsaSupport alsaLib
2016-02-29 19:47:12 +01:00
++ optional pulseSupport libpulseaudio
++ optionals stdenv.isDarwin [ CoreServices AudioUnit AudioToolbox ];
NIX_LDFLAGS = []
2015-02-21 00:43:40 +01:00
++ optional alsaSupport "-lasound"
++ optional pulseSupport "-lpulse";
meta = {
description = "OpenAL alternative";
homepage = http://kcat.strangesoft.net/openal.html;
2015-02-21 00:43:40 +01:00
license = licenses.lgpl2;
maintainers = with maintainers; [ftrvxmtrx];
2016-02-29 19:47:12 +01:00
platforms = platforms.unix;
};
}