2012-09-30 21:23:28 +02:00
|
|
|
{ stdenv, fetchurl, dbus, dbus_cplusplus, expat, glibmm, libconfig
|
2012-04-08 01:57:30 +02:00
|
|
|
, libavc1394, libiec61883, libraw1394, libxmlxx, makeWrapper, pkgconfig
|
|
|
|
, pyqt4, python, pythonDBus, qt4, scons }:
|
2012-04-05 23:53:42 +02:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2012-09-30 21:23:28 +02:00
|
|
|
name = "libffado-${version}";
|
|
|
|
version = "2.1.0";
|
2012-04-05 23:53:42 +02:00
|
|
|
|
2012-09-30 21:23:28 +02:00
|
|
|
src = fetchurl {
|
|
|
|
url = "http://www.ffado.org/files/${name}.tgz";
|
|
|
|
sha256 = "11cxmy31c19720j2171l735rpg7l8i41icsgqscfd2vkbscfmh6y";
|
2012-04-05 23:53:42 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs =
|
2012-04-08 01:57:30 +02:00
|
|
|
[ dbus dbus_cplusplus expat glibmm libavc1394 libconfig
|
|
|
|
libiec61883 libraw1394 libxmlxx makeWrapper pkgconfig pyqt4
|
|
|
|
python pythonDBus qt4 scons
|
2012-04-05 23:53:42 +02:00
|
|
|
];
|
|
|
|
|
2012-04-08 01:57:30 +02:00
|
|
|
patches = [ ./enable-mixer-and-dbus.patch ];
|
|
|
|
|
|
|
|
# TODO fix ffado-diag, it doesn't seem to use PYPKGDIR
|
2012-09-30 21:23:28 +02:00
|
|
|
buildPhase = ''
|
|
|
|
export PYLIBSUFFIX=lib/${python.libPrefix}/site-packages
|
2012-10-07 22:28:45 +02:00
|
|
|
scons PYPKGDIR=$out/$PYLIBSUFFIX DEBUG=False
|
2012-09-30 21:23:28 +02:00
|
|
|
sed -e "s#/usr/local#$out#" -i support/mixer-qt4/ffado/config.py
|
|
|
|
'';
|
|
|
|
|
2012-04-05 23:53:42 +02:00
|
|
|
installPhase = ''
|
2012-04-08 01:57:30 +02:00
|
|
|
scons PREFIX=$out LIBDIR=$out/lib SHAREDIR=$out/share/libffado \
|
2012-09-30 21:23:28 +02:00
|
|
|
PYPKGDIR=$out/$PYLIBSUFFIX UDEVDIR=$out/lib/udev/rules.d install
|
2012-04-08 01:57:30 +02:00
|
|
|
|
2012-07-15 11:51:49 +02:00
|
|
|
sed -e "s#/usr/local#$out#g" -i $out/bin/ffado-diag
|
|
|
|
|
2012-04-08 01:57:30 +02:00
|
|
|
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:
|
2012-04-05 23:53:42 +02:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
homepage = http://www.ffado.org;
|
2012-04-08 01:57:30 +02:00
|
|
|
description = "FireWire audio drivers";
|
2012-04-05 23:53:42 +02:00
|
|
|
license = licenses.gpl3;
|
|
|
|
maintainers = [ maintainers.goibhniu ];
|
2014-03-16 12:08:26 +01:00
|
|
|
platforms = platforms.linux;
|
2012-04-05 23:53:42 +02:00
|
|
|
};
|
|
|
|
}
|