diff --git a/pkgs/applications/networking/instant-messengers/sflphone/default.nix b/pkgs/applications/networking/instant-messengers/sflphone/default.nix index 4dbfa3da9793..79b554798eee 100644 --- a/pkgs/applications/networking/instant-messengers/sflphone/default.nix +++ b/pkgs/applications/networking/instant-messengers/sflphone/default.nix @@ -1,8 +1,10 @@ -{ stdenv, fetchurl, libyaml, alsaLib, openssl, libuuid, pkgconfig, pulseaudio, libsamplerate, -commoncpp2, ccrtp, libzrtpcpp, dbus, dbus_cplusplus, expat, pcre, gsm, speex, ilbc, libopus, -autoconf, automake, libtool, gettext, perl }: +{ stdenv, fetchurl, libyaml, alsaLib, openssl, libuuid, pkgconfig, pulseaudio, libsamplerate +, commoncpp2, ccrtp, libzrtpcpp, dbus, dbus_cplusplus, expat, pcre, gsm, speex, ilbc, libopus +, autoconf, automake, libtool, gettext, perl +, cmake, qt4 +, gtk, glib, dbus_glib, libnotify, intltool }: -stdenv.mkDerivation rec { +let name = "sflphone-1.2.3"; src = fetchurl { @@ -10,23 +12,68 @@ stdenv.mkDerivation rec { sha256 = "0aiwlky7mp5l51a7kkhkmaz7ivapypar291kdxzdxl1s3qy0x6fd"; }; - patches = [ ./libzrtpcpp-cflags.patch ]; + meta = { + homepage = http://sflphone.org/; + license = "GPLv3+"; + description = "Free software enterprise-class softphone for GNU/Linux"; + platforms = with stdenv.lib.platforms; linux; + maintainers = with stdenv.lib.maintainers; [viric]; + }; - preConfigure = '' - cd daemon +in +rec { + daemon = stdenv.mkDerivation { + name = name + "-daemon"; - # Post patch, required - autoreconf -vfi + inherit src; - cd libs - bash ./compile_pjsip.sh - cd .. - ''; + patches = [ ./libzrtpcpp-cflags.patch ]; - configureFlags = "--with-expat --with-expat-inc=${expat}/include " + - "--with-expat-lib=-lexpat --with-opus "; + preConfigure = '' + cd daemon - buildInputs = [ libyaml alsaLib openssl libuuid pkgconfig pulseaudio libsamplerate - commoncpp2 ccrtp libzrtpcpp dbus dbus_cplusplus expat pcre gsm speex ilbc libopus - autoconf automake libtool gettext perl ]; + # Post patch, required + autoreconf -vfi + + cd libs + bash ./compile_pjsip.sh + cd .. + ''; + + configureFlags = "--with-expat --with-expat-inc=${expat}/include " + + "--with-expat-lib=-lexpat --with-opus "; + + buildInputs = [ libyaml alsaLib openssl libuuid pkgconfig pulseaudio libsamplerate + commoncpp2 ccrtp libzrtpcpp dbus dbus_cplusplus expat pcre gsm speex ilbc libopus + autoconf automake libtool gettext perl ]; + }; + + # This fails still. + # I don't know the best way to make this a KDE program (with switchable kde + # libs, like digikam for example) + /* + kde = stdenv.mkDerivation { + name = name + "-kde"; + + inherit src; + + preConfigure = '' + cd kde + ''; + + buildInputs = [ daemon cmake qt4 pkgconfig ]; + }; + */ + + gnome = stdenv.mkDerivation { + name = name + "-gnome"; + + inherit src; + + preConfigure = '' + cd gnome + ''; + + buildInputs = [ daemon pkgconfig gtk glib dbus_glib libnotify intltool ]; + }; } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 7ac7ff889ffa..45ed59df8884 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8107,7 +8107,9 @@ let seq24 = callPackage ../applications/audio/seq24 { }; - sflphone = callPackage ../applications/networking/instant-messengers/sflphone { }; + sflphone = callPackage ../applications/networking/instant-messengers/sflphone { + gtk = gtk3; + }; siproxd = callPackage ../applications/networking/siproxd { };