Author: cillian
Date: Sat Apr  7 23:57:30 2012
New Revision: 33664
URL: https://nixos.org/websvn/nix/?rev=33664&sc=1

Log:
Adding extra requirements, fixing some of the ffado utilities

Added:
   nixpkgs/trunk/pkgs/os-specific/linux/ffado/enable-mixer-and-dbus.patch
Modified:
   nixpkgs/trunk/pkgs/os-specific/linux/ffado/default.nix

Modified: nixpkgs/trunk/pkgs/os-specific/linux/ffado/default.nix
==============================================================================
--- nixpkgs/trunk/pkgs/os-specific/linux/ffado/default.nix      Sat Apr  7 
15:18:39 2012        (r33663)
+++ nixpkgs/trunk/pkgs/os-specific/linux/ffado/default.nix      Sat Apr  7 
23:57:30 2012        (r33664)
@@ -1,9 +1,9 @@
-{stdenv, fetchsvn, dbus_glib, dbus_libs, expat, glibmm, jackaudio
-, libconfig, libiec61883, libraw1394, libxmlxx, pkgconfig, pyqt4, python
-, pythonDBus, qt4, scons }:
+{ stdenv, fetchsvn, dbus, dbus_cplusplus, expat, glibmm, libconfig
+, libavc1394, libiec61883, libraw1394, libxmlxx, makeWrapper, pkgconfig
+, pyqt4, python, pythonDBus, qt4, scons }:
 
 stdenv.mkDerivation rec {
-  name = "libffado-svn";
+  name = "libffado-svn-2117";
 
   src = fetchsvn {
     url = "http://subversion.ffado.org/ffado/trunk/libffado";;
@@ -12,18 +12,31 @@
   };
 
   buildInputs =
-    [ dbus_glib dbus_libs expat glibmm jackaudio libconfig libiec61883
-      libraw1394 libxmlxx pkgconfig pyqt4 python pythonDBus qt4 scons
+    [ dbus dbus_cplusplus expat glibmm libavc1394 libconfig
+      libiec61883 libraw1394 libxmlxx makeWrapper pkgconfig pyqt4
+      python pythonDBus qt4 scons
     ];
 
-  buildPhase = "scons";
+  patches = [ ./enable-mixer-and-dbus.patch ];
+
+  preBuild = "export PYLIBSUFFIX=lib/${python.libPrefix}/site-packages";
+
+  # TODO fix ffado-diag, it doesn't seem to use PYPKGDIR
+  buildPhase = "scons PYPKGDIR=$out/$PYLIBSUFFIX";
   installPhase = ''
-    scons PREFIX=$out LIBDIR=$out/lib SHAREDIR=$out/share/libffado install
+    scons PREFIX=$out LIBDIR=$out/lib SHAREDIR=$out/share/libffado \
+      PYPKGDIR=$out/$PYLIBSUFFIX install
+
+    PYDIR=$out/$PYLIBSUFFIX
+    wrapProgram $out/bin/ffado-mixer --prefix PYTHONPATH : \
+      $PYTHONPATH:$PYDIR:${pyqt4}/$LIBSUFFIX:${pythonDBus}/$LIBSUFFIX:
+    wrapProgram $out/bin/ffado-diag --prefix PYTHONPATH : \
+      
$PYTHONPATH:$PYDIR:$out/share/libffado/python:${pyqt4}/$LIBSUFFIX:${pythonDBus}/$LIBSUFFIX:
     '';
 
   meta = with stdenv.lib; {
     homepage = http://www.ffado.org;
-    description = "Firewire audio drivers";
+    description = "FireWire audio drivers";
     license = licenses.gpl3;
     maintainers = [ maintainers.goibhniu ];
   };

Added: nixpkgs/trunk/pkgs/os-specific/linux/ffado/enable-mixer-and-dbus.patch
==============================================================================
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ nixpkgs/trunk/pkgs/os-specific/linux/ffado/enable-mixer-and-dbus.patch      
Sat Apr  7 23:57:30 2012        (r33664)
@@ -0,0 +1,25 @@
+--- libffado-r2117/SConstruct  1970-01-01 01:00:01.000000000 +0100
++++ libffado-r2117/SConstruct  2012-04-06 18:26:45.521100690 +0200
+@@ -314,10 +314,8 @@
+ #
+ 
+ # PyQT checks
+-build_mixer = False
+-if conf.CheckForApp( 'which pyuic4' ) and conf.CheckForPyModule( 'dbus' ) and 
conf.CheckForPyModule( 'PyQt4' ) and conf.CheckForPyModule( 'dbus.mainloop.qt' 
):
+-    env['PYUIC4'] = True
+-    build_mixer = True
++env['PYUIC4'] = True
++build_mixer = True
+ 
+ if conf.CheckForApp( 'xdg-desktop-menu --help' ):
+     env['XDG_TOOLS'] = True
+@@ -348,7 +346,8 @@
+     name2 = pkg.replace("+","").replace(".","").replace("-","").upper()
+     env['%s_FLAGS' % name2] = conf.GetPKGFlags( pkg, pkgs[pkg] )
+ 
+-if not env['DBUS1_FLAGS'] or not env['DBUSC1_FLAGS'] or not 
conf.CheckForApp('which dbusxx-xml2cpp'):
++
++if False:
+     env['DBUS1_FLAGS'] = ""
+     env['DBUSC1_FLAGS'] = ""
+     print """
_______________________________________________
nix-commits mailing list
nix-comm...@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-commits

Reply via email to