From 55e1d04e91f8e3600064e1972c84b9fbc31623ee Mon Sep 17 00:00:00 2001 From: Peter Hoeg Date: Tue, 14 Feb 2017 15:00:42 +0800 Subject: [PATCH] qtox: 1.5.0 -> 1.8.1 --- .../instant-messengers/qtox/default.nix | 53 +++++++------------ 1 file changed, 19 insertions(+), 34 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/qtox/default.nix b/pkgs/applications/networking/instant-messengers/qtox/default.nix index 9a26e2e4fc0f..036d7fb3ce52 100644 --- a/pkgs/applications/networking/instant-messengers/qtox/default.nix +++ b/pkgs/applications/networking/instant-messengers/qtox/default.nix @@ -1,46 +1,31 @@ -{ stdenv, fetchFromGitHub, pkgconfig, libtoxcore-dev, openal, opencv, - libsodium, libXScrnSaver, glib, gdk_pixbuf, gtk2, cairo, +{ stdenv, fetchFromGitHub, cmake, pkgconfig, openal, opencv, + libtoxcore, libsodium, libXScrnSaver, glib, gdk_pixbuf, gtk2, cairo, xorg, pango, atk, qrencode, ffmpeg, filter-audio, makeQtWrapper, - qtbase, qtsvg, qttools, qmakeHook, qttranslations, sqlcipher }: - -let - version = "1.5.0"; - revision = "v${version}"; -in + qtbase, qtsvg, qttools, qttranslations, sqlcipher, + libvpx, libopus }: stdenv.mkDerivation rec { name = "qtox-${version}"; + version = "1.8.1"; src = fetchFromGitHub { - owner = "tux3"; - repo = "qTox"; - rev = revision; - sha256 = "1na2qqzbdbjfw8kymxw5jfglslmw18fz3vpw805pqg4d5y7f7vsi"; + owner = "tux3"; + repo = "qTox"; + rev = "v${version}"; + sha256 = "073kwfaw5n7vvcpwrpdbw5mlswbbwjipx7yy4a95r9z0gjljqnhq"; }; - buildInputs = - [ - libtoxcore-dev openal opencv libsodium filter-audio - qtbase qttools qtsvg libXScrnSaver glib gtk2 cairo - pango atk qrencode ffmpeg qttranslations makeQtWrapper - sqlcipher - ]; + buildInputs = [ + libtoxcore openal opencv libsodium filter-audio + qtbase qttools qtsvg libXScrnSaver glib gtk2 cairo + pango atk qrencode ffmpeg qttranslations + sqlcipher + libopus libvpx + ] ++ (with xorg; [ + libpthreadstubs libXdmcp + ]); - nativeBuildInputs = [ pkgconfig qmakeHook ]; - - preConfigure = '' - # patch .pro file for proper set of the git hash - sed -i '/git rev-parse/d' qtox.pro - sed -i 's/$$quote($$GIT_VERSION)/${revision}/' qtox.pro - # since .pro have hardcoded paths, we need to explicitly set paths here - export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE $(pkg-config --cflags glib-2.0)" - export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE $(pkg-config --cflags gdk-pixbuf-2.0)" - export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE $(pkg-config --cflags gtk+-2.0)" - export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE $(pkg-config --cflags cairo)" - export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE $(pkg-config --cflags pango)" - export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE $(pkg-config --cflags atk)" - export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE $(pkg-config --cflags sqlcipher)" - ''; + nativeBuildInputs = [ cmake makeQtWrapper pkgconfig ]; installPhase = '' runHook preInstall