about summary refs log tree commit diff
path: root/pkgs/applications/video/mplayer
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2013-01-14 23:08:27 +0100
committerEelco Dolstra <eelco.dolstra@logicblox.com>2013-01-14 23:08:27 +0100
commitbb6db816fe915a589155b45978b4a5a067945b46 (patch)
treec4187c81027a6801a714203be0675a30655442e5 /pkgs/applications/video/mplayer
parentf286cc65b111df56c5df23af09dbd2d8eb598ccc (diff)
downloadnixlib-bb6db816fe915a589155b45978b4a5a067945b46.tar
nixlib-bb6db816fe915a589155b45978b4a5a067945b46.tar.gz
nixlib-bb6db816fe915a589155b45978b4a5a067945b46.tar.bz2
nixlib-bb6db816fe915a589155b45978b4a5a067945b46.tar.lz
nixlib-bb6db816fe915a589155b45978b4a5a067945b46.tar.xz
nixlib-bb6db816fe915a589155b45978b4a5a067945b46.tar.zst
nixlib-bb6db816fe915a589155b45978b4a5a067945b46.zip
mplayer: Disable use of unfree binary codecs by default
Diffstat (limited to 'pkgs/applications/video/mplayer')
-rw-r--r--pkgs/applications/video/mplayer/default.nix10
1 files changed, 5 insertions, 5 deletions
diff --git a/pkgs/applications/video/mplayer/default.nix b/pkgs/applications/video/mplayer/default.nix
index 944af1c26571..357c6eec6e7e 100644
--- a/pkgs/applications/video/mplayer/default.nix
+++ b/pkgs/applications/video/mplayer/default.nix
@@ -18,6 +18,7 @@
 , pulseSupport ? false, pulseaudio ? null
 # For screenshots
 , libpngSupport ? true, libpng ? null
+, useUnfreeCodecs ? false
 }:
 
 assert x11Support -> (libX11 != null && libXext != null && mesa != null);
@@ -66,9 +67,7 @@ let
       cp -prv * $out
     '';
 
-    meta = {
-      license = "unfree";
-    };
+    meta.license = "unfree";
   } else null;
 
 in
@@ -140,8 +139,7 @@ stdenv.mkDerivation rec {
       ${if x264Support then "--enable-x264 --disable-x264-lavc" else "--disable-x264 --enable-x264-lavc"}
       ${if jackaudioSupport then "--enable-jack" else "--disable-jack"}
       ${if pulseSupport then "--enable-pulse" else "--disable-pulse"}
-
-      ${optionalString (codecs != null) "--codecsdir=${codecs}"}
+      ${optionalString (useUnfreeCodecs && codecs != null) "--codecsdir=${codecs}"}
       ${optionalString (stdenv.isi686 || stdenv.isx86_64) "--enable-runtime-cpudetection"}
       --enable-freetype
       --disable-xanim
@@ -154,6 +152,8 @@ stdenv.mkDerivation rec {
 
   NIX_LDFLAGS = stdenv.lib.optionalString x11Support "-lX11 -lXext";
 
+  enableParallelBuilding = true;
+
   # Provide a reasonable standard font.  Maybe we should symlink here.
   postInstall =
     ''