Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
c4f3d97
firefox-bin: fix references
oxij Feb 23, 2018
d57ebca
telegram/tdesktop: fix references
oxij Feb 23, 2018
5c76f58
qt-5/qtmultimedia: allow to disable pulseaudio
oxij Feb 23, 2018
cd84f17
libmikmod: allow to disable pulseaudio
oxij Feb 23, 2018
6a16258
openal-soft: allow to disable pulseaudio
oxij Feb 23, 2018
ae56503
retroarchBare: allow to disable pulseaudio
oxij Feb 23, 2018
fb3fc78
alsaPlugins: allow to disable pulseaudio and jack
oxij Feb 23, 2018
0700c6e
fluidsynth: allow to disable pulseaudio and jack
oxij Feb 23, 2018
194af04
lmms: allow to disable pulseaudio and jack
oxij Feb 23, 2018
126fb0a
gst-plugins-good: allow to disable pulseaudio
oxij Feb 23, 2018
0f0554c
gstreamer: fix condition
oxij Feb 23, 2018
f86353f
pcaudiolib: fix condition
oxij Feb 23, 2018
818f1f0
aegisub: fix condition
oxij Feb 23, 2018
2530007
obs-studio: fix condition
oxij Feb 23, 2018
802b87d
bomi: fix condition
oxij Feb 23, 2018
b2f2214
chromium: fix condition
oxij Feb 23, 2018
81bec5d
deadbeef: fix condition
oxij Feb 23, 2018
3bf5763
guvcview: fix condition
oxij Feb 23, 2018
3ba6ad3
virtualbox: fix condition
oxij Feb 23, 2018
63ce5b4
blueman: fix condition
oxij Feb 23, 2018
4c2ff98
firefox: fix condition
oxij Feb 23, 2018
5934bc2
libmatemixer: fix condition
oxij Feb 23, 2018
01038ea
mate-settings-daemon: fix condition
oxij Feb 23, 2018
c2f9059
apulse: patch with trace-to-stderr patch
oxij Feb 23, 2018
2c42f94
apulse: trace missing API calls
oxij Feb 23, 2018
fe9eb72
pkgs: pulseaudio -> pressureaudio; nixos: override when running a daemon
oxij Feb 22, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions nixos/modules/config/pulseaudio.nix
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,9 @@ in {
source = writeText "libao.conf" "default_driver=pulse"; }
];

environment.sessionVariables.LD_LIBRARY_PATH =
[ "${getLib overriddenPackage}/lib" ];

# Allow PulseAudio to get realtime priority using rtkit.
security.rtkit.enable = true;

Expand Down
4 changes: 2 additions & 2 deletions pkgs/applications/audio/deadbeef/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ stdenv, fetchurl, intltool, pkgconfig, fetchpatch, jansson
{ config, stdenv, fetchurl, intltool, pkgconfig, fetchpatch, jansson
# deadbeef can use either gtk2 or gtk3
, gtk2Support ? false, gtk2 ? null
, gtk3Support ? true, gtk3 ? null, gsettings_desktop_schemas ? null, wrapGAppsHook ? null
Expand All @@ -20,7 +20,7 @@
, osdSupport ? true, dbus ? null
# output plugins
, alsaSupport ? true, alsaLib ? null
, pulseSupport ? true, libpulseaudio ? null
, pulseSupport ? config.pulseaudio or stdenv.isLinux, libpulseaudio ? null
# effect plugins
, resamplerSupport ? true, libsamplerate ? null
, overloadSupport ? true, zlib ? null
Expand Down
13 changes: 10 additions & 3 deletions pkgs/applications/audio/fluidsynth/default.nix
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
{ stdenv, lib, fetchFromGitHub, pkgconfig, cmake
, alsaLib, glib, libjack2, libsndfile, libpulseaudio
{ config, stdenv, lib, fetchFromGitHub, pkgconfig, cmake
, alsaLib, glib, libsndfile
, AudioUnit, CoreAudio, CoreMIDI, CoreServices
, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux, libpulseaudio ? null
, jackSupport ? stdenv.isLinux, libjack2 ? null
}:

assert pulseaudioSupport -> libpulseaudio != null;
assert jackSupport -> libjack2 != null;

stdenv.mkDerivation rec {
name = "fluidsynth-${version}";
version = "1.1.8";
Expand All @@ -17,7 +22,9 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ pkgconfig cmake ];

buildInputs = [ glib libsndfile ]
++ lib.optionals (!stdenv.isDarwin) [ alsaLib libpulseaudio libjack2 ]
++ lib.optional stdenv.isLinux alsaLib
++ lib.optional pulseaudioSupport libpulseaudio
++ lib.optional jackSupport libjack2
++ lib.optionals stdenv.isDarwin [ AudioUnit CoreAudio CoreMIDI CoreServices ];

cmakeFlags = lib.optional stdenv.isDarwin "-Denable-framework=off";
Expand Down
20 changes: 14 additions & 6 deletions pkgs/applications/audio/lmms/default.nix
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
{ stdenv, fetchFromGitHub, cmake, pkgconfig, alsaLib ? null, fftwFloat, fltk13
, fluidsynth ? null, lame ? null, libgig ? null, libjack2 ? null, libpulseaudio ? null
{ config, lib, stdenv, fetchFromGitHub, cmake, pkgconfig, alsaLib ? null, fftwFloat, fltk13
, fluidsynth ? null, lame ? null, libgig ? null
, libsamplerate, libsoundio ? null, libsndfile, libvorbis ? null, portaudio ? null
, qtbase, qttools, SDL ? null }:
, qtbase, qttools, SDL ? null
, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux, libpulseaudio ? null
, jackSupport ? stdenv.isLinux, libjack2 ? null
}:

with lib;

assert pulseaudioSupport -> libpulseaudio != null;
assert jackSupport -> libjack2 != null;

stdenv.mkDerivation rec {
name = "lmms-${version}";
Expand All @@ -23,16 +31,16 @@ stdenv.mkDerivation rec {
fluidsynth
lame
libgig
libjack2
libpulseaudio
libsamplerate
libsndfile
libsoundio
libvorbis
portaudio
qtbase
SDL # TODO: switch to SDL2 in the next version
];
]
++ optional pulseaudioSupport libpulseaudio
++ optional jackSupport libjack2;

cmakeFlags = [ "-DWANT_QT5=ON" ];
enableParallelBuilding = true;
Expand Down
6 changes: 3 additions & 3 deletions pkgs/applications/networking/browsers/chromium/common.nix
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
, gnomeKeyringSupport ? false, libgnome_keyring3 ? null
, proprietaryCodecs ? true
, cupsSupport ? true
, pulseSupport ? false, libpulseaudio ? null
, pulseaudioSupport ? false, libpulseaudio ? null

, upstream-info
}:
Expand Down Expand Up @@ -131,7 +131,7 @@ let
] ++ optional gnomeKeyringSupport libgnome_keyring3
++ optionals gnomeSupport [ gnome.GConf libgcrypt ]
++ optionals cupsSupport [ libgcrypt cups ]
++ optional pulseSupport libpulseaudio;
++ optional pulseaudioSupport libpulseaudio;

patches = [
./patches/nix_plugin_paths_52.patch
Expand Down Expand Up @@ -245,7 +245,7 @@ let
proprietary_codecs = true;
enable_hangout_services_extension = true;
ffmpeg_branding = "Chrome";
} // optionalAttrs pulseSupport {
} // optionalAttrs pulseaudioSupport {
use_pulseaudio = true;
link_pulseaudio = true;
} // (extraAttrs.gnFlags or {}));
Expand Down
6 changes: 3 additions & 3 deletions pkgs/applications/networking/browsers/chromium/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ newScope, stdenv, makeWrapper, makeDesktopItem, ed
{ config, newScope, stdenv, makeWrapper, makeDesktopItem, ed
, glib, gtk3, gnome3, gsettings_desktop_schemas

# package customization
Expand All @@ -11,7 +11,7 @@
, enablePepperFlash ? false
, enableWideVine ? false
, cupsSupport ? true
, pulseSupport ? false
, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux
, commandLineArgs ? ""
}:

Expand All @@ -23,7 +23,7 @@ let

mkChromiumDerivation = callPackage ./common.nix {
inherit enableNaCl enableHotwording gnomeSupport gnome
gnomeKeyringSupport proprietaryCodecs cupsSupport pulseSupport
gnomeKeyringSupport proprietaryCodecs cupsSupport pulseaudioSupport
enableWideVine;
};

Expand Down
6 changes: 3 additions & 3 deletions pkgs/applications/networking/browsers/firefox-bin/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ stdenv, fetchurl, config, wrapGAppsHook
{ lib, stdenv, fetchurl, config, wrapGAppsHook
, alsaLib
, atk
, cairo
Expand Down Expand Up @@ -87,7 +87,7 @@ stdenv.mkDerivation {
libPath = stdenv.lib.makeLibraryPath
[ stdenv.cc.cc
alsaLib
alsaLib.dev
(lib.getDev alsaLib)
atk
cairo
curl
Expand Down Expand Up @@ -124,7 +124,7 @@ stdenv.mkDerivation {
pango
libheimdal
libpulseaudio
libpulseaudio.dev
(lib.getDev libpulseaudio)
systemd
] + ":" + stdenv.lib.makeSearchPathOutput "lib" "lib64" [
stdenv.cc.cc
Expand Down
2 changes: 1 addition & 1 deletion pkgs/applications/networking/browsers/firefox/wrapper.nix
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ let
++ lib.optionals (cfg.enableQuakeLive or false)
(with xorg; [ stdenv.cc libX11 libXxf86dga libXxf86vm libXext libXt alsaLib zlib libudev ])
++ lib.optional (enableAdobeFlash && (cfg.enableAdobeFlashDRM or false)) hal-flash
++ lib.optional (config.pulseaudio or true) libpulseaudio;
++ lib.optional (config.pulseaudio or stdenv.isLinux) libpulseaudio;
gst-plugins = with gst_all; [ gst-plugins-base gst-plugins-good gst-plugins-bad gst-plugins-ugly gst-ffmpeg ];
gtk_modules = [ libcanberra_gtk2 ];

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
, dee, ffmpeg, openalSoft, minizip, libopus, alsaLib, libpulseaudio, range-v3
}:

with lib;

mkDerivation rec {
name = "telegram-desktop-${version}";
version = "1.2.6";
Expand Down Expand Up @@ -40,7 +42,7 @@ mkDerivation rec {

enableParallelBuilding = true;

GYP_DEFINES = lib.concatStringsSep "," [
GYP_DEFINES = concatStringsSep "," [
"TDESKTOP_DISABLE_CRASH_REPORTS"
"TDESKTOP_DISABLE_AUTOUPDATE"
"TDESKTOP_DISABLE_REGISTER_CUSTOM_SCHEME"
Expand All @@ -52,14 +54,14 @@ mkDerivation rec {
"-DTDESKTOP_DISABLE_REGISTER_CUSTOM_SCHEME"
"-I${minizip}/include/minizip"
# See Telegram/gyp/qt.gypi
"-I${qtbase.dev}/mkspecs/linux-g++"
] ++ lib.concatMap (x: [
"-I${qtbase.dev}/include/${x}"
"-I${qtbase.dev}/include/${x}/${qtbase.version}"
"-I${qtbase.dev}/include/${x}/${qtbase.version}/${x}"
"-I${libopus.dev}/include/opus"
"-I${alsaLib.dev}/include/alsa"
"-I${libpulseaudio.dev}/include/pulse"
"-I${getDev qtbase}/mkspecs/linux-g++"
] ++ concatMap (x: [
"-I${getDev qtbase}/include/${x}"
"-I${getDev qtbase}/include/${x}/${qtbase.version}"
"-I${getDev qtbase}/include/${x}/${qtbase.version}/${x}"
"-I${getDev libopus}/include/opus"
"-I${getDev alsaLib}/include/alsa"
"-I${getDev libpulseaudio}/include/pulse"
]) [ "QtCore" "QtGui" "QtDBus" ];
CPPFLAGS = NIX_CFLAGS_COMPILE;

Expand Down Expand Up @@ -116,7 +118,7 @@ mkDerivation rec {
-e "s,'XDG-RUNTIME-DIR',\"\''${XDG_RUNTIME_DIR:-/run/user/\$(id --user)}\","
'';

meta = with lib; {
meta = {
description = "Telegram Desktop messaging app";
license = licenses.gpl3;
platforms = platforms.linux;
Expand Down
4 changes: 2 additions & 2 deletions pkgs/applications/video/bomi/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ stdenv, fetchFromGitHub, fetchpatch, pkgconfig, perl, python, which
{ config, stdenv, fetchFromGitHub, fetchpatch, pkgconfig, perl, python, which
, libX11, libxcb, mesa
, qtbase, qtdeclarative, qtquickcontrols, qttools, qtx11extras, qmake, makeWrapper
, libchardet
Expand All @@ -15,7 +15,7 @@
, libbluray
, jackSupport ? false, jack ? null
, portaudioSupport ? false, portaudio ? null
, pulseSupport ? true, libpulseaudio ? null
, pulseSupport ? config.pulseaudio or stdenv.isLinux, libpulseaudio ? null
, cddaSupport ? false, libcdda ? null
, youtubeSupport ? true, youtube-dl ? null
}:
Expand Down
14 changes: 9 additions & 5 deletions pkgs/applications/video/obs-studio/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{ stdenv
{ config
, stdenv
, fetchFromGitHub
, cmake
, fdk_aac
Expand All @@ -19,12 +20,15 @@
, pkgconfig
, vlc

, alsaSupport ? false
, alsaLib
, pulseaudioSupport ? false
, libpulseaudio
, alsaSupport ? stdenv.isLinux
, alsaLib ? null
, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux
, libpulseaudio ? null
}:

assert alsaSupport -> alsaLib != null;
assert pulseaudioSupport -> libpulseaudio != null;

let
optional = stdenv.lib.optional;
in stdenv.mkDerivation rec {
Expand Down
10 changes: 5 additions & 5 deletions pkgs/applications/virtualization/virtualbox/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ stdenv, fetchurl, lib, iasl, dev86, pam, libxslt, libxml2, libX11, xproto, libXext
{ config, stdenv, fetchurl, lib, iasl, dev86, pam, libxslt, libxml2, libX11, xproto, libXext
, libXcursor, libXmu, qt5, libIDL, SDL, libcap, zlib, libpng, glib, lvm2
, libXrandr, libXinerama
, pkgconfig, which, docbook_xsl, docbook_xml_dtd_43
Expand All @@ -7,7 +7,7 @@
, javaBindings ? false, jdk ? null
, pythonBindings ? false, python2 ? null
, enableExtensionPack ? false, requireFile ? null, patchelf ? null, fakeroot ? null
, pulseSupport ? false, libpulseaudio ? null
, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux, libpulseaudio ? null
, enableHardening ? false
, headless ? false
, enable32bitGuests ? true
Expand Down Expand Up @@ -61,7 +61,7 @@ in stdenv.mkDerivation {
libXmu libpng patchelfUnstable python ]
++ optional javaBindings jdk
++ optional pythonBindings python # Python is needed even when not building bindings
++ optional pulseSupport libpulseaudio
++ optional pulseaudioSupport libpulseaudio
++ optionals (headless) [ libXrandr ]
++ optionals (!headless) [ qt5.qtbase qt5.qtx11extras libXinerama SDL ];

Expand All @@ -79,7 +79,7 @@ in stdenv.mkDerivation {
ls kBuild/bin/linux.amd64/k* tools/linux.amd64/bin/* | xargs -n 1 patchelf --set-interpreter ${stdenv.glibc.out}/lib/ld-linux-x86-64.so.2

grep 'libpulse\.so\.0' src include -rI --files-with-match | xargs sed -i -e '
${optionalString pulseSupport
${optionalString pulseaudioSupport
''s@"libpulse\.so\.0"@"${libpulseaudio.out}/lib/libpulse.so.0"@g''}'

grep 'libdbus-1\.so\.3' src include -rI --files-with-match | xargs sed -i -e '
Expand Down Expand Up @@ -137,7 +137,7 @@ in stdenv.mkDerivation {
${optionalString headless "--build-headless"} \
${optionalString (!javaBindings) "--disable-java"} \
${optionalString (!pythonBindings) "--disable-python"} \
${optionalString (!pulseSupport) "--disable-pulse"} \
${optionalString (!pulseaudioSupport) "--disable-pulse"} \
${optionalString (!enableHardening) "--disable-hardening"} \
${optionalString (!enable32bitGuests) "--disable-vmmraw"} \
--disable-kmods --with-mkisofs=${xorriso}/bin/xorrisofs
Expand Down
2 changes: 1 addition & 1 deletion pkgs/desktops/mate/libmatemixer/default.nix
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{ stdenv, fetchurl, pkgconfig, intltool, glib, mate
, alsaSupport ? stdenv.isLinux, alsaLib
, pulseaudioSupport ? stdenv.config.pulseaudio or true, libpulseaudio
, pulseaudioSupport ? stdenv.config.pulseaudio or stdenv.isLinux, libpulseaudio
, ossSupport ? false
}:

Expand Down
2 changes: 1 addition & 1 deletion pkgs/desktops/mate/mate-settings-daemon/default.nix
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{ stdenv, fetchurl, pkgconfig, intltool, glib, dbus_glib, libxklavier, libcanberra_gtk3, libnotify, nss, polkit, gnome3, mate, wrapGAppsHook
, pulseaudioSupport ? stdenv.config.pulseaudio or true, libpulseaudio
, pulseaudioSupport ? stdenv.config.pulseaudio or stdenv.isLinux, libpulseaudio
}:

stdenv.mkDerivation rec {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@ stdenv.mkDerivation rec {
# TODO : v4l, libvisual
buildInputs =
[ pkgconfig glib cairo orc ]
# can't build alsaLib on darwin
++ stdenv.lib.optional (!stdenv.isDarwin) alsaLib
++ stdenv.lib.optional stdenv.isLinux alsaLib
++ stdenv.lib.optionals (!minimalDeps)
[ xorg.xlibsWrapper xorg.libXv libogg libtheora libvorbis freetype pango
liboil ]
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
{ fetchurl, stdenv, lib, pkgconfig, gst-plugins-base, aalib, cairo
{ config, fetchurl, stdenv, lib, pkgconfig, gst-plugins-base, aalib, cairo
, flac, libjpeg, zlib, speex, libpng, libdv, libcaca, libvpx
, libiec61883, libavc1394, taglib, libpulseaudio, gdk_pixbuf, orc
, libiec61883, libavc1394, taglib, gdk_pixbuf, orc
, glib, gstreamer, bzip2, libsoup, libshout, ncurses, libintlOrEmpty
, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux, libpulseaudio ? null
, # Whether to build no plugins that have external dependencies
# (except the PulseAudio plugin).
minimalDeps ? false
}:

assert pulseaudioSupport -> libpulseaudio != null;

stdenv.mkDerivation rec {
name = "gst-plugins-good-0.10.31";

Expand All @@ -24,7 +27,7 @@ stdenv.mkDerivation rec {

buildInputs =
[ pkgconfig glib gstreamer gst-plugins-base ]
++ lib.optional stdenv.isLinux libpulseaudio
++ lib.optional pulseaudioSupport libpulseaudio
++ libintlOrEmpty
++ lib.optionals (!minimalDeps)
[ aalib libcaca cairo libdv flac libjpeg libpng speex
Expand Down
9 changes: 6 additions & 3 deletions pkgs/development/libraries/libmikmod/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{ stdenv, fetchurl, texinfo, alsaLib, libpulseaudio, CoreAudio }:
{ config, stdenv, fetchurl, texinfo, alsaLib, CoreAudio
, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux, libpulseaudio ? null }:

let
inherit (stdenv.lib) optional optionals optionalString;
Expand All @@ -11,10 +12,12 @@ in stdenv.mkDerivation rec {
};

buildInputs = [ texinfo ]
++ optionals stdenv.isLinux [ alsaLib libpulseaudio ]
++ optional stdenv.isLinux alsaLib
++ optional pulseaudioSupport libpulseaudio
++ optional stdenv.isDarwin CoreAudio;

propagatedBuildInputs =
optional stdenv.isLinux libpulseaudio;
optional pulseaudioSupport libpulseaudio;

NIX_LDFLAGS = optionalString stdenv.isLinux "-lasound";

Expand Down
Loading