From 9f8751528cd89d343258dd718afa56f8590917bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Mon, 18 Apr 2016 08:50:34 +0200 Subject: [PATCH 001/147] stdenv multiple-outputs: fix #14782 --docdir location - the default --docdir is typically DATAROOTDIR/doc/pkgName - I saw no other way than to employ some magic to guess this `pkgName` - user can override it by setting $shareDocName --- .../setup-hooks/multiple-outputs.sh | 20 ++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/pkgs/build-support/setup-hooks/multiple-outputs.sh b/pkgs/build-support/setup-hooks/multiple-outputs.sh index 2cf08d42ae04..c49ea4b09a7f 100644 --- a/pkgs/build-support/setup-hooks/multiple-outputs.sh +++ b/pkgs/build-support/setup-hooks/multiple-outputs.sh @@ -47,11 +47,28 @@ _overrideFirst outputInfo "info" "doc" "$outputMan" _multioutConfig() { if [ "$outputs" = "out" ] || [ -z "${setOutputFlags-1}" ]; then return; fi; + # try to detect share/doc/${shareDocName} + # Note: sadly, $configureScript detection comes later in configurePhase, + # and reordering would cause more trouble than worth. + if [ -z "$shareDocName" ]; then + local confScript="$configureScript" + if [ -z "$confScript" ] && [ -x ./configure ]; then + confScript=./configure + fi + if [ -f "$confScript" ]; then + local shareDocName="$(sed -n "s/^PACKAGE_TARNAME='\(.*\)'$/\1/p" < "$confScript")" + fi + # PACKAGE_TARNAME sometimes contains garbage. + if [ -n "$shareDocName" ] || echo "$shareDocName" | grep -q '[^a-zA-Z-_0-9]'; then + shareDocName="$(echo "$name" | sed 's/-[^a-zA-Z].*//')" + fi + fi + configureFlags="\ --bindir=${!outputBin}/bin --sbindir=${!outputBin}/sbin \ --includedir=${!outputInclude}/include --oldincludedir=${!outputInclude}/include \ --mandir=${!outputMan}/share/man --infodir=${!outputInfo}/share/info \ - --docdir=${!outputDoc}/share/doc \ + --docdir=${!outputDoc}/share/doc/${shareDocName} \ --libdir=${!outputLib}/lib --libexecdir=${!outputLib}/libexec \ --localedir=${!outputLib}/share/locale \ $configureFlags" @@ -62,6 +79,7 @@ _multioutConfig() { $installFlags" } + # Add rpath prefixes to library paths, and avoid stdenv doing it for $out. _addRpathPrefix "${!outputLib}" NIX_NO_SELF_RPATH=1 From f6dfbb692c638b83989eb9e5cd286ea847e84e36 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Tue, 19 Apr 2016 13:13:27 +0200 Subject: [PATCH 002/147] stdenv multiple-outputs: fix cross-build propagation Fixes #14817. The outputs weren't propagated correctly when cross-building. --- pkgs/build-support/setup-hooks/multiple-outputs.sh | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/pkgs/build-support/setup-hooks/multiple-outputs.sh b/pkgs/build-support/setup-hooks/multiple-outputs.sh index c49ea4b09a7f..06d80e12f09b 100644 --- a/pkgs/build-support/setup-hooks/multiple-outputs.sh +++ b/pkgs/build-support/setup-hooks/multiple-outputs.sh @@ -162,8 +162,8 @@ _multioutDevs() { # Make the first output (typically "dev") propagate other outputs needed for development. # Take the first, because that's what one gets when putting the package into buildInputs. -# Note: during the build, probably only the "native" development packages are useful. -# With current cross-building setup, all packages are "native" if not cross-building. +# Note: with current cross-building setup, all packages are "native" if not cross-building; +# however, if cross-building, the outputs are non-native. We have to choose the right file. _multioutPropagateDev() { if [ "$outputs" = "out" ]; then return; fi; @@ -188,8 +188,15 @@ _multioutPropagateDev() { fi mkdir -p "${!outputFirst}"/nix-support + local propagatedBuildInputsFile + if [ -z "$crossConfig" ]; then + propagatedBuildInputsFile=propagated-native-build-inputs + else + propagatedBuildInputsFile=propagated-build-inputs + fi + for output in $propagatedBuildOutputs; do - echo -n " ${!output}" >> "${!outputFirst}"/nix-support/propagated-native-build-inputs + echo -n " ${!output}" >> "${!outputFirst}"/nix-support/$propagatedBuildInputsFile done } From 60d6c5a92bd86fe0977bae93aca69b5ca3ccb4f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Tue, 19 Apr 2016 20:37:28 +0200 Subject: [PATCH 003/147] groff: fix build after --docdir fix --- pkgs/tools/text/groff/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/tools/text/groff/default.nix b/pkgs/tools/text/groff/default.nix index e08c10fd9ed2..ee8f9b7037f8 100644 --- a/pkgs/tools/text/groff/default.nix +++ b/pkgs/tools/text/groff/default.nix @@ -35,9 +35,9 @@ stdenv.mkDerivation rec { postInstall = '' # Remove example output with (random?) colors to # avoid non-determinism in the output - rm $doc/share/doc/examples/hdtbl/*color*ps + rm $doc/share/doc/${name}/examples/hdtbl/*color*ps # Remove creation date - find $doc/share/doc/ -type f -print0 | xargs -0 sed -i -e 's/%%CreationDate: .*//' + find $doc/share/doc/${name} -type f -print0 | xargs -0 sed -i -e 's/%%CreationDate: .*//' ''; meta = with stdenv.lib; { From 90ee00324077acfeec88c94f3f51a5a6ef132c89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Mon, 18 Apr 2016 10:24:28 +0200 Subject: [PATCH 004/147] gcc: fix mingw build after closure-size merge This may also (help to) fix also other less usual configurations. --- pkgs/development/compilers/gcc/builder.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pkgs/development/compilers/gcc/builder.sh b/pkgs/development/compilers/gcc/builder.sh index 3190c5f5739f..5b206a63daa1 100644 --- a/pkgs/development/compilers/gcc/builder.sh +++ b/pkgs/development/compilers/gcc/builder.sh @@ -210,10 +210,14 @@ preInstall() { postInstall() { + mkdir -p "$lib" # some configs don't have anything to put into $lib + # Move runtime libraries to $lib. moveToOutput "lib/lib*.so*" "$lib" moveToOutput "lib/lib*.la" "$lib" - ln -s lib "$lib/lib64" # for *.la + if [ -d "$lib/lib" ]; then + ln -s lib "$lib/lib64" # for *.la + fi moveToOutput "share/gcc-*/python" "$lib" for i in "$lib"/lib/*.{la,py}; do From aa711c58bf0c4362c0070b267c0f019380fc2c2c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Mon, 18 Apr 2016 11:51:43 +0200 Subject: [PATCH 005/147] mesa: maintenance update 11.1.2 -> 11.1.3 There's also 11.2.1, but I don't have time to test ATM, and such a change might be risky without any testing. --- pkgs/development/libraries/mesa/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/mesa/default.nix b/pkgs/development/libraries/mesa/default.nix index ad6bf8ba3190..2d05861605a5 100644 --- a/pkgs/development/libraries/mesa/default.nix +++ b/pkgs/development/libraries/mesa/default.nix @@ -23,7 +23,7 @@ else with { inherit (stdenv.lib) optional optionalString; }; let - version = "11.1.2"; + version = "11.1.3"; # this is the default search path for DRI drivers driverLink = "/run/opengl-driver" + optionalString stdenv.isi686 "-32"; in @@ -38,7 +38,7 @@ stdenv.mkDerivation { + head (splitString "." version) + ''.x/${version}/mesa-${version}.tar.xz'') "https://launchpad.net/mesa/trunk/${version}/+download/mesa-${version}.tar.xz" ]; - sha256 = "8f72aead896b340ba0f7a4a474bfaf71681f5d675592aec1cb7ba698e319148b"; + sha256 = "51f6658a214d75e4d9f05207586d7ed56ebba75c6b10841176fb6675efa310ac"; }; prePatch = "patchShebangs ."; From a01fdb3ad4761676147df023880f77de52d60b94 Mon Sep 17 00:00:00 2001 From: Aneesh Agrawal Date: Tue, 19 Apr 2016 12:43:20 -0400 Subject: [PATCH 006/147] gzip: 1.6 -> 1.7 (close #14828) --- pkgs/tools/compression/gzip/default.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pkgs/tools/compression/gzip/default.nix b/pkgs/tools/compression/gzip/default.nix index 009246b69a08..cf09ec8bf739 100644 --- a/pkgs/tools/compression/gzip/default.nix +++ b/pkgs/tools/compression/gzip/default.nix @@ -1,11 +1,12 @@ { stdenv, fetchurl, xz }: stdenv.mkDerivation rec { - name = "gzip-1.6"; + name = "gzip-${version}"; + version = "1.7"; src = fetchurl { url = "mirror://gnu/gzip/${name}.tar.xz"; - sha256 = "0ivqnbhiwd12q8hp3qw6rpsrpw2jg5y2mymk8cn22lsx90dfvprp"; + sha256 = "1as1ddq58spflzz5kxm0ni0xfpswrkkrncjpxyb3aw77gizcacgv"; }; outputs = [ "out" "man" "info" ]; @@ -22,7 +23,7 @@ stdenv.mkDerivation rec { makeFlags = "SHELL=/bin/sh GREP=grep"; meta = { - homepage = http://www.gnu.org/software/gzip/; + homepage = https://www.gnu.org/software/gzip/; description = "GNU zip compression program"; longDescription = From c9fe0d779c7ad11d327df0764bcf96326f43610a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Tue, 19 Apr 2016 14:45:46 +0200 Subject: [PATCH 007/147] libjpeg(-turbo): drop unneeded autoreconf, fix cross --- pkgs/development/libraries/libjpeg-turbo/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/libjpeg-turbo/default.nix b/pkgs/development/libraries/libjpeg-turbo/default.nix index 79cf45a8005f..da4d3a9822f2 100644 --- a/pkgs/development/libraries/libjpeg-turbo/default.nix +++ b/pkgs/development/libraries/libjpeg-turbo/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, nasm, autoreconfHook }: +{ stdenv, fetchurl, nasm }: stdenv.mkDerivation rec { name = "libjpeg-turbo-1.4.2"; @@ -10,7 +10,7 @@ stdenv.mkDerivation rec { outputs = [ "dev" "out" "doc" "bin" ]; - buildInputs = [ autoreconfHook nasm ]; + nativeBuildInputs = [ nasm ]; enableParallelBuilding = true; From 7629cd6b34c5aac801655e2b021aa7007ea15045 Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Sun, 3 Apr 2016 08:06:27 +0200 Subject: [PATCH 008/147] libsigcxx: 2.6.2 -> 2.8.0 --- pkgs/development/libraries/libsigcxx/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/libsigcxx/default.nix b/pkgs/development/libraries/libsigcxx/default.nix index 1171fa079cf6..e062e2db5c29 100644 --- a/pkgs/development/libraries/libsigcxx/default.nix +++ b/pkgs/development/libraries/libsigcxx/default.nix @@ -1,14 +1,14 @@ { stdenv, fetchurl, fetchpatch, pkgconfig, gnum4 }: let - ver_maj = "2.6"; # odd major numbers are unstable - ver_min = "2"; + ver_maj = "2.8"; # odd major numbers are unstable + ver_min = "0"; in stdenv.mkDerivation rec { name = "libsigc++-${ver_maj}.${ver_min}"; src = fetchurl { url = "mirror://gnome/sources/libsigc++/${ver_maj}/${name}.tar.xz"; - sha256 = "fdace7134c31de792c17570f9049ca0657909b28c4c70ec4882f91a03de54437"; + sha256 = "0lcnzzdq6718znfshs1hflpwqq6awbzwdyp4kv5lfaf54z880jbp"; }; patches = [(fetchpatch { url = "https://anonscm.debian.org/cgit/collab-maint/libsigc++-2.0.git/plain" From 9c8148dbab84527ff6fec76345487f4c73b521a0 Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Tue, 29 Mar 2016 19:51:18 +0200 Subject: [PATCH 009/147] glib: 2.46.1 -> 2.48.0 --- pkgs/development/libraries/glib/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/glib/default.nix b/pkgs/development/libraries/glib/default.nix index 120d398bd44d..b3b9dfcef161 100644 --- a/pkgs/development/libraries/glib/default.nix +++ b/pkgs/development/libraries/glib/default.nix @@ -39,8 +39,8 @@ let ln -sr -t "''${!outputInclude}/include/" "''${!outputInclude}"/lib/*/include/* 2>/dev/null || true ''; - ver_maj = "2.46"; - ver_min = "2"; + ver_maj = "2.48"; + ver_min = "0"; in stdenv.mkDerivation rec { @@ -48,7 +48,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "mirror://gnome/sources/glib/${ver_maj}/${name}.tar.xz"; - sha256 = "5031722e37036719c1a09163cc6cf7c326e4c4f1f1e074b433c156862bd733db"; + sha256 = "0d3w2hblrw7vvpx60l1kbvb830ygn3v8zhwdz65cc5593j9ycjvl"; }; patches = optional stdenv.isDarwin ./darwin-compilation.patch ++ optional doCheck ./skip-timer-test.patch; From 39af1c76e12222ddf365cd3380ff36e7fc013e51 Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Thu, 31 Mar 2016 07:25:44 +0200 Subject: [PATCH 010/147] gobject-introspection: 1.46.0 -> 1.48.0 --- pkgs/development/libraries/gobject-introspection/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/gobject-introspection/default.nix b/pkgs/development/libraries/gobject-introspection/default.nix index 47ccb17e4845..55abb21845b9 100644 --- a/pkgs/development/libraries/gobject-introspection/default.nix +++ b/pkgs/development/libraries/gobject-introspection/default.nix @@ -7,7 +7,7 @@ # In that case its about 6MB which could be separated let - ver_maj = "1.46"; + ver_maj = "1.48"; ver_min = "0"; in with stdenv.lib; @@ -16,7 +16,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "mirror://gnome/sources/gobject-introspection/${ver_maj}/${name}.tar.xz"; - sha256 = "6658bd3c2b8813eb3e2511ee153238d09ace9d309e4574af27443d87423e4233"; + sha256 = "0xsqwxhfqzr79av89mg766kxpb2i41bd0vwspk01xjdzrnn5l9zs"; }; outputs = [ "dev" "out" ]; From 4d968dd416c9e5125a905a4360e317626e7ac96d Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Sun, 3 Apr 2016 07:28:15 +0200 Subject: [PATCH 011/147] pygobject: 3.18.2 -> 3.20.0 --- pkgs/development/python-modules/pygobject/3.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/pygobject/3.nix b/pkgs/development/python-modules/pygobject/3.nix index b8082890299b..6a58550e7c58 100644 --- a/pkgs/development/python-modules/pygobject/3.nix +++ b/pkgs/development/python-modules/pygobject/3.nix @@ -1,11 +1,13 @@ { stdenv, fetchurl, python, pkgconfig, glib, gobjectIntrospection, pycairo, cairo }: stdenv.mkDerivation rec { - name = "pygobject-3.18.2"; + major = "3.20"; + minor = "0"; + name = "pygobject-${major}.${minor}"; src = fetchurl { - url = "mirror://gnome/sources/pygobject/3.18/${name}.tar.xz"; - sha256 = "0prc3ky7g50ixmfxbc7zf43fw6in4hw2q07667hp8swi2wassg1a"; + url = "mirror://gnome/sources/pygobject/${major}/${name}.tar.xz"; + sha256 = "0ikzh3l7g1gjh8jj8vg6mdvrb25svp63gxcam4m0i404yh0lgari"; }; buildInputs = [ python pkgconfig glib gobjectIntrospection ]; From 3e3a24e2c688a8e0015caa595193de18ff22499d Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Wed, 30 Mar 2016 17:28:08 +0200 Subject: [PATCH 012/147] json-glib: 1.0.2 -> 1.2.0 --- pkgs/development/libraries/json-glib/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/json-glib/default.nix b/pkgs/development/libraries/json-glib/default.nix index e49063a9de91..5cfafc8e69ae 100644 --- a/pkgs/development/libraries/json-glib/default.nix +++ b/pkgs/development/libraries/json-glib/default.nix @@ -1,12 +1,12 @@ { stdenv, fetchurl, glib, pkgconfig, gobjectIntrospection, dbus }: stdenv.mkDerivation rec { - name = "json-glib-${minVer}.2"; - minVer = "1.0"; + name = "json-glib-${minVer}.0"; + minVer = "1.2"; src = fetchurl { url = "mirror://gnome/sources/json-glib/${minVer}/${name}.tar.xz"; - sha256 = "887bd192da8f5edc53b490ec51bf3ffebd958a671f5963e4f3af32c22e35660a"; + sha256 = "1lx7p1c7cl21byvfgw92n8dhm09vi6qxrs0zkx9dg3y096zdzmlr"; }; configureflags= "--with-introspection"; From 386597c132ef953b6803f44feb5384a73686ab8d Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Wed, 30 Mar 2016 11:14:02 +0200 Subject: [PATCH 013/147] gdk-pixbuf: 2.32.3 -> 2.34.0 --- pkgs/development/libraries/gdk-pixbuf/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/gdk-pixbuf/default.nix b/pkgs/development/libraries/gdk-pixbuf/default.nix index 756ebf816199..1487d92dada0 100644 --- a/pkgs/development/libraries/gdk-pixbuf/default.nix +++ b/pkgs/development/libraries/gdk-pixbuf/default.nix @@ -2,15 +2,15 @@ , jasper, libintlOrEmpty, gobjectIntrospection, doCheck ? false }: let - ver_maj = "2.32"; - ver_min = "3"; + ver_maj = "2.34"; + ver_min = "0"; in stdenv.mkDerivation rec { name = "gdk-pixbuf-${ver_maj}.${ver_min}"; src = fetchurl { url = "mirror://gnome/sources/gdk-pixbuf/${ver_maj}/${name}.tar.xz"; - sha256 = "0cfh87aqyqbfcwpbv1ihgmgfcn66il5q2n8yjyl8gxkjmkqp2rrb"; + sha256 = "0yc8indbl3hf18z6x6kjg59xp9sngm1d8vmz4c7bs6g27qw5npnm"; }; outputs = [ "dev" "out" "docdev" ]; From 325cfb219280bb9f6a5be39290750775572156fd Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Tue, 29 Mar 2016 10:37:39 +0200 Subject: [PATCH 014/147] gtk3: 3.18.5 -> 3.20.0 --- pkgs/development/libraries/gtk+/3.x.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/gtk+/3.x.nix b/pkgs/development/libraries/gtk+/3.x.nix index a2da4c7b0339..a8b0118567a0 100644 --- a/pkgs/development/libraries/gtk+/3.x.nix +++ b/pkgs/development/libraries/gtk+/3.x.nix @@ -11,8 +11,8 @@ assert cupsSupport -> cups != null; with stdenv.lib; let - ver_maj = "3.18"; - ver_min = "5"; + ver_maj = "3.20"; + ver_min = "0"; version = "${ver_maj}.${ver_min}"; in stdenv.mkDerivation rec { @@ -20,7 +20,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "mirror://gnome/sources/gtk+/${ver_maj}/gtk+-${version}.tar.xz"; - sha256 = "107aeb9a4244ce3c044becdd6dffc32d83202595181597180d4c736302a71852"; + sha256 = "00yqlqxzhpizdbg71g3gqlgch9gsp36ln1ybdiiwi7lmdr53lg8w"; }; outputs = [ "dev" "out" ]; From 972fd22fe4dc38ee3a0bc1658b1f8dd366df3a20 Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Wed, 30 Mar 2016 16:33:16 +0200 Subject: [PATCH 015/147] cantarell-fonts: 0.0.17 -> 0.0.24 --- pkgs/data/fonts/cantarell-fonts/default.nix | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/pkgs/data/fonts/cantarell-fonts/default.nix b/pkgs/data/fonts/cantarell-fonts/default.nix index 34434f601720..65df7fc1f95a 100644 --- a/pkgs/data/fonts/cantarell-fonts/default.nix +++ b/pkgs/data/fonts/cantarell-fonts/default.nix @@ -1,11 +1,13 @@ { stdenv, fetchurl }: -stdenv.mkDerivation { - name = "cantarell-fonts-0.0.17"; +stdenv.mkDerivation rec { + major = "0.0"; + minor = "24"; + name = "cantarell-fonts-${major}.${minor}"; src = fetchurl { - url = mirror://gnome/sources/cantarell-fonts/0.0/cantarell-fonts-0.0.17.tar.xz; - sha256 = "0kx05fw1i11zcqx5yv9y9iprpl49k51sibz86bc58a50n1w6gcwn"; + url = "mirror://gnome/sources/cantarell-fonts/${major}/${name}.tar.xz"; + sha256 = "0r4jnc2x9yncf40lixjb1pqgpq8rzbi2fz33pshlqzjgx2d69bcw"; }; meta = { From d30a9fd186e3d191a0164c932c90317d1f3e015b Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Sat, 2 Apr 2016 12:15:19 +0200 Subject: [PATCH 016/147] telepathy-glib: 0.24.0 -> 0.24.1 --- pkgs/development/libraries/telepathy/glib/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/telepathy/glib/default.nix b/pkgs/development/libraries/telepathy/glib/default.nix index 9167ecc76d4a..bb187ce1202b 100644 --- a/pkgs/development/libraries/telepathy/glib/default.nix +++ b/pkgs/development/libraries/telepathy/glib/default.nix @@ -2,11 +2,11 @@ , gobjectIntrospection, valaSupport ? true, vala }: stdenv.mkDerivation rec { - name = "telepathy-glib-0.24.0"; + name = "telepathy-glib-0.24.1"; src = fetchurl { url = "${meta.homepage}/releases/telepathy-glib/${name}.tar.gz"; - sha256 = "ae0002134991217f42e503c43dea7817853afc18863b913744d51ffa029818cf"; + sha256 = "1symyzbjmxvksn2ifdkk50lafjm2llf2sbmky062gq2pz3cg23cy"; }; configureFlags = stdenv.lib.optional valaSupport "--enable-vala-bindings"; From 914e193dba94a8e3d65a46c53b0874398b7a205d Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Sat, 2 Apr 2016 08:27:23 +0200 Subject: [PATCH 017/147] gegl: 0.3.0-20140619 -> 0.3.6 --- pkgs/development/libraries/gegl/3.0.nix | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/pkgs/development/libraries/gegl/3.0.nix b/pkgs/development/libraries/gegl/3.0.nix index 575e2d562aad..1ca0a2b59257 100644 --- a/pkgs/development/libraries/gegl/3.0.nix +++ b/pkgs/development/libraries/gegl/3.0.nix @@ -1,13 +1,12 @@ -{ stdenv, fetchgit, pkgconfig, glib, babl, libpng, cairo, libjpeg, which +{ stdenv, fetchurl, pkgconfig, glib, babl, libpng, cairo, libjpeg, which , librsvg, pango, gtk, bzip2, intltool, libtool, automake, autoconf, json_glib }: stdenv.mkDerivation rec { - name = "gegl-0.3.0-20140619"; + name = "gegl-0.3.6"; - src = fetchgit { - url = "https://git.gnome.org/browse/gegl"; - sha256 = "1rjmv2y7z34zrnlqczmmh0bm724iszzdf6jpibszxnp3w0npwjrb"; - rev = "0014eb1bad50244314ed09592fe57efa9322678c"; + src = fetchurl { + url = "http://download.gimp.org/pub/gegl/0.3/${name}.tar.bz2"; + sha256 = "08m7dlf2kwmp7jw3qskwxas192swhn1g4jcd8aldg9drfjygprvh"; }; configureScript = "./autogen.sh"; From 802f830b2af18feb8cebe0c71323dadb5e407829 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Tue, 19 Apr 2016 15:07:54 +0200 Subject: [PATCH 018/147] gtk3: maintenance update 3.20.0 -> 3.20.3 --- pkgs/development/libraries/gtk+/3.x.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/gtk+/3.x.nix b/pkgs/development/libraries/gtk+/3.x.nix index a8b0118567a0..dcbf0b4a47c1 100644 --- a/pkgs/development/libraries/gtk+/3.x.nix +++ b/pkgs/development/libraries/gtk+/3.x.nix @@ -12,7 +12,7 @@ with stdenv.lib; let ver_maj = "3.20"; - ver_min = "0"; + ver_min = "3"; version = "${ver_maj}.${ver_min}"; in stdenv.mkDerivation rec { @@ -20,7 +20,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "mirror://gnome/sources/gtk+/${ver_maj}/gtk+-${version}.tar.xz"; - sha256 = "00yqlqxzhpizdbg71g3gqlgch9gsp36ln1ybdiiwi7lmdr53lg8w"; + sha256 = "3834f3bf23b260b3e5ebfea41102e2026a8af29e36c3620edf4a5cf05e82f694"; }; outputs = [ "dev" "out" ]; From afe5a05c930eeba53cc7f2595bebddb4c05ac876 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Mon, 11 Apr 2016 08:26:50 -0500 Subject: [PATCH 019/147] kde5.kinit: get library path from NIX_PROFILES --- .../kinit/0001-kinit-libpath.patch | 42 ------------------- .../kde-5/frameworks-5.19/kinit/default.nix | 4 +- .../frameworks-5.19/kinit/kinit-libpath.patch | 31 ++++++++++++++ .../kde-5/frameworks-5.19/kinit/series | 1 + 4 files changed, 34 insertions(+), 44 deletions(-) delete mode 100644 pkgs/desktops/kde-5/frameworks-5.19/kinit/0001-kinit-libpath.patch create mode 100644 pkgs/desktops/kde-5/frameworks-5.19/kinit/kinit-libpath.patch create mode 100644 pkgs/desktops/kde-5/frameworks-5.19/kinit/series diff --git a/pkgs/desktops/kde-5/frameworks-5.19/kinit/0001-kinit-libpath.patch b/pkgs/desktops/kde-5/frameworks-5.19/kinit/0001-kinit-libpath.patch deleted file mode 100644 index 9c76079a382a..000000000000 --- a/pkgs/desktops/kde-5/frameworks-5.19/kinit/0001-kinit-libpath.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 723c9b1268a04127647a1c20eebe9804150566dd Mon Sep 17 00:00:00 2001 -From: Thomas Tuegel -Date: Sat, 13 Jun 2015 08:57:55 -0500 -Subject: [PATCH] kinit libpath - ---- - src/kdeinit/kinit.cpp | 18 ++++++++++-------- - 1 file changed, 10 insertions(+), 8 deletions(-) - -diff --git a/src/kdeinit/kinit.cpp b/src/kdeinit/kinit.cpp -index 9e775b6..0ac5646 100644 ---- a/src/kdeinit/kinit.cpp -+++ b/src/kdeinit/kinit.cpp -@@ -660,15 +660,17 @@ static pid_t launch(int argc, const char *_name, const char *args, - if (!libpath.isEmpty()) { - if (!l.load()) { - if (libpath_relative) { -- // NB: Because Qt makes the actual dlopen() call, the -- // RUNPATH of kdeinit is *not* respected - see -- // https://sourceware.org/bugzilla/show_bug.cgi?id=13945 -- // - so we try hacking it in ourselves -- QString install_lib_dir = QFile::decodeName( -- CMAKE_INSTALL_PREFIX "/" LIB_INSTALL_DIR "/"); -- libpath = install_lib_dir + libpath; -- l.setFileName(libpath); -+ // Use QT_PLUGIN_PATH to find shared library directories -+ // For KF5, the plugin path is /lib/qt5/plugins/, so kdeinit5 -+ // shared libraries should be in /lib/qt5/plugins/../../ -+ const QRegExp pathSepRegExp(QString::fromLatin1("[:\b]")); -+ const QString up = QString::fromLocal8Bit("/../../"); -+ const QStringList paths = QString::fromLocal8Bit(qgetenv("QT_PLUGIN_PATH")).split(pathSepRegExp, QString::KeepEmptyParts); -+ Q_FOREACH (const QString &path, paths) { -+ l.setFileName(path + up + libpath); - l.load(); -+ if (l.isLoaded()) break; -+ } - } - } - if (!l.isLoaded()) { --- -2.4.2 - diff --git a/pkgs/desktops/kde-5/frameworks-5.19/kinit/default.nix b/pkgs/desktops/kde-5/frameworks-5.19/kinit/default.nix index 5f644d7c424e..64210ca76051 100644 --- a/pkgs/desktops/kde-5/frameworks-5.19/kinit/default.nix +++ b/pkgs/desktops/kde-5/frameworks-5.19/kinit/default.nix @@ -1,4 +1,4 @@ -{ kdeFramework, lib, extra-cmake-modules, kconfig, kcrash +{ kdeFramework, lib, copyPathsToStore, extra-cmake-modules, kconfig, kcrash , kdoctools, ki18n, kio, kservice, kwindowsystem, libcap , libcap_progs }: @@ -10,7 +10,7 @@ kdeFramework { nativeBuildInputs = [ extra-cmake-modules kdoctools libcap_progs ]; buildInputs = [ kconfig kcrash kservice libcap ]; propagatedBuildInputs = [ ki18n kio kwindowsystem ]; - patches = [ ./0001-kinit-libpath.patch ]; + patches = copyPathsToStore (lib.readPathsFromFile ./. ./series); meta = { maintainers = [ lib.maintainers.ttuegel ]; }; diff --git a/pkgs/desktops/kde-5/frameworks-5.19/kinit/kinit-libpath.patch b/pkgs/desktops/kde-5/frameworks-5.19/kinit/kinit-libpath.patch new file mode 100644 index 000000000000..52c5563ea581 --- /dev/null +++ b/pkgs/desktops/kde-5/frameworks-5.19/kinit/kinit-libpath.patch @@ -0,0 +1,31 @@ +Index: kinit-5.19.0/src/kdeinit/kinit.cpp +=================================================================== +--- kinit-5.19.0.orig/src/kdeinit/kinit.cpp ++++ kinit-5.19.0/src/kdeinit/kinit.cpp +@@ -658,15 +658,17 @@ static pid_t launch(int argc, const char + if (!libpath.isEmpty()) { + if (!l.load()) { + if (libpath_relative) { +- // NB: Because Qt makes the actual dlopen() call, the +- // RUNPATH of kdeinit is *not* respected - see +- // https://sourceware.org/bugzilla/show_bug.cgi?id=13945 +- // - so we try hacking it in ourselves +- QString install_lib_dir = QFile::decodeName( +- CMAKE_INSTALL_PREFIX "/" LIB_INSTALL_DIR "/"); +- libpath = install_lib_dir + libpath; +- l.setFileName(libpath); +- l.load(); ++ // Try to load the library relative to the active profiles. ++ QByteArrayList profiles = qgetenv("NIX_PROFILES").split(' '); ++ // Reverse the profile list. ++ std::reverse(profiles.begin(), profiles.end()); ++ const QString libdir = QString::fromLatin1("/lib/"); ++ Q_FOREACH (const QByteArray &profile, profiles) { ++ if (!profile.isEmpty()) { ++ l.setFileName(QFile::decodeName(profile) + libdir + libpath); ++ if (l.load()) break; ++ } ++ } + } + } + if (!l.isLoaded()) { diff --git a/pkgs/desktops/kde-5/frameworks-5.19/kinit/series b/pkgs/desktops/kde-5/frameworks-5.19/kinit/series new file mode 100644 index 000000000000..5faa456366b9 --- /dev/null +++ b/pkgs/desktops/kde-5/frameworks-5.19/kinit/series @@ -0,0 +1 @@ +kinit-libpath.patch From 468d0bc56a8510f84969c0306d927ae0d7813782 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Mon, 11 Apr 2016 10:17:13 -0500 Subject: [PATCH 020/147] kde5.plasma-workspace: unwrap --- .../plasma-5.5/plasma-workspace/default.nix | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix b/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix index 01c5c63ce0aa..30bd264ddcd0 100644 --- a/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix +++ b/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix @@ -65,20 +65,4 @@ plasmaPackage { rm "$out/lib/libexec/startplasma" rm -r "$out/share/wayland-sessions" ''; - - postFixup = '' - wrapQtProgram "$out/bin/ksmserver" - wrapQtProgram "$out/bin/plasmawindowed" - wrapQtProgram "$out/bin/kcminit_startup" - wrapQtProgram "$out/bin/ksplashqml" - wrapQtProgram "$out/bin/kcheckrunning" - wrapQtProgram "$out/bin/systemmonitor" - wrapQtProgram "$out/bin/kstartupconfig5" - wrapQtProgram "$out/bin/kdostartupconfig5" - wrapQtProgram "$out/bin/klipper" - wrapQtProgram "$out/bin/kuiserver5" - wrapQtProgram "$out/bin/krunner" - wrapQtProgram "$out/bin/plasmashell" - wrapQtProgram "$out/lib/libexec/drkonqi" - ''; } From 2780894b1bf8d9541ad024fdbb8694e887ddd649 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Thu, 14 Apr 2016 16:34:45 -0500 Subject: [PATCH 021/147] kde5.startkde: init at 5.5.5 --- .../services/x11/desktop-managers/kde5.nix | 24 +- pkgs/desktops/kde-5/plasma-5.5/default.nix | 1 + .../plasma-5.5/plasma-workspace/default.nix | 29 +- .../kde-5/plasma-5.5/plasma-workspace/series | 1 - .../kde-5/plasma-5.5/startkde/default.nix | 35 ++ .../kde-5/plasma-5.5/startkde/startkde.sh | 337 ++++++++++++++++++ 6 files changed, 392 insertions(+), 35 deletions(-) create mode 100644 pkgs/desktops/kde-5/plasma-5.5/startkde/default.nix create mode 100755 pkgs/desktops/kde-5/plasma-5.5/startkde/startkde.sh diff --git a/nixos/modules/services/x11/desktop-managers/kde5.nix b/nixos/modules/services/x11/desktop-managers/kde5.nix index 4f74d5732af5..70dc1ac2a26a 100644 --- a/nixos/modules/services/x11/desktop-managers/kde5.nix +++ b/nixos/modules/services/x11/desktop-managers/kde5.nix @@ -62,17 +62,25 @@ in ${config.hardware.pulseaudio.package}/bin/pactl load-module module-device-manager "do_routing=1" ''} - exec startkde + exec "${kde5.startkde}" + ''; }; - security.setuidOwners = singleton { - program = "kcheckpass"; - source = "${kde5.plasma-workspace.out}/lib/libexec/kcheckpass"; - owner = "root"; - group = "root"; - setuid = true; - }; + security.setuidOwners = [ + { + program = "kcheckpass"; + source = "${kde5.plasma-workspace}/lib/libexec/kcheckpass"; + owner = "root"; + setuid = true; + } + { + program = "start_kdeinit_wrapper"; + source = "${kde5.plasma-workspace}/lib/libexec/kf5/start_kdeinit_wrapper"; + owner = "root"; + setuid = true; + } + ]; environment.systemPackages = [ diff --git a/pkgs/desktops/kde-5/plasma-5.5/default.nix b/pkgs/desktops/kde-5/plasma-5.5/default.nix index 384fa6f6d272..a4f5c7c23204 100644 --- a/pkgs/desktops/kde-5/plasma-5.5/default.nix +++ b/pkgs/desktops/kde-5/plasma-5.5/default.nix @@ -81,6 +81,7 @@ let plasma-workspace-wallpapers = callPackage ./plasma-workspace-wallpapers.nix {}; polkit-kde-agent = callPackage ./polkit-kde-agent.nix {}; powerdevil = callPackage ./powerdevil.nix {}; + startkde = callPackage ./startkde {}; systemsettings = callPackage ./systemsettings.nix {}; }; diff --git a/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix b/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix index 30bd264ddcd0..1d67761d2444 100644 --- a/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix +++ b/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix @@ -1,14 +1,12 @@ { plasmaPackage, lib, copyPathsToStore -, extra-cmake-modules, kdoctools, makeQtWrapper +, extra-cmake-modules, kdoctools , baloo, kactivities, kcmutils, kcrash, kdbusaddons, kdeclarative , kdelibs4support, kdesu, kdewebkit, kglobalaccel, kidletime , kjsembed, knewstuff, knotifyconfig, kpackage, krunner , ktexteditor, ktextwidgets, kwallet, kwayland, kwin, kxmlrpcclient , libdbusmenu, libkscreen, libSM, libXcursor, networkmanager-qt , pam, phonon, plasma-framework, qtquick1, qtscript, qtx11extras, wayland -, libksysguard, bash, coreutils, gnused, gnugrep, socat, kconfig -, kinit, kservice, qttools, dbus_tools, mkfontdir, xmessage -, xprop, xrdb, xset, xsetroot, solid, qtquickcontrols +, libksysguard, kconfig, solid, qtquickcontrols }: plasmaPackage { @@ -17,7 +15,6 @@ plasmaPackage { nativeBuildInputs = [ extra-cmake-modules kdoctools - makeQtWrapper ]; buildInputs = [ dbus_tools kcmutils kconfig kcrash kdbusaddons kdesu kdewebkit @@ -35,32 +32,12 @@ plasmaPackage { patches = copyPathsToStore (lib.readPathsFromFile ./. ./series); postPatch = '' - substituteInPlace startkde/startkde.cmake \ - --subst-var-by bash $(type -P bash) \ - --subst-var-by sed $(type -P sed) \ - --subst-var-by grep $(type -P grep) \ - --subst-var-by socat $(type -P socat) \ - --subst-var-by kcheckrunning $(type -P kcheckrunning) \ - --subst-var-by xmessage $(type -P xmessage) \ - --subst-var-by tr $(type -P tr) \ - --subst-var-by qtpaths $(type -P qtpaths) \ - --subst-var-by qdbus $(type -P qdbus) \ - --subst-var-by dbus-launch $(type -P dbus-launch) \ - --subst-var-by mkfontdir $(type -P mkfontdir) \ - --subst-var-by xset $(type -P xset) \ - --subst-var-by xsetroot $(type -P xsetroot) \ - --subst-var-by xprop $(type -P xprop) \ - --subst-var-by start_kdeinit_wrapper "${kinit.out}/lib/libexec/kf5/start_kdeinit_wrapper" \ - --subst-var-by kwrapper5 $(type -P kwrapper5) \ - --subst-var-by kdeinit5_shutdown $(type -P kdeinit5_shutdown) \ - --subst-var-by kbuildsycoca5 $(type -P kbuildsycoca5) \ - --subst-var-by kreadconfig5 $(type -P kreadconfig5) \ - --subst-var out substituteInPlace startkde/kstartupconfig/kstartupconfig.cpp \ --replace kdostartupconfig5 $out/bin/kdostartupconfig5 ''; postInstall = '' + rm "$out/bin/startkde" rm "$out/bin/startplasmacompositor" rm "$out/lib/libexec/startplasma" rm -r "$out/share/wayland-sessions" diff --git a/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/series b/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/series index 88b54af793e7..b9081298bd69 100644 --- a/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/series +++ b/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/series @@ -1,2 +1 @@ -startkde.patch qml-import-path.patch diff --git a/pkgs/desktops/kde-5/plasma-5.5/startkde/default.nix b/pkgs/desktops/kde-5/plasma-5.5/startkde/default.nix new file mode 100644 index 000000000000..13e248c0fb7c --- /dev/null +++ b/pkgs/desktops/kde-5/plasma-5.5/startkde/default.nix @@ -0,0 +1,35 @@ +{ stdenv, lib, runCommand +, dbus +, gnugrep, gnused +, kconfig, kinit, kservice +, plasma-workspace +, qttools +, socat +, xmessage, xprop, xsetroot +}: + +let + + env = { + inherit (stdenv) shell; + paths = [ + dbus.tools + gnugrep gnused + kconfig kinit kservice + plasma-workspace + qttools + socat + xmessage xprop xsetroot + ]; + }; + +in runCommand "startkde" env '' + prefix_PATH= + for pkg in $paths; do + addToSearchPath prefix_PATH "$pkg/bin" + addToSearchPath prefix_PATH "$pkg/lib/libexec" + addToSearchPath prefix_PATH "$pkg/lib/libexec/kf5" + done + substitute ${./startkde.sh} "$out" --subst-var shell --subst-var prefix_PATH + chmod +x "$out" +'' diff --git a/pkgs/desktops/kde-5/plasma-5.5/startkde/startkde.sh b/pkgs/desktops/kde-5/plasma-5.5/startkde/startkde.sh new file mode 100755 index 000000000000..be374e7504d9 --- /dev/null +++ b/pkgs/desktops/kde-5/plasma-5.5/startkde/startkde.sh @@ -0,0 +1,337 @@ +#!@shell@ + +PATH="@prefix_PATH@:$PATH" + +export NIX_PROFILES +echo "NIX_PROFILES=$NIX_PROFILES" + +# The KDE icon cache is supposed to update itself +# automatically, but it uses the timestamp on the icon +# theme directory as a trigger. Since in Nix the +# timestamp is always the same, this doesn't work. So as +# a workaround, nuke the icon cache on login. This isn't +# perfect, since it may require logging out after +# installing new applications to update the cache. +# See http://lists-archives.org/kde-devel/26175-what-when-will-icon-cache-refresh.html +rm -fv $HOME/.cache/icon-cache.kcache + +# Qt writes a weird ‘libraryPath’ line to +# ~/.config/Trolltech.conf that causes the KDE plugin +# paths of previous KDE invocations to be searched. +# Obviously using mismatching KDE libraries is potentially +# disastrous, so here we nuke references to the Nix store +# in Trolltech.conf. A better solution would be to stop +# Qt from doing this wackiness in the first place. +if [ -e $HOME/.config/Trolltech.conf ]; then + sed -e '/nix\\store\|nix\/store/ d' -i $HOME/.config/Trolltech.conf +fi + +if test "x$1" = x--failsafe; then + KDE_FAILSAFE=1 # General failsafe flag + KWIN_COMPOSE=N # Disable KWin's compositing + QT_XCB_FORCE_SOFTWARE_OPENGL=1 + export KWIN_COMPOSE KDE_FAILSAFE QT_XCB_FORCE_SOFTWARE_OPENGL +fi + +# When the X server dies we get a HUP signal from xinit. We must ignore it +# because we still need to do some cleanup. +trap 'echo GOT SIGHUP' HUP + +# we have to unset this for Darwin since it will screw up KDE's dynamic-loading +unset DYLD_FORCE_FLAT_NAMESPACE + +# Check if a KDE session already is running and whether it's possible to connect to X +kcheckrunning +kcheckrunning_result=$? +if test $kcheckrunning_result -eq 0 ; then + echo "KDE seems to be already running on this display." + xmessage -geometry 500x100 "KDE seems to be already running on this display." + exit 1 +elif test $kcheckrunning_result -eq 2 ; then + echo "\$DISPLAY is not set or cannot connect to the X server." + exit 1 +fi + +# Boot sequence: +# +# kdeinit is used to fork off processes which improves memory usage +# and startup time. +# +# * kdeinit starts klauncher first. +# * Then kded is started. kded is responsible for keeping the sycoca +# database up to date. When an up to date database is present it goes +# into the background and the startup continues. +# * Then kdeinit starts kcminit. kcminit performs initialisation of +# certain devices according to the user's settings +# +# * Then ksmserver is started which takes control of the rest of the startup sequence + +# We need to create config folder so we can write startupconfigkeys +configDir=$(qtpaths --writable-path GenericConfigLocation) +mkdir -p "$configDir" + +#This is basically setting defaults so we can use them with kstartupconfig5 +cat >$configDir/startupconfigkeys <$plasmalocalerc <$kdeglobalsfile </dev/null 2>/dev/null; then + : # ok +else + echo 'startkde: Could not start D-Bus. Can you call qdbus?' 1>&2 + test -n "$ksplash_pid" && kill "$ksplash_pid" 2>/dev/null + xmessage -geometry 500x100 "Could not start D-Bus. Can you call qdbus?" + exit 1 +fi + +ksplash_pid= +if test -z "$dl"; then + # the splashscreen and progress indicator + case "$ksplashrc_ksplash_engine" in + KSplashQML) + ksplash_pid=$(ksplashqml "${ksplashrc_ksplash_theme}" --pid) + ;; + None) + ;; + *) + ;; + esac +fi + +# Source scripts found in /plasma-workspace/env/*.sh +# (where correspond to the system and user's configuration +# directories, as identified by Qt's qtpaths, e.g. $HOME/.config +# and /etc/xdg/ on Linux) +# +# This is where you can define environment variables that will be available to +# all KDE programs, so this is where you can run agents using e.g. eval `ssh-agent` +# or eval `gpg-agent --daemon`. +# Note: if you do that, you should also put "ssh-agent -k" as a shutdown script +# +# (see end of this file). +# For anything else (that doesn't set env vars, or that needs a window manager), +# better use the Autostart folder. + +IFS=":" read -r -a scriptpath <<< $(qtpaths --paths GenericConfigLocation) +# Add /env/ to the directory to locate the scripts to be sourced +for prefix in "${scriptpath[@]}"; do + for file in "$prefix"/plasma-workspace/env/*.sh; do + test -r "$file" && . "$file" || true + done +done + +echo 'startkde: Starting up...' 1>&2 + +# Mark that full KDE session is running (e.g. Konqueror preloading works only +# with full KDE running). The KDE_FULL_SESSION property can be detected by +# any X client connected to the same X session, even if not launched +# directly from the KDE session but e.g. using "ssh -X", kdesu. $KDE_FULL_SESSION +# however guarantees that the application is launched in the same environment +# like the KDE session and that e.g. KDE utilities/libraries are available. +# KDE_FULL_SESSION property is also only available since KDE 3.5.5. +# The matching tests are: +# For $KDE_FULL_SESSION: +# if test -n "$KDE_FULL_SESSION"; then ... whatever +# For KDE_FULL_SESSION property: +# xprop -root | grep "^KDE_FULL_SESSION" >/dev/null 2>/dev/null +# if test $? -eq 0; then ... whatever +# +# Additionally there is (since KDE 3.5.7) $KDE_SESSION_UID with the uid +# of the user running the KDE session. It should be rarely needed (e.g. +# after sudo to prevent desktop-wide functionality in the new user's kded). +# +# Since KDE4 there is also KDE_SESSION_VERSION, containing the major version number. +# Note that this didn't exist in KDE3, which can be detected by its absense and +# the presence of KDE_FULL_SESSION. +# +KDE_FULL_SESSION=true +export KDE_FULL_SESSION +xprop -root -f KDE_FULL_SESSION 8t -set KDE_FULL_SESSION true + +KDE_SESSION_VERSION=5 +export KDE_SESSION_VERSION +xprop -root -f KDE_SESSION_VERSION 32c -set KDE_SESSION_VERSION 5 + +KDE_SESSION_UID=`id -ru` +export KDE_SESSION_UID + +XDG_CURRENT_DESKTOP=KDE +export XDG_CURRENT_DESKTOP + +# At this point all the environment is ready, let's send it to kwalletd if running +if test -n "$PAM_KWALLET_LOGIN" ; then + env | socat STDIN UNIX-CONNECT:$PAM_KWALLET_LOGIN +fi +# ...and also to kwalletd5 +if test -n "$PAM_KWALLET5_LOGIN" ; then + env | socat STDIN UNIX-CONNECT:$PAM_KWALLET5_LOGIN +fi + +# At this point all environment variables are set, let's send it to the DBus session server to update the activation environment +ksyncdbusenv +if test $? -ne 0; then + # Startup error + echo 'startkde: Could not sync environment to dbus.' 1>&2 + test -n "$ksplash_pid" && kill "$ksplash_pid" 2>/dev/null + xmessage -geometry 500x100 "Could not sync environment to dbus." + exit 1 +fi + +# We set LD_BIND_NOW to increase the efficiency of kdeinit. +# kdeinit unsets this variable before loading applications. +LD_BIND_NOW=true start_kdeinit_wrapper --kded +kcminit_startup +if test $? -ne 0; then + # Startup error + echo 'startkde: Could not start kdeinit5. Check your installation.' 1>&2 + test -n "$ksplash_pid" && kill "$ksplash_pid" 2>/dev/null + xmessage -geometry 500x100 "Could not start kdeinit5. Check your installation." + exit 1 +fi + +# (NixOS) Run kbuildsycoca5 before starting the user session because things +# may be missing or moved if they have run nixos-rebuild and it may not be +# possible for them to start Konsole to run it manually! +kbuildsycoca5 + +# finally, give the session control to the session manager +# see kdebase/ksmserver for the description of the rest of the startup sequence +# if the KDEWM environment variable has been set, then it will be used as KDE's +# window manager instead of kwin. +# if KDEWM is not set, ksmserver will ensure kwin is started. +# kwrapper5 is used to reduce startup time and memory usage +# kwrapper5 does not return useful error codes such as the exit code of ksmserver. +# We only check for 255 which means that the ksmserver process could not be +# started, any problems thereafter, e.g. ksmserver failing to initialize, +# will remain undetected. +test -n "$KDEWM" && KDEWM="--windowmanager $KDEWM" +# If the session should be locked from the start (locked autologin), +# lock now and do the rest of the KDE startup underneath the locker. +KSMSERVEROPTIONS="" +test -n "$dl" && KSMSERVEROPTIONS=" --lockscreen" +kwrapper5 ksmserver $KDEWM $KSMSERVEROPTIONS +if test $? -eq 255; then + # Startup error + echo 'startkde: Could not start ksmserver. Check your installation.' 1>&2 + test -n "$ksplash_pid" && kill "$ksplash_pid" 2>/dev/null + xmessage -geometry 500x100 "Could not start ksmserver. Check your installation." +fi + +wait_drkonqi=$(kreadconfig5 --file startkderc --group WaitForDrKonqi --key Enabled --default true) + +if test x"$wait_drkonqi"x = x"true"x ; then + # wait for remaining drkonqi instances with timeout (in seconds) + wait_drkonqi_timeout=$(kreadconfig5 --file startkderc --group WaitForDrKonqi --key Timeout --default 900) + wait_drkonqi_counter=0 + while qdbus | grep "^[^w]*org.kde.drkonqi" > /dev/null ; do + sleep 5 + wait_drkonqi_counter=$((wait_drkonqi_counter+5)) + if test "$wait_drkonqi_counter" -ge "$wait_drkonqi_timeout" ; then + # ask remaining drkonqis to die in a graceful way + qdbus | grep 'org.kde.drkonqi-' | while read address ; do + qdbus "$address" "/MainApplication" "quit" + done + break + fi + done +fi + +echo 'startkde: Shutting down...' 1>&2 +# just in case +test -n "$ksplash_pid" && kill "$ksplash_pid" 2>/dev/null + +# Clean up +kdeinit5_shutdown + +unset KDE_FULL_SESSION +xprop -root -remove KDE_FULL_SESSION +unset KDE_SESSION_VERSION +xprop -root -remove KDE_SESSION_VERSION +unset KDE_SESSION_UID + +echo 'startkde: Done.' 1>&2 From b3317a020e6c961882cf99da16aa5ac8ffb762e2 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Fri, 15 Apr 2016 06:07:50 -0500 Subject: [PATCH 022/147] nixos/pulseaudio: don't use dev output at runtime --- nixos/modules/config/pulseaudio.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nixos/modules/config/pulseaudio.nix b/nixos/modules/config/pulseaudio.nix index 642aedc3f242..1654d31cfeb4 100644 --- a/nixos/modules/config/pulseaudio.nix +++ b/nixos/modules/config/pulseaudio.nix @@ -98,9 +98,9 @@ in { package = mkOption { type = types.package; - default = pulseaudioLight; - defaultText = "pkgs.pulseaudioLight"; - example = literalExample "pkgs.pulseaudioFull"; + default = pulseaudioLight.out; + defaultText = "pkgs.pulseaudioLight.out"; + example = literalExample "pkgs.pulseaudioFull.out"; description = '' The PulseAudio derivation to use. This can be used to enable features (such as JACK support, Bluetooth) via the From f418bd2dfaa02aa4af6ee3cec64a050edfac2bcf Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Fri, 15 Apr 2016 06:10:12 -0500 Subject: [PATCH 023/147] kde5.startkde: fix PATH --- .../kde-5/plasma-5.5/startkde/default.nix | 21 ++++++++----------- .../kde-5/plasma-5.5/startkde/startkde.sh | 3 --- 2 files changed, 9 insertions(+), 15 deletions(-) diff --git a/pkgs/desktops/kde-5/plasma-5.5/startkde/default.nix b/pkgs/desktops/kde-5/plasma-5.5/startkde/default.nix index 13e248c0fb7c..30e986c21b4b 100644 --- a/pkgs/desktops/kde-5/plasma-5.5/startkde/default.nix +++ b/pkgs/desktops/kde-5/plasma-5.5/startkde/default.nix @@ -1,10 +1,8 @@ { stdenv, lib, runCommand -, dbus +, dbus, qttools, socat , gnugrep, gnused , kconfig, kinit, kservice , plasma-workspace -, qttools -, socat , xmessage, xprop, xsetroot }: @@ -12,15 +10,14 @@ let env = { inherit (stdenv) shell; - paths = [ - dbus.tools - gnugrep gnused - kconfig kinit kservice - plasma-workspace - qttools - socat - xmessage xprop xsetroot - ]; + paths = builtins.map (pkg: pkg.out or pkg) + [ + dbus qttools socat + gnugrep gnused + kconfig kinit kservice + plasma-workspace + xmessage xprop xsetroot + ]; }; in runCommand "startkde" env '' diff --git a/pkgs/desktops/kde-5/plasma-5.5/startkde/startkde.sh b/pkgs/desktops/kde-5/plasma-5.5/startkde/startkde.sh index be374e7504d9..d839226a4562 100755 --- a/pkgs/desktops/kde-5/plasma-5.5/startkde/startkde.sh +++ b/pkgs/desktops/kde-5/plasma-5.5/startkde/startkde.sh @@ -2,9 +2,6 @@ PATH="@prefix_PATH@:$PATH" -export NIX_PROFILES -echo "NIX_PROFILES=$NIX_PROFILES" - # The KDE icon cache is supposed to update itself # automatically, but it uses the timestamp on the icon # theme directory as a trigger. Since in Nix the From 3d05424dc2db687b2e5edf07b09aa037b9507f84 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Fri, 15 Apr 2016 06:10:26 -0500 Subject: [PATCH 024/147] kde5.plasma-workspace: fix up dependencies --- .../kde-5/plasma-5.5/plasma-workspace/default.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix b/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix index 1d67761d2444..1a96c1eced2e 100644 --- a/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix +++ b/pkgs/desktops/kde-5/plasma-5.5/plasma-workspace/default.nix @@ -17,11 +17,11 @@ plasmaPackage { kdoctools ]; buildInputs = [ - dbus_tools kcmutils kconfig kcrash kdbusaddons kdesu kdewebkit - kinit kjsembed knewstuff knotifyconfig kpackage kservice + kcmutils kconfig kcrash kdbusaddons kdesu kdewebkit + kjsembed knewstuff knotifyconfig kpackage ktextwidgets kwallet kwayland kxmlrpcclient libdbusmenu libSM - libXcursor mkfontdir networkmanager-qt pam phonon qtscript qttools - socat wayland xmessage xprop xset xsetroot + libXcursor networkmanager-qt pam phonon qtscript + wayland ]; propagatedBuildInputs = [ baloo kactivities kdeclarative kdelibs4support kglobalaccel From e6c91d586cd2ea5e5d3c7180fddd8e2992f1c2fa Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Fri, 15 Apr 2016 06:22:54 -0500 Subject: [PATCH 025/147] qt55.qtbase: debug NIX_PROFILES paths --- .../libraries/qt-5/5.5/qtbase/debug-nix-profiles-paths.patch | 0 pkgs/development/libraries/qt-5/5.5/qtbase/series | 1 + 2 files changed, 1 insertion(+) create mode 100644 pkgs/development/libraries/qt-5/5.5/qtbase/debug-nix-profiles-paths.patch diff --git a/pkgs/development/libraries/qt-5/5.5/qtbase/debug-nix-profiles-paths.patch b/pkgs/development/libraries/qt-5/5.5/qtbase/debug-nix-profiles-paths.patch new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/pkgs/development/libraries/qt-5/5.5/qtbase/series b/pkgs/development/libraries/qt-5/5.5/qtbase/series index 2196d8383752..fbe309909049 100644 --- a/pkgs/development/libraries/qt-5/5.5/qtbase/series +++ b/pkgs/development/libraries/qt-5/5.5/qtbase/series @@ -7,3 +7,4 @@ xdg-config-dirs.patch nix-profiles-library-paths.patch compose-search-path.patch libressl.patch +debug-nix-profiles-paths.patch From e0a87ce931e69f2775d99de12986f1e6b5ea70aa Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Fri, 15 Apr 2016 06:57:06 -0500 Subject: [PATCH 026/147] qt55.qtdeclarative: get import paths from NIX_PROFILES --- .../nix-profiles-import-paths.patch | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/pkgs/development/libraries/qt-5/5.5/qtdeclarative/nix-profiles-import-paths.patch b/pkgs/development/libraries/qt-5/5.5/qtdeclarative/nix-profiles-import-paths.patch index e69de29bb2d1..06b244b974ff 100644 --- a/pkgs/development/libraries/qt-5/5.5/qtdeclarative/nix-profiles-import-paths.patch +++ b/pkgs/development/libraries/qt-5/5.5/qtdeclarative/nix-profiles-import-paths.patch @@ -0,0 +1,20 @@ +Index: qtdeclarative-opensource-src-5.5.1/src/qml/qml/qqmlimport.cpp +=================================================================== +--- qtdeclarative-opensource-src-5.5.1.orig/src/qml/qml/qqmlimport.cpp ++++ qtdeclarative-opensource-src-5.5.1/src/qml/qml/qqmlimport.cpp +@@ -1549,6 +1549,15 @@ QQmlImportDatabase::QQmlImportDatabase(Q + QString installImportsPath = QLibraryInfo::location(QLibraryInfo::Qml2ImportsPath); + addImportPath(installImportsPath); + ++ // Add library paths derived from NIX_PROFILES. ++ const QByteArrayList profiles = qgetenv("NIX_PROFILES").split(' '); ++ const QString qmldir = QString::fromLatin1("/lib/qt5/qml"); ++ Q_FOREACH (const QByteArray &profile, profiles) { ++ if (!profile.isEmpty()) { ++ addImportPath(QFile::decodeName(profile) + qmldir); ++ } ++ } ++ + // env import paths + QByteArray envImportPath = qgetenv("QML2_IMPORT_PATH"); + if (!envImportPath.isEmpty()) { From 35f9c58206dac4a5f57c52da86774e2e656bcb64 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Fri, 15 Apr 2016 07:02:49 -0500 Subject: [PATCH 027/147] qt55.qtquick1: get import paths from NIX_PROFILES --- .../qtquick1/nix-profiles-import-paths.patch | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/pkgs/development/libraries/qt-5/5.5/qtquick1/nix-profiles-import-paths.patch b/pkgs/development/libraries/qt-5/5.5/qtquick1/nix-profiles-import-paths.patch index e69de29bb2d1..c01061d3378b 100644 --- a/pkgs/development/libraries/qt-5/5.5/qtquick1/nix-profiles-import-paths.patch +++ b/pkgs/development/libraries/qt-5/5.5/qtquick1/nix-profiles-import-paths.patch @@ -0,0 +1,20 @@ +Index: qtquick1-opensource-src-5.5.1/src/declarative/qml/qdeclarativeimport.cpp +=================================================================== +--- qtquick1-opensource-src-5.5.1.orig/src/declarative/qml/qdeclarativeimport.cpp ++++ qtquick1-opensource-src-5.5.1/src/declarative/qml/qdeclarativeimport.cpp +@@ -725,6 +725,15 @@ QDeclarativeImportDatabase::QDeclarative + + addImportPath(installImportsPath); + ++ // Add library paths derived from NIX_PROFILES. ++ const QByteArrayList profiles = qgetenv("NIX_PROFILES").split(' '); ++ const QString importdir = QString::fromLatin1("/lib/qt5/imports"); ++ Q_FOREACH (const QByteArray &profile, profiles) { ++ if (!profile.isEmpty()) { ++ addImportPath(QFile::decodeName(profile) + importdir); ++ } ++ } ++ + // env import paths + QByteArray envImportPath = qgetenv("QML_IMPORT_PATH"); + if (!envImportPath.isEmpty()) { From 51fe07711f3c0bbf378748de75e137548886dc11 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Fri, 15 Apr 2016 07:06:16 -0500 Subject: [PATCH 028/147] qt55.qtbase: disable plugin path debugging --- .../5.5/qtbase/debug-nix-profiles-paths.patch | 0 .../qtbase/nix-profiles-library-paths.patch | 18 ++++++------------ .../libraries/qt-5/5.5/qtbase/series | 1 - 3 files changed, 6 insertions(+), 13 deletions(-) delete mode 100644 pkgs/development/libraries/qt-5/5.5/qtbase/debug-nix-profiles-paths.patch diff --git a/pkgs/development/libraries/qt-5/5.5/qtbase/debug-nix-profiles-paths.patch b/pkgs/development/libraries/qt-5/5.5/qtbase/debug-nix-profiles-paths.patch deleted file mode 100644 index e69de29bb2d1..000000000000 diff --git a/pkgs/development/libraries/qt-5/5.5/qtbase/nix-profiles-library-paths.patch b/pkgs/development/libraries/qt-5/5.5/qtbase/nix-profiles-library-paths.patch index d20767a38e5b..b4561db6e77d 100644 --- a/pkgs/development/libraries/qt-5/5.5/qtbase/nix-profiles-library-paths.patch +++ b/pkgs/development/libraries/qt-5/5.5/qtbase/nix-profiles-library-paths.patch @@ -2,24 +2,18 @@ Index: qt-everywhere-opensource-src-5.5.1/qtbase/src/corelib/kernel/qcoreapplica =================================================================== --- qt-everywhere-opensource-src-5.5.1.orig/qtbase/src/corelib/kernel/qcoreapplication.cpp +++ qt-everywhere-opensource-src-5.5.1/qtbase/src/corelib/kernel/qcoreapplication.cpp -@@ -2498,6 +2498,22 @@ QStringList QCoreApplication::libraryPat +@@ -2498,6 +2498,16 @@ QStringList QCoreApplication::libraryPat } } } + qunsetenv("QT_PLUGIN_PATH"); // do not propagate to child processes + + // Add library paths derived from NIX_PROFILES. -+ const QByteArray nixProfilesEnv = qgetenv("NIX_PROFILES"); -+ if (!nixProfilesEnv.isEmpty()) { -+ QLatin1Char pathSep(' '); -+ QStringList paths = QFile::decodeName(nixProfilesEnv).split(pathSep, QString::SkipEmptyParts); -+ for (QStringList::iterator it = paths.begin(); it != paths.end(); ++it) { -+ it->append("/lib/qt5/plugins"); -+ QString canonicalPath = QDir(*it).canonicalPath(); -+ if (!canonicalPath.isEmpty() -+ && !app_libpaths->contains(canonicalPath)) { -+ app_libpaths->append(canonicalPath); -+ } ++ const QByteArrayList profiles = qgetenv("NIX_PROFILES").split(' '); ++ const QString plugindir = QString::fromLatin1("/lib/qt5/plugins"); ++ Q_FOREACH (const QByteArray &profile, profiles) { ++ if (!profile.isEmpty()) { ++ app_libpaths->append(QFile::decodeName(profile) + plugindir); + } + } } diff --git a/pkgs/development/libraries/qt-5/5.5/qtbase/series b/pkgs/development/libraries/qt-5/5.5/qtbase/series index fbe309909049..2196d8383752 100644 --- a/pkgs/development/libraries/qt-5/5.5/qtbase/series +++ b/pkgs/development/libraries/qt-5/5.5/qtbase/series @@ -7,4 +7,3 @@ xdg-config-dirs.patch nix-profiles-library-paths.patch compose-search-path.patch libressl.patch -debug-nix-profiles-paths.patch From 8727485e08f404d62b286deab39c6f588b517e28 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Mon, 18 Apr 2016 08:43:37 -0500 Subject: [PATCH 029/147] qt55.qtbase: canonicalize paths in addToSearchPathOnce --- .../libraries/qt-5/5.5/qtbase/setup-hook.sh | 21 +++++++++++-------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh b/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh index 9cf1ef9ccb61..e6b34b40292c 100644 --- a/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh +++ b/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh @@ -2,7 +2,7 @@ if [[ -z "$QMAKE" ]]; then _qtLinkDependencyDir() { @lndir@/bin/lndir -silent "$1/$2" "$qtOut/$2" - if [[ -n "$NIX_QT_SUBMODULE" ]]; then + if [ -n "$NIX_QT_SUBMODULE" ]; then find "$1/$2" -printf "$2/%P\n" >> "$out/nix-support/qt-inputs" fi } @@ -22,13 +22,13 @@ _qtLinkModule() { _qtRmModules() { cat "$out/nix-support/qt-inputs" | while read file; do - if [[ -h "$out/$file" ]]; then + if [ -h "$out/$file" ]; then rm "$out/$file" fi done cat "$out/nix-support/qt-inputs" | while read file; do - if [[ -d "$out/$file" ]]; then + if [ -d "$out/$file" ]; then rmdir --ignore-fail-on-non-empty -p "$out/$file" fi done @@ -43,11 +43,14 @@ addToSearchPathOnceWithCustomDelimiter() { local dirs local exported IFS="$delim" read -a dirs <<< "${!search}" - for dir in ${dirs[@]}; do - if [ "z$dir" == "z$target" ]; then exported=1; fi - done - if [ -z $exported ]; then - eval "export ${search}=\"${!search}${!search:+$delim}$target\"" + local canonical + if canonical=$(readlink -e "$target"); then + for dir in ${dirs[@]}; do + if [ "z$dir" == "z$canonical" ]; then exported=1; fi + done + if [ -z $exported ]; then + eval "export ${search}=\"${!search}${!search:+$delim}$canonical\"" + fi fi } @@ -97,7 +100,7 @@ _qtMultioutDevs() { } qtOut="" -if [[ -z "$NIX_QT_SUBMODULE" ]]; then +if [ -z "$NIX_QT_SUBMODULE" ]; then qtOut=`mktemp -d` else qtOut=$out From d5c100dc21475517f00aa3bafd9b7068d73f68f2 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Mon, 18 Apr 2016 18:05:12 -0500 Subject: [PATCH 030/147] makeQtWrapper: defer environment settings to prePhases --- .../libraries/qt-5/5.5/make-qt-wrapper.sh | 20 +++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/pkgs/development/libraries/qt-5/5.5/make-qt-wrapper.sh b/pkgs/development/libraries/qt-5/5.5/make-qt-wrapper.sh index f29bbb73639b..3b537430371a 100644 --- a/pkgs/development/libraries/qt-5/5.5/make-qt-wrapper.sh +++ b/pkgs/development/libraries/qt-5/5.5/make-qt-wrapper.sh @@ -24,11 +24,15 @@ makeQtWrapper() { "$@" } -# cannot use addToSearchPath because these directories may not exist yet -export QT_PLUGIN_PATH="$QT_PLUGIN_PATH${QT_PLUGIN_PATH:+:}${!outputLib}/lib/qt5/plugins" -export QML_IMPORT_PATH="$QML_IMPORT_PATH${QML_IMPORT_PATH:+:}${!outputLib}/lib/qt5/imports" -export QML2_IMPORT_PATH="$QML2_IMPORT_PATH${QML2_IMPORT_PATH:+:}${!outputLib}/lib/qt5/qml" -export XDG_CONFIG_DIRS="$XDG_CONFIG_DIRS${XDG_CONFIG_DIRS:+:}${!outputLib}/etc/xdg" -export XDG_DATA_DIRS="$XDG_DATA_DIRS${XDG_DATA_DIRS:+:}${!outputLib}/share" -export NIX_WRAP_XDG_CONFIG_DIRS="$NIX_WRAP_XDG_CONFIG_DIRS${NIX_WRAP_XDG_CONFIG_DIRS:+:}${!outputLib}/etc/xdg" -export NIX_WRAP_XDG_DATA_DIRS="$NIX_WRAP_XDG_DATA_DIRS${NIX_WRAP_XDG_DATA_DIRS:+:}${!outputLib}/share" +_makeQtWrapperSetup() { + # cannot use addToSearchPath because these directories may not exist yet + export QT_PLUGIN_PATH="$QT_PLUGIN_PATH${QT_PLUGIN_PATH:+:}${!outputLib}/lib/qt5/plugins" + export QML_IMPORT_PATH="$QML_IMPORT_PATH${QML_IMPORT_PATH:+:}${!outputLib}/lib/qt5/imports" + export QML2_IMPORT_PATH="$QML2_IMPORT_PATH${QML2_IMPORT_PATH:+:}${!outputLib}/lib/qt5/qml" + export XDG_CONFIG_DIRS="$XDG_CONFIG_DIRS${XDG_CONFIG_DIRS:+:}${!outputLib}/etc/xdg" + export XDG_DATA_DIRS="$XDG_DATA_DIRS${XDG_DATA_DIRS:+:}${!outputLib}/share" + export NIX_WRAP_XDG_CONFIG_DIRS="$NIX_WRAP_XDG_CONFIG_DIRS${NIX_WRAP_XDG_CONFIG_DIRS:+:}${!outputLib}/etc/xdg" + export NIX_WRAP_XDG_DATA_DIRS="$NIX_WRAP_XDG_DATA_DIRS${NIX_WRAP_XDG_DATA_DIRS:+:}${!outputLib}/share" +} + +prePhases+=(_makeQtWrapperSetup) From 84a83feb4d806849901d7fb9f997674e543b92f1 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Mon, 18 Apr 2016 18:05:31 -0500 Subject: [PATCH 031/147] qt55.qtbase: do not link $out/lib into $dev/ --- pkgs/development/libraries/qt-5/5.5/qtbase/default.nix | 5 ----- 1 file changed, 5 deletions(-) diff --git a/pkgs/development/libraries/qt-5/5.5/qtbase/default.nix b/pkgs/development/libraries/qt-5/5.5/qtbase/default.nix index 35410d55e66d..596135a060d7 100644 --- a/pkgs/development/libraries/qt-5/5.5/qtbase/default.nix +++ b/pkgs/development/libraries/qt-5/5.5/qtbase/default.nix @@ -121,11 +121,6 @@ stdenv.mkDerivation { # The destination directory must exist or moveToOutput will do nothing mkdir -p "$dev/share" moveToOutput "share/doc" "$dev" - - mkdir -p "$dev/lib" - lndir -silent "$out/lib" "$dev/lib" - if [[ -h "$dev/lib/cmake" ]]; then rm "$dev/lib/cmake"; fi - if [[ -h "$dev/lib/pkgconfig" ]]; then rm "$dev/lib/pkgconfig"; fi } preFixupHooks+=(_multioutQtDevs) From fc45aaafa659763178d29639fa0ca18337d5f8f3 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Mon, 18 Apr 2016 18:06:11 -0500 Subject: [PATCH 032/147] kde5.extra-cmake-modules: do not propagate build inputs for docs --- .../kde-5/frameworks-5.19/extra-cmake-modules/setup-hook.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkgs/desktops/kde-5/frameworks-5.19/extra-cmake-modules/setup-hook.sh b/pkgs/desktops/kde-5/frameworks-5.19/extra-cmake-modules/setup-hook.sh index 56ed09f4ea59..193cb048949a 100644 --- a/pkgs/desktops/kde-5/frameworks-5.19/extra-cmake-modules/setup-hook.sh +++ b/pkgs/desktops/kde-5/frameworks-5.19/extra-cmake-modules/setup-hook.sh @@ -7,7 +7,6 @@ _ecmSetXdgDirs() { _ecmPropagateSharedData() { local sharedPaths=( \ "config.cfg" \ - "doc" \ "kconf_update" \ "kservices5" \ "kservicetypes5" \ @@ -20,7 +19,6 @@ _ecmPropagateSharedData() { "applications" \ "desktop-directories" \ "mime" \ - "info" \ "dbus-1" \ "interfaces" \ "services" \ @@ -28,6 +26,7 @@ _ecmPropagateSharedData() { for dir in ${sharedPaths[@]}; do if [ -d "$1/share/$dir" ]; then addToSearchPathOnce NIX_WRAP_XDG_DATA_DIRS "$1/share" + propagateOnce propagatedBuildInputs "$1" propagateOnce propagatedUserEnvPkgs "$1" break fi From 40ebe0bad3cce545f9f5eb41ca6749b3d7a76e02 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Mon, 18 Apr 2016 20:29:19 -0500 Subject: [PATCH 033/147] qt55.polkit-qt: use multiple outputs --- pkgs/development/libraries/polkit-qt-1/default.nix | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/pkgs/development/libraries/polkit-qt-1/default.nix b/pkgs/development/libraries/polkit-qt-1/default.nix index 3715158705cb..dc28d1398bc5 100644 --- a/pkgs/development/libraries/polkit-qt-1/default.nix +++ b/pkgs/development/libraries/polkit-qt-1/default.nix @@ -9,6 +9,8 @@ assert (withQt5 -> qtbase != null); assert (!withQt5 -> qt4 != null); stdenv.mkDerivation { name = "polkit-qt-1-0.112.0"; + outputs = [ "dev" "out" ]; + src = fetchurl { url = "mirror://kde/stable/apps/KDE4.x/admin/polkit-qt-1-0.112.0.tar.bz2"; sha256 = "1ip78x20hjqvm08kxhp6gb8hf6k5n6sxyx6kk2yvvq53djzh7yv7"; @@ -18,6 +20,16 @@ stdenv.mkDerivation { propagatedBuildInputs = [ polkit glib ] ++ [(if withQt5 then qtbase else qt4)]; + preConfigure = '' + cmakeFlags+=" -DCMAKE_INSTALL_LIBDIR=''${!outputLib}/lib" + ''; + + postFixup = '' + # Fix library location in CMake module + sed -i "$dev/lib/cmake/PolkitQt5-1/PolkitQt5-1Config.cmake" \ + -e "s,set_and_check.POLKITQT-1_LIB_DIR.*$,set_and_check(POLKITQT-1_LIB_DIR \"''${!outputLib}/lib\")," + ''; + meta = { description = "A Qt wrapper around PolKit"; maintainers = with stdenv.lib.maintainers; [ ttuegel ]; From 7cc52a65b0681ba5e16fb38f9baafa1a61088762 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Mon, 18 Apr 2016 20:55:19 -0500 Subject: [PATCH 034/147] kde5.kconfigwidgets: remove runtime perl dependency --- pkgs/desktops/kde-5/frameworks-5.19/kconfigwidgets/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/desktops/kde-5/frameworks-5.19/kconfigwidgets/default.nix b/pkgs/desktops/kde-5/frameworks-5.19/kconfigwidgets/default.nix index 0e14d06edd36..3b3bd27cce08 100644 --- a/pkgs/desktops/kde-5/frameworks-5.19/kconfigwidgets/default.nix +++ b/pkgs/desktops/kde-5/frameworks-5.19/kconfigwidgets/default.nix @@ -9,7 +9,8 @@ kdeFramework { propagatedBuildInputs = [ kauth kconfig kcodecs ki18n kwidgetsaddons ]; patches = [ ./0001-qdiriterator-follow-symlinks.patch ]; postInstall = '' - wrapQtProgram "$out/bin/preparetips5" + moveToOutput "bin/preparetips5" "$dev" + wrapQtProgram "$dev/bin/preparetips5" ''; meta = { maintainers = [ lib.maintainers.ttuegel ]; From afef9d4b0a13ab928e62e55d579840b7831466e8 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Tue, 19 Apr 2016 06:08:06 -0500 Subject: [PATCH 035/147] polkit-qt-1: separate Qt 4 and Qt 5 versions --- .../libraries/polkit-qt-1/qt-4.nix | 21 +++++++++++++++++++ .../polkit-qt-1/{default.nix => qt-5.nix} | 12 ++++------- pkgs/top-level/all-packages.nix | 6 ++---- 3 files changed, 27 insertions(+), 12 deletions(-) create mode 100644 pkgs/development/libraries/polkit-qt-1/qt-4.nix rename pkgs/development/libraries/polkit-qt-1/{default.nix => qt-5.nix} (65%) diff --git a/pkgs/development/libraries/polkit-qt-1/qt-4.nix b/pkgs/development/libraries/polkit-qt-1/qt-4.nix new file mode 100644 index 000000000000..fa5c77aa27aa --- /dev/null +++ b/pkgs/development/libraries/polkit-qt-1/qt-4.nix @@ -0,0 +1,21 @@ +{ stdenv, fetchurl, cmake, pkgconfig, polkit, automoc4, glib, qt4 }: + +with stdenv.lib; + +stdenv.mkDerivation { + name = "polkit-qt-1-qt4-0.112.0"; + + src = fetchurl { + url = "mirror://kde/stable/apps/KDE4.x/admin/polkit-qt-1-0.112.0.tar.bz2"; + sha256 = "1ip78x20hjqvm08kxhp6gb8hf6k5n6sxyx6kk2yvvq53djzh7yv7"; + }; + + nativeBuildInputs = [ cmake pkgconfig automoc4 ]; + + propagatedBuildInputs = [ polkit glib qt4 ]; + + meta = { + description = "A Qt wrapper around PolKit"; + maintainers = with stdenv.lib.maintainers; [ ttuegel ]; + }; +} diff --git a/pkgs/development/libraries/polkit-qt-1/default.nix b/pkgs/development/libraries/polkit-qt-1/qt-5.nix similarity index 65% rename from pkgs/development/libraries/polkit-qt-1/default.nix rename to pkgs/development/libraries/polkit-qt-1/qt-5.nix index dc28d1398bc5..d9b2afbd8011 100644 --- a/pkgs/development/libraries/polkit-qt-1/default.nix +++ b/pkgs/development/libraries/polkit-qt-1/qt-5.nix @@ -1,13 +1,9 @@ -{ stdenv, fetchurl, cmake, pkgconfig, polkit, automoc4, glib -, qt4 ? null -, withQt5 ? false, qtbase ? null }: +{ stdenv, fetchurl, cmake, pkgconfig, polkit, glib, qtbase }: with stdenv.lib; -assert (withQt5 -> qtbase != null); assert (!withQt5 -> qt4 != null); - stdenv.mkDerivation { - name = "polkit-qt-1-0.112.0"; + name = "polkit-qt-1-qt5-0.112.0"; outputs = [ "dev" "out" ]; @@ -16,9 +12,9 @@ stdenv.mkDerivation { sha256 = "1ip78x20hjqvm08kxhp6gb8hf6k5n6sxyx6kk2yvvq53djzh7yv7"; }; - nativeBuildInputs = [ cmake pkgconfig ] ++ optional (!withQt5) automoc4; + nativeBuildInputs = [ cmake pkgconfig ]; - propagatedBuildInputs = [ polkit glib ] ++ [(if withQt5 then qtbase else qt4)]; + propagatedBuildInputs = [ polkit glib qtbase ]; preConfigure = '' cmakeFlags+=" -DCMAKE_INSTALL_LIBDIR=''${!outputLib}/lib" diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 8132ccd5aa51..33bdf7235ef0 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8469,7 +8469,7 @@ in spidermonkey = spidermonkey_17; }; - polkit_qt4 = callPackage ../development/libraries/polkit-qt-1 { }; + polkit_qt4 = callPackage ../development/libraries/polkit-qt-1/qt-4.nix { }; poppler = callPackage ../development/libraries/poppler { lcms = lcms2; }; @@ -8581,9 +8581,7 @@ in phonon-backend-vlc = callPackage ../development/libraries/phonon-backend-vlc/qt5 { }; - polkit-qt = callPackage ../development/libraries/polkit-qt-1 { - withQt5 = true; - }; + polkit-qt = callPackage ../development/libraries/polkit-qt-1/qt-5.nix { }; poppler = callPackage ../development/libraries/poppler { lcms = lcms2; From 924c0d34e7ddc9f21ce182122e3eaf9cfea12ffa Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Tue, 19 Apr 2016 07:48:50 -0500 Subject: [PATCH 036/147] qt55.polkit-qt: set CMAKE_INSTALL_INCLUDEDIR --- pkgs/development/libraries/polkit-qt-1/qt-5.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/development/libraries/polkit-qt-1/qt-5.nix b/pkgs/development/libraries/polkit-qt-1/qt-5.nix index d9b2afbd8011..c6e26385d446 100644 --- a/pkgs/development/libraries/polkit-qt-1/qt-5.nix +++ b/pkgs/development/libraries/polkit-qt-1/qt-5.nix @@ -18,12 +18,13 @@ stdenv.mkDerivation { preConfigure = '' cmakeFlags+=" -DCMAKE_INSTALL_LIBDIR=''${!outputLib}/lib" + cmakeFlags+=" -DCMAKE_INSTALL_INCLUDEDIR=''${!outputDev}/include" ''; postFixup = '' # Fix library location in CMake module sed -i "$dev/lib/cmake/PolkitQt5-1/PolkitQt5-1Config.cmake" \ - -e "s,set_and_check.POLKITQT-1_LIB_DIR.*$,set_and_check(POLKITQT-1_LIB_DIR \"''${!outputLib}/lib\")," + -e "s,\\(set_and_check.POLKITQT-1_LIB_DIR\\).*$,\\1 \"''${!outputLib}/lib\")," ''; meta = { From d088e0621e11a03cd50b27863f883fb0f8d3db36 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Tue, 19 Apr 2016 19:41:27 -0500 Subject: [PATCH 037/147] dbus: 1.8.20 -> 1.10.8 --- pkgs/development/libraries/dbus/default.nix | 7 +++--- .../dbus/ignore-missing-includedirs.patch | 23 ------------------- 2 files changed, 3 insertions(+), 27 deletions(-) delete mode 100644 pkgs/development/libraries/dbus/ignore-missing-includedirs.patch diff --git a/pkgs/development/libraries/dbus/default.nix b/pkgs/development/libraries/dbus/default.nix index 83635d9739f1..dd86ca540815 100644 --- a/pkgs/development/libraries/dbus/default.nix +++ b/pkgs/development/libraries/dbus/default.nix @@ -6,8 +6,8 @@ assert x11Support -> libX11 != null && libSM != null; let - version = "1.8.20"; - sha256 = "0fkh3d5r57a659hw9lqnw4v0bc5556vx54fsf7l9c732ci6byksw"; + version = "1.10.8"; + sha256 = "0560y3hxpgh346w6avcrcz79c8ansmn771y5xpcvvlr6m8mx5wxs"; self = stdenv.mkDerivation { name = "dbus-${version}"; @@ -17,8 +17,7 @@ self = stdenv.mkDerivation { inherit sha256; }; - patches = [ ./ignore-missing-includedirs.patch ] - ++ lib.optional stdenv.isSunOS ./implement-getgrouplist.patch; + patches = lib.optional stdenv.isSunOS ./implement-getgrouplist.patch; postPatch = '' substituteInPlace tools/Makefile.in \ --replace 'install-localstatelibDATA:' 'disabled:' \ diff --git a/pkgs/development/libraries/dbus/ignore-missing-includedirs.patch b/pkgs/development/libraries/dbus/ignore-missing-includedirs.patch deleted file mode 100644 index 2781f4ae3de5..000000000000 --- a/pkgs/development/libraries/dbus/ignore-missing-includedirs.patch +++ /dev/null @@ -1,23 +0,0 @@ -diff -ru -x '*~' dbus-1.2.24-orig/bus/config-parser.c dbus-1.2.24/bus/config-parser.c ---- dbus-1.2.24-orig/bus/config-parser.c 2010-03-23 20:01:27.000000000 +0100 -+++ dbus-1.2.24/bus/config-parser.c 2010-07-20 14:17:20.000000000 +0200 -@@ -2159,12 +2159,16 @@ - - retval = FALSE; - -- dir = _dbus_directory_open (dirname, error); -+ dbus_error_init (&tmp_error); -+ -+ dir = _dbus_directory_open (dirname, &tmp_error); - - if (dir == NULL) -- goto failed; -+ { -+ retval = TRUE; -+ goto failed; -+ } - -- dbus_error_init (&tmp_error); - while (_dbus_directory_get_next_file (dir, &filename, &tmp_error)) - { - DBusString full_path; From 491f7f017c4dd247413d3367d4733541c797d9ea Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Tue, 19 Apr 2016 20:36:03 -0500 Subject: [PATCH 038/147] cmake: set LIBDIR and INCLUDEDIR for multiple outputs --- pkgs/development/libraries/polkit-qt-1/qt-5.nix | 5 ----- pkgs/development/tools/build-managers/cmake/setup-hook.sh | 2 ++ 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/pkgs/development/libraries/polkit-qt-1/qt-5.nix b/pkgs/development/libraries/polkit-qt-1/qt-5.nix index c6e26385d446..bdeb175b89f5 100644 --- a/pkgs/development/libraries/polkit-qt-1/qt-5.nix +++ b/pkgs/development/libraries/polkit-qt-1/qt-5.nix @@ -16,11 +16,6 @@ stdenv.mkDerivation { propagatedBuildInputs = [ polkit glib qtbase ]; - preConfigure = '' - cmakeFlags+=" -DCMAKE_INSTALL_LIBDIR=''${!outputLib}/lib" - cmakeFlags+=" -DCMAKE_INSTALL_INCLUDEDIR=''${!outputDev}/include" - ''; - postFixup = '' # Fix library location in CMake module sed -i "$dev/lib/cmake/PolkitQt5-1/PolkitQt5-1Config.cmake" \ diff --git a/pkgs/development/tools/build-managers/cmake/setup-hook.sh b/pkgs/development/tools/build-managers/cmake/setup-hook.sh index b14e9984bc3c..eaabb37f4987 100755 --- a/pkgs/development/tools/build-managers/cmake/setup-hook.sh +++ b/pkgs/development/tools/build-managers/cmake/setup-hook.sh @@ -44,6 +44,8 @@ cmakeConfigurePhase() { # executable. This flag makes the shared library accessible from its # nix/store directory. cmakeFlags="-DCMAKE_INSTALL_NAME_DIR=$prefix/lib $cmakeFlags" + cmakeFlags="-DCMAKE_INSTALL_LIBDIR=${!outputLib}/lib $cmakeFlags" + cmakeFlags="-DCMAKE_INSTALL_INCLUDEDIR=${!outputDev}/include $cmakeFlags" # Avoid cmake resetting the rpath of binaries, on make install # And build always Release, to ensure optimisation flags From 01b171c87782237374385eeb37a4a9a1149002c9 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Wed, 20 Apr 2016 09:59:41 -0500 Subject: [PATCH 039/147] phonon: fix build after cmake setup hook changes --- .../phonon-backend-gstreamer/qt4/default.nix | 17 ++++++--- .../libraries/phonon/qt4/default.nix | 28 -------------- .../libraries/phonon/qt5/default.nix | 38 ------------------- pkgs/top-level/all-packages.nix | 4 +- 4 files changed, 13 insertions(+), 74 deletions(-) delete mode 100644 pkgs/development/libraries/phonon/qt4/default.nix delete mode 100644 pkgs/development/libraries/phonon/qt5/default.nix diff --git a/pkgs/development/libraries/phonon-backend-gstreamer/qt4/default.nix b/pkgs/development/libraries/phonon-backend-gstreamer/qt4/default.nix index 844c2e580093..2f588cbe7087 100644 --- a/pkgs/development/libraries/phonon-backend-gstreamer/qt4/default.nix +++ b/pkgs/development/libraries/phonon-backend-gstreamer/qt4/default.nix @@ -1,8 +1,7 @@ -{ stdenv, fetchurl, cmake, automoc4, qt4, pkgconfig, phonon, gstreamer -, gst_plugins_base }: +{ stdenv, fetchurl, cmake, automoc4, qt4, pkgconfig, phonon, gst_all_1 }: let - version = "4.7.2"; + version = "4.8.2"; pname = "phonon-backend-gstreamer"; in @@ -11,18 +10,24 @@ stdenv.mkDerivation rec { src = fetchurl { url = "mirror://kde/stable/phonon/${pname}/${version}/src/${name}.tar.xz"; - sha256 = "1cfjk450aajr8hfhnfq7zbmryprxiwr9ha5x585dsh7mja82mdw0"; + sha256 = "1q1ix6zsfnh6gfnpmwp67s376m7g7ahpjl1qp2fqakzb5cgzgq10"; }; - buildInputs = [ phonon qt4 gstreamer gst_plugins_base ]; + buildInputs = with gst_all_1; [ phonon qt4 gstreamer gst-plugins-base ]; nativeBuildInputs = [ cmake automoc4 pkgconfig ]; + NIX_CFLAGS_COMPILE = [ + # This flag should be picked up through pkgconfig, but it isn't. + "-I${gst_all_1.gstreamer}/lib/gstreamer-1.0/include" + ]; + cmakeFlags = [ "-DCMAKE_INSTALL_LIBDIR=lib" ]; meta = { homepage = http://phonon.kde.org/; description = "GStreamer backend for Phonon"; platforms = stdenv.lib.platforms.linux; - }; + maintainers = with stdenv.lib.maintainers; [ ttuegel ]; + }; } diff --git a/pkgs/development/libraries/phonon/qt4/default.nix b/pkgs/development/libraries/phonon/qt4/default.nix deleted file mode 100644 index 9875b216e066..000000000000 --- a/pkgs/development/libraries/phonon/qt4/default.nix +++ /dev/null @@ -1,28 +0,0 @@ -{ stdenv, fetchurl, cmake, automoc4, libpulseaudio, qt4 }: - -with stdenv.lib; - -let - v = "4.8.1"; -in - -stdenv.mkDerivation rec { - name = "phonon-${v}"; - - src = fetchurl { - url = "mirror://kde/stable/phonon/${v}/phonon-${v}.tar.xz"; - sha256 = "1l97h1jj3gvl1chx1qbipizfvjgqc05wrhdcflc76c2krlk03jmn"; - }; - - buildInputs = [ qt4 libpulseaudio ]; - - nativeBuildInputs = [ cmake automoc4 ]; - - meta = { - homepage = http://phonon.kde.org/; - description = "Multimedia API for Qt"; - license = stdenv.lib.licenses.lgpl2; - platforms = stdenv.lib.platforms.linux; - maintainers = with stdenv.lib.maintainers; [ ttuegel ]; - }; -} diff --git a/pkgs/development/libraries/phonon/qt5/default.nix b/pkgs/development/libraries/phonon/qt5/default.nix deleted file mode 100644 index fc07344d2d1a..000000000000 --- a/pkgs/development/libraries/phonon/qt5/default.nix +++ /dev/null @@ -1,38 +0,0 @@ -{ stdenv, fetchurl, cmake, mesa, pkgconfig, libpulseaudio -, qtbase, qtquick1, qttools -, debug ? false }: - -with stdenv.lib; - -let - v = "4.8.3"; -in - -stdenv.mkDerivation rec { - name = "phonon-${v}"; - - src = fetchurl { - url = "mirror://kde/stable/phonon/${v}/src/phonon-${v}.tar.xz"; - sha256 = "05nshngk03ln90vsjz44dx8al576f4vd5fvhs1l0jmx13jb9q551"; - }; - - buildInputs = [ mesa qtbase qtquick1 qttools libpulseaudio ]; - - nativeBuildInputs = [ cmake pkgconfig ]; - - NIX_CFLAGS_COMPILE = "-fPIC"; - - cmakeFlags = [ - "-DCMAKE_BUILD_TYPE=${if debug then "Debug" else "Release"}" - "-DPHONON_BUILD_PHONON4QT5=ON" - "-DCMAKE_INSTALL_LIBDIR=lib" - ]; - - meta = { - homepage = http://phonon.kde.org/; - description = "Multimedia API for Qt"; - license = stdenv.lib.licenses.lgpl2; - platforms = stdenv.lib.platforms.linux; - maintainers = with stdenv.lib.maintainers; [ ttuegel ]; - }; -} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 33bdf7235ef0..aef36f574be1 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8440,7 +8440,7 @@ in pdf2xml = callPackage ../development/libraries/pdf2xml {} ; - phonon = callPackage ../development/libraries/phonon/qt4 {}; + phonon = callPackage ../development/libraries/phonon {}; phonon_backend_gstreamer = callPackage ../development/libraries/phonon-backend-gstreamer/qt4 {}; @@ -8575,7 +8575,7 @@ in openbr = callPackage ../development/libraries/openbr { }; - phonon = callPackage ../development/libraries/phonon/qt5 { }; + phonon = callPackage ../development/libraries/phonon { }; phonon-backend-gstreamer = callPackage ../development/libraries/phonon-backend-gstreamer/qt5 { }; From 3ecbb214b6c0f0571c5742357f80e2d11c2c5935 Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Wed, 20 Apr 2016 10:15:10 -0500 Subject: [PATCH 040/147] phonon: fix evaluation error --- pkgs/development/libraries/phonon/default.nix | 54 +++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 pkgs/development/libraries/phonon/default.nix diff --git a/pkgs/development/libraries/phonon/default.nix b/pkgs/development/libraries/phonon/default.nix new file mode 100644 index 000000000000..3c731ca19e32 --- /dev/null +++ b/pkgs/development/libraries/phonon/default.nix @@ -0,0 +1,54 @@ +{ stdenv, fetchurl, cmake, mesa, pkgconfig, libpulseaudio +, qt4 ? null, automoc4 ? null +, qtbase ? null, qtquick1 ? null, qttools ? null +, debug ? false }: + +with stdenv.lib; + +let + v = "4.8.3"; + withQt5 = qtbase != null; +in + +assert withQt5 -> qtquick1 != null; +assert withQt5 -> qttools != null; +assert !withQt5 -> automoc4 != null; + +stdenv.mkDerivation rec { + name = "phonon-${v}"; + + meta = { + homepage = http://phonon.kde.org/; + description = "Multimedia API for Qt"; + license = stdenv.lib.licenses.lgpl2; + platforms = stdenv.lib.platforms.linux; + maintainers = with stdenv.lib.maintainers; [ ttuegel ]; + }; + + src = fetchurl { + url = "mirror://kde/stable/phonon/${v}/src/phonon-${v}.tar.xz"; + sha256 = "05nshngk03ln90vsjz44dx8al576f4vd5fvhs1l0jmx13jb9q551"; + }; + + buildInputs = + [ mesa libpulseaudio ] + ++ (if withQt5 then [ qtbase qtquick1 qttools ] else [ qt4 ]); + + nativeBuildInputs = + [ cmake pkgconfig ] + ++ optional (!withQt5) automoc4; + + NIX_CFLAGS_COMPILE = "-fPIC"; + + cmakeFlags = + [ "-DCMAKE_BUILD_TYPE=${if debug then "Debug" else "Release"}" ] + ++ optional withQt5 "-DPHONON_BUILD_PHONON4QT5=ON"; + + postPatch = '' + sed -i PhononConfig.cmake.in \ + -e "/get_filename_component(rootDir/ s/^.*$//" \ + -e "s,\\(set(PHONON_INCLUDE_DIR\\).*$,\\1 \"''${!outputDev}/include\")," \ + -e "s,\\(set(PHONON_LIBRARY_DIR\\).*$,\\1 \"''${!outputLib}/lib\")," \ + -e "s,\\(set(PHONON_BUILDSYSTEM_DIR\\).*$,\\1 \"''${!outputDev}/share/phonon${if withQt5 then "4qt5" else ""}/buildsystem\")," + ''; +} From 065a7515a75e15b30840da31dc063564fa4335a4 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:21:07 +0300 Subject: [PATCH 041/147] qmake4Hook: init --- pkgs/development/libraries/qt-4.x/4.8/qmake-hook.sh | 11 +++++++++++ pkgs/top-level/all-packages.nix | 6 ++++++ 2 files changed, 17 insertions(+) create mode 100644 pkgs/development/libraries/qt-4.x/4.8/qmake-hook.sh diff --git a/pkgs/development/libraries/qt-4.x/4.8/qmake-hook.sh b/pkgs/development/libraries/qt-4.x/4.8/qmake-hook.sh new file mode 100644 index 000000000000..bf716a72d0fc --- /dev/null +++ b/pkgs/development/libraries/qt-4.x/4.8/qmake-hook.sh @@ -0,0 +1,11 @@ +qmakeConfigurePhase() { + runHook preConfigure + + $QMAKE PREFIX=$out $qmakeFlags + + runHook postConfigure +} + +export QMAKE=@qt4@/bin/qmake + +configurePhase=qmakeConfigurePhase diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index aef36f574be1..dd2abaa4dc43 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8544,6 +8544,12 @@ in inherit (pkgs.darwin.apple_sdk.frameworks) ApplicationServices OpenGL Cocoa AGL; }; + qmake48Hook = makeSetupHook + { substitutions = { qt4 = qt48; }; } + ../development/libraries/qt-4.x/4.8/qmake-hook.sh; + + qmake4Hook = qmake48Hook; + qt48Full = appendToName "full" (qt48.override { docs = true; demos = true; From b857459bdbce58c833845b6adfdc68b1a204bed5 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:22:45 +0300 Subject: [PATCH 042/147] qt5.qmakeHook: init, move from qtbase's setup hook --- .../libraries/qt-5/5.4/default.nix | 5 +- .../libraries/qt-5/5.4/qmake-hook.sh | 120 +++++++++++++++++ .../libraries/qt-5/5.4/qtbase/default.nix | 1 - .../libraries/qt-5/5.4/qtbase/setup-hook.sh | 121 ++---------------- .../libraries/qt-5/5.5/default.nix | 4 +- .../libraries/qt-5/5.5/qmake-hook.sh | 120 +++++++++++++++++ .../libraries/qt-5/5.5/qtbase/default.nix | 1 - .../libraries/qt-5/5.5/qtbase/setup-hook.sh | 109 ---------------- 8 files changed, 252 insertions(+), 229 deletions(-) create mode 100644 pkgs/development/libraries/qt-5/5.4/qmake-hook.sh create mode 100644 pkgs/development/libraries/qt-5/5.5/qmake-hook.sh diff --git a/pkgs/development/libraries/qt-5/5.4/default.nix b/pkgs/development/libraries/qt-5/5.4/default.nix index df2fb8ad1862..950129ba5413 100644 --- a/pkgs/development/libraries/qt-5/5.4/default.nix +++ b/pkgs/development/libraries/qt-5/5.4/default.nix @@ -37,12 +37,10 @@ let inherit src; propagatedBuildInputs = args.qtInputs ++ (args.propagatedBuildInputs or []); - nativeBuildInputs = (args.nativeBuildInputs or []) ++ [ self.fixQtModuleCMakeConfig ]; + nativeBuildInputs = (args.nativeBuildInputs or []) ++ [ self.fixQtModuleCMakeConfig self.qmakeHook ]; NIX_QT_SUBMODULE = args.NIX_QT_SUBMODULE or true; - dontAddPrefix = args.dontAddPrefix or true; dontFixLibtool = args.dontFixLibtool or true; - configureScript = args.configureScript or "qmake"; outputs = args.outputs or [ "dev" "out" ]; setOutputFlags = false; @@ -109,6 +107,7 @@ let makeQtWrapper = makeSetupHook { deps = [ makeWrapper ]; } ./make-qt-wrapper.sh; fixQtModuleCMakeConfig = makeSetupHook { } ./fix-qt-module-cmake-config.sh; + qmakeHook = makeSetupHook { substitutions = { qt_dev = qtbase.dev; lndir = pkgs.xorg.lndir; }; } ./qmake-hook.sh; }; diff --git a/pkgs/development/libraries/qt-5/5.4/qmake-hook.sh b/pkgs/development/libraries/qt-5/5.4/qmake-hook.sh new file mode 100644 index 000000000000..e8838b854b50 --- /dev/null +++ b/pkgs/development/libraries/qt-5/5.4/qmake-hook.sh @@ -0,0 +1,120 @@ +if [[ -z "$QMAKE" ]]; then + +_qtLinkDependencyDir() { + @lndir@/bin/lndir -silent "$1/$2" "$qtOut/$2" + if [ -n "$NIX_QT_SUBMODULE" ]; then + find "$1/$2" -printf "$2/%P\n" >> "$out/nix-support/qt-inputs" + fi +} + +_qtLinkModule() { + if [ -d "$1/mkspecs" ]; then + # $1 is a Qt module + _qtLinkDependencyDir "$1" mkspecs + + for dir in bin include lib share; do + if [ -d "$1/$dir" ]; then + _qtLinkDependencyDir "$1" "$dir" + fi + done + fi +} + +_qtRmModules() { + cat "$out/nix-support/qt-inputs" | while read file; do + if [ -h "$out/$file" ]; then + rm "$out/$file" + fi + done + + cat "$out/nix-support/qt-inputs" | while read file; do + if [ -d "$out/$file" ]; then + rmdir --ignore-fail-on-non-empty -p "$out/$file" + fi + done + + rm "$out/nix-support/qt-inputs" +} + +_qtPropagateRuntimeDependencies() { + for dir in "lib/qt5/plugins" "lib/qt5/qml" "lib/qt5/imports"; do + if [ -d "$1/$dir" ]; then + propagateOnce propagatedBuildInputs "$1" + propagateOnce propagatedUserEnvPkgs "$1" + break + fi + done + addToSearchPathOnce QT_PLUGIN_PATH "$1/lib/qt5/plugins" + addToSearchPathOnce QML_IMPORT_PATH "$1/lib/qt5/imports" + addToSearchPathOnce QML2_IMPORT_PATH "$1/lib/qt5/qml" +} + +_qtRmQmake() { + rm "$qtOut/bin/qmake" "$qtOut/bin/qt.conf" +} + +_qtSetQmakePath() { + export PATH="$qtOut/bin${PATH:+:}$PATH" +} + +_qtMultioutModuleDevs() { + # We cannot simply set these paths in configureFlags because libQtCore retains + # references to the paths it was built with. + moveToOutput "bin" "${!outputDev}" + moveToOutput "include" "${!outputDev}" + + # The destination directory must exist or moveToOutput will do nothing + mkdir -p "${!outputDev}/share" + moveToOutput "share/doc" "${!outputDev}" +} + +_qtMultioutDevs() { + # This is necessary whether the package is a Qt module or not + moveToOutput "mkspecs" "${!outputDev}" +} + +qmakeConfigurePhase() { + runHook preConfigure + + qmake PREFIX=$out $qmakeFlags + + runHook postConfigure +} + +qtOut="" +if [[ -z "$NIX_QT_SUBMODULE" ]]; then + qtOut=`mktemp -d` +else + qtOut=$out +fi + +mkdir -p "$qtOut/bin" "$qtOut/mkspecs" "$qtOut/include" "$qtOut/nix-support" "$qtOut/lib" "$qtOut/share" + +cp "@qt_dev@/bin/qmake" "$qtOut/bin" +cat >"$qtOut/bin/qt.conf" <> "$out/nix-support/qt-inputs" - fi -} - -_qtLinkModule() { - if [ -d "$1/mkspecs" ]; then - # $1 is a Qt module - _qtLinkDependencyDir "$1" mkspecs - - for dir in bin include lib share; do - if [ -d "$1/$dir" ]; then - _qtLinkDependencyDir "$1" "$dir" - fi - done - fi -} - -_qtRmModules() { - cat "$out/nix-support/qt-inputs" | while read file; do - if [[ -h "$out/$file" ]]; then - rm "$out/$file" - fi - done - - cat "$out/nix-support/qt-inputs" | while read file; do - if [[ -d "$out/$file" ]]; then - rmdir --ignore-fail-on-non-empty -p "$out/$file" - fi - done - - rm "$out/nix-support/qt-inputs" -} - addToSearchPathOnceWithCustomDelimiter() { local delim="$1" local search="$2" @@ -43,11 +5,14 @@ addToSearchPathOnceWithCustomDelimiter() { local dirs local exported IFS="$delim" read -a dirs <<< "${!search}" - for dir in ${dirs[@]}; do - if [ "z$dir" == "z$target" ]; then exported=1; fi - done - if [ -z $exported ]; then - eval "export ${search}=\"${!search}${!search:+$delim}$target\"" + local canonical + if canonical=$(readlink -e "$target"); then + for dir in ${dirs[@]}; do + if [ "z$dir" == "z$canonical" ]; then exported=1; fi + done + if [ -z $exported ]; then + eval "export ${search}=\"${!search}${!search:+$delim}$canonical\"" + fi fi } @@ -59,76 +24,6 @@ propagateOnce() { addToSearchPathOnceWithCustomDelimiter ' ' "$@" } -_qtPropagateRuntimeDependencies() { - for dir in "lib/qt5/plugins" "lib/qt5/qml" "lib/qt5/imports"; do - if [ -d "$1/$dir" ]; then - propagateOnce propagatedBuildInputs "$1" - break - fi - done - addToSearchPathOnce QT_PLUGIN_PATH "$1/lib/qt5/plugins" - addToSearchPathOnce QML_IMPORT_PATH "$1/lib/qt5/imports" - addToSearchPathOnce QML2_IMPORT_PATH "$1/lib/qt5/qml" -} - -_qtRmQmake() { - rm "$qtOut/bin/qmake" "$qtOut/bin/qt.conf" -} - -_qtSetQmakePath() { - export PATH="$qtOut/bin${PATH:+:}$PATH" -} - -_qtMultioutModuleDevs() { - # We cannot simply set these paths in configureFlags because libQtCore retains - # references to the paths it was built with. - moveToOutput "bin" "${!outputDev}" - moveToOutput "include" "${!outputDev}" - - # The destination directory must exist or moveToOutput will do nothing - mkdir -p "${!outputDev}/share" - moveToOutput "share/doc" "${!outputDev}" -} - -_qtMultioutDevs() { - # This is necessary whether the package is a Qt module or not - moveToOutput "mkspecs" "${!outputDev}" -} - -qtOut="" -if [[ -z "$NIX_QT_SUBMODULE" ]]; then - qtOut=`mktemp -d` -else - qtOut=$out -fi - -mkdir -p "$qtOut/bin" "$qtOut/mkspecs" "$qtOut/include" "$qtOut/nix-support" "$qtOut/lib" "$qtOut/share" - -cp "@dev@/bin/qmake" "$qtOut/bin" -cat >"$qtOut/bin/qt.conf" <> "$out/nix-support/qt-inputs" + fi +} + +_qtLinkModule() { + if [ -d "$1/mkspecs" ]; then + # $1 is a Qt module + _qtLinkDependencyDir "$1" mkspecs + + for dir in bin include lib share; do + if [ -d "$1/$dir" ]; then + _qtLinkDependencyDir "$1" "$dir" + fi + done + fi +} + +_qtRmModules() { + cat "$out/nix-support/qt-inputs" | while read file; do + if [ -h "$out/$file" ]; then + rm "$out/$file" + fi + done + + cat "$out/nix-support/qt-inputs" | while read file; do + if [ -d "$out/$file" ]; then + rmdir --ignore-fail-on-non-empty -p "$out/$file" + fi + done + + rm "$out/nix-support/qt-inputs" +} + +_qtPropagateRuntimeDependencies() { + for dir in "lib/qt5/plugins" "lib/qt5/qml" "lib/qt5/imports"; do + if [ -d "$1/$dir" ]; then + propagateOnce propagatedBuildInputs "$1" + propagateOnce propagatedUserEnvPkgs "$1" + break + fi + done + addToSearchPathOnce QT_PLUGIN_PATH "$1/lib/qt5/plugins" + addToSearchPathOnce QML_IMPORT_PATH "$1/lib/qt5/imports" + addToSearchPathOnce QML2_IMPORT_PATH "$1/lib/qt5/qml" +} + +_qtRmQmake() { + rm "$qtOut/bin/qmake" "$qtOut/bin/qt.conf" +} + +_qtSetQmakePath() { + export PATH="$qtOut/bin${PATH:+:}$PATH" +} + +_qtMultioutModuleDevs() { + # We cannot simply set these paths in configureFlags because libQtCore retains + # references to the paths it was built with. + moveToOutput "bin" "${!outputDev}" + moveToOutput "include" "${!outputDev}" + + # The destination directory must exist or moveToOutput will do nothing + mkdir -p "${!outputDev}/share" + moveToOutput "share/doc" "${!outputDev}" +} + +_qtMultioutDevs() { + # This is necessary whether the package is a Qt module or not + moveToOutput "mkspecs" "${!outputDev}" +} + +qmakeConfigurePhase() { + runHook preConfigure + + qmake PREFIX=$out $qmakeFlags + + runHook postConfigure +} + +qtOut="" +if [[ -z "$NIX_QT_SUBMODULE" ]]; then + qtOut=`mktemp -d` +else + qtOut=$out +fi + +mkdir -p "$qtOut/bin" "$qtOut/mkspecs" "$qtOut/include" "$qtOut/nix-support" "$qtOut/lib" "$qtOut/share" + +cp "@qt_dev@/bin/qmake" "$qtOut/bin" +cat >"$qtOut/bin/qt.conf" <> "$out/nix-support/qt-inputs" - fi -} - -_qtLinkModule() { - if [ -d "$1/mkspecs" ]; then - # $1 is a Qt module - _qtLinkDependencyDir "$1" mkspecs - - for dir in bin include lib share; do - if [ -d "$1/$dir" ]; then - _qtLinkDependencyDir "$1" "$dir" - fi - done - fi -} - -_qtRmModules() { - cat "$out/nix-support/qt-inputs" | while read file; do - if [ -h "$out/$file" ]; then - rm "$out/$file" - fi - done - - cat "$out/nix-support/qt-inputs" | while read file; do - if [ -d "$out/$file" ]; then - rmdir --ignore-fail-on-non-empty -p "$out/$file" - fi - done - - rm "$out/nix-support/qt-inputs" -} - addToSearchPathOnceWithCustomDelimiter() { local delim="$1" local search="$2" @@ -62,77 +24,6 @@ propagateOnce() { addToSearchPathOnceWithCustomDelimiter ' ' "$@" } -_qtPropagateRuntimeDependencies() { - for dir in "lib/qt5/plugins" "lib/qt5/qml" "lib/qt5/imports"; do - if [ -d "$1/$dir" ]; then - propagateOnce propagatedBuildInputs "$1" - propagateOnce propagatedUserEnvPkgs "$1" - break - fi - done - addToSearchPathOnce QT_PLUGIN_PATH "$1/lib/qt5/plugins" - addToSearchPathOnce QML_IMPORT_PATH "$1/lib/qt5/imports" - addToSearchPathOnce QML2_IMPORT_PATH "$1/lib/qt5/qml" -} - -_qtRmQmake() { - rm "$qtOut/bin/qmake" "$qtOut/bin/qt.conf" -} - -_qtSetQmakePath() { - export PATH="$qtOut/bin${PATH:+:}$PATH" -} - -_qtMultioutModuleDevs() { - # We cannot simply set these paths in configureFlags because libQtCore retains - # references to the paths it was built with. - moveToOutput "bin" "${!outputDev}" - moveToOutput "include" "${!outputDev}" - - # The destination directory must exist or moveToOutput will do nothing - mkdir -p "${!outputDev}/share" - moveToOutput "share/doc" "${!outputDev}" -} - -_qtMultioutDevs() { - # This is necessary whether the package is a Qt module or not - moveToOutput "mkspecs" "${!outputDev}" -} - -qtOut="" -if [ -z "$NIX_QT_SUBMODULE" ]; then - qtOut=`mktemp -d` -else - qtOut=$out -fi - -mkdir -p "$qtOut/bin" "$qtOut/mkspecs" "$qtOut/include" "$qtOut/nix-support" "$qtOut/lib" "$qtOut/share" - -cp "@dev@/bin/qmake" "$qtOut/bin" -cat >"$qtOut/bin/qt.conf" < Date: Sun, 17 Apr 2016 02:23:21 +0300 Subject: [PATCH 043/147] memorycoin: move to qmake4Hook --- pkgs/applications/altcoins/memorycoin.nix | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/altcoins/memorycoin.nix b/pkgs/applications/altcoins/memorycoin.nix index 4e5e24e3062a..0470fd21eaea 100644 --- a/pkgs/applications/altcoins/memorycoin.nix +++ b/pkgs/applications/altcoins/memorycoin.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, pkgconfig, openssl, db48, boost -, zlib, miniupnpc, qt4, utillinux, protobuf, qrencode +, zlib, miniupnpc, qt4, qmake4Hook, utillinux, protobuf, qrencode , withGui }: with stdenv.lib; @@ -15,13 +15,11 @@ stdenv.mkDerivation rec{ buildInputs = [ pkgconfig openssl db48 boost zlib miniupnpc utillinux protobuf ] - ++ optionals withGui [ qt4 qrencode ]; + ++ optionals withGui [ qt4 qmake4Hook qrencode ]; configureFlags = [ "--with-boost-libdir=${boost.lib}/lib" ] ++ optionals withGui [ "--with-gui=qt4" ]; - configurePhase = optional withGui "qmake"; - preBuild = optional (!withGui) "cd src; cp makefile.unix Makefile"; installPhase = From a6e731a8f822ecf5984068105c6133028da37942 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:23:39 +0300 Subject: [PATCH 044/147] namecoin: move to qmake4Hook --- pkgs/applications/altcoins/namecoin.nix | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/pkgs/applications/altcoins/namecoin.nix b/pkgs/applications/altcoins/namecoin.nix index f2e2aae698e2..563363b8baf4 100644 --- a/pkgs/applications/altcoins/namecoin.nix +++ b/pkgs/applications/altcoins/namecoin.nix @@ -1,4 +1,4 @@ -{ stdenv, db4, boost, openssl, qt4, miniupnpc, unzip, namecoind }: +{ stdenv, db4, boost, openssl, qt4, qmake4Hook, miniupnpc, unzip, namecoind }: with stdenv.lib; stdenv.mkDerivation rec { @@ -7,15 +7,9 @@ stdenv.mkDerivation rec { version = namecoind.version; src = namecoind.src; - buildInputs = [ db4 boost openssl unzip qt4 miniupnpc ]; + buildInputs = [ db4 boost openssl unzip qt4 qmake4Hook miniupnpc ]; - configurePhase = '' - qmake USE_UPNP=- - ''; - - buildPhase = '' - make - ''; + qmakeFlags = [ "USE_UPNP=-" ]; installPhase = '' mkdir -p $out/bin From 3a713b166e7c656b476ebd5a9abb53f46a89fd4a Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:24:07 +0300 Subject: [PATCH 045/147] primecoin: move to qmake4Hook --- pkgs/applications/altcoins/primecoin.nix | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/altcoins/primecoin.nix b/pkgs/applications/altcoins/primecoin.nix index 61bba04cb6ae..360a39a4fd81 100644 --- a/pkgs/applications/altcoins/primecoin.nix +++ b/pkgs/applications/altcoins/primecoin.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, pkgconfig, openssl, db48, boost -, zlib, miniupnpc, qt4, utillinux, protobuf, qrencode +, zlib, miniupnpc, qt4, qmake4Hook, utillinux, protobuf, qrencode , withGui }: with stdenv.lib; @@ -15,13 +15,11 @@ stdenv.mkDerivation rec{ buildInputs = [ pkgconfig openssl db48 boost zlib miniupnpc utillinux protobuf ] - ++ optionals withGui [ qt4 qrencode ]; + ++ optionals withGui [ qt4 qmake4Hook qrencode ]; configureFlags = [ "--with-boost-libdir=${boost.lib}/lib" ] ++ optionals withGui [ "--with-gui=qt4" ]; - configurePhase = optional withGui "qmake"; - preBuild = optional (!withGui) "cd src; cp makefile.unix Makefile"; installPhase = From a3d909836d28ef164abfc930299c05b9885777b2 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:20 +0300 Subject: [PATCH 046/147] dfasma: move to qmakeHook This reverts commit 4dde716a0510b352abf67ed08902422d9ec3b214. --- pkgs/applications/audio/dfasma/default.nix | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/audio/dfasma/default.nix b/pkgs/applications/audio/dfasma/default.nix index 94f20bc543e3..d006f2c01781 100644 --- a/pkgs/applications/audio/dfasma/default.nix +++ b/pkgs/applications/audio/dfasma/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, fftw, libsndfile, qtbase, qtmultimedia, makeQtWrapper }: +{ stdenv, fetchFromGitHub, fftw, libsndfile, qtbase, qtmultimedia, qmakeHook, makeQtWrapper }: let @@ -37,7 +37,7 @@ in stdenv.mkDerivation rec { owner = "gillesdegottex"; }; - buildInputs = [ fftw libsndfile qtbase qtmultimedia ]; + buildInputs = [ fftw libsndfile qtbase qtmultimedia qmakeHook ]; nativeBuildInputs = [ makeQtWrapper ]; @@ -47,10 +47,8 @@ in stdenv.mkDerivation rec { cp -Rv "${libqaudioextra.src}"/* external/libqaudioextra ''; - configurePhase = '' - runHook preConfigure - qmake PREFIX=$out PREFIXSHORTCUT=$out dfasma.pro - runHook postConfigure + preConfigure = '' + qmakeFlags="$qmakeFlags PREFIXSHORTCUT=$out" ''; enableParallelBuilding = true; From 222c4a221eb0ed6498d47562b51fe7b203984747 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:19 +0300 Subject: [PATCH 047/147] fmit: move to qmakeHook This reverts commit 97d89ad7eee9dcfd17b696ebd69b30d242c2d3cb. --- pkgs/applications/audio/fmit/default.nix | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/pkgs/applications/audio/fmit/default.nix b/pkgs/applications/audio/fmit/default.nix index c27e049a4ae1..83367b83e480 100644 --- a/pkgs/applications/audio/fmit/default.nix +++ b/pkgs/applications/audio/fmit/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, fftw, freeglut, qtbase, qtmultimedia +{ stdenv, fetchFromGitHub, fftw, freeglut, mesa_glu, qtbase, qtmultimedia, qmakeHook , alsaSupport ? true, alsaLib ? null , jackSupport ? false, libjack2 ? null , portaudioSupport ? false, portaudio ? null }: @@ -18,22 +18,17 @@ stdenv.mkDerivation rec { owner = "gillesdegottex"; }; - buildInputs = [ fftw freeglut qtbase qtmultimedia ] + buildInputs = [ fftw freeglut mesa_glu qtbase qtmultimedia qmakeHook ] ++ stdenv.lib.optionals alsaSupport [ alsaLib ] ++ stdenv.lib.optionals jackSupport [ libjack2 ] ++ stdenv.lib.optionals portaudioSupport [ portaudio ]; - configurePhase = '' - runHook preConfigure - mkdir build - cd build - qmake \ + preConfigure = '' + qmakeFlags="$qmakeFlags \ CONFIG+=${stdenv.lib.optionalString alsaSupport "acs_alsa"} \ CONFIG+=${stdenv.lib.optionalString jackSupport "acs_jack"} \ CONFIG+=${stdenv.lib.optionalString portaudioSupport "acs_portaudio"} \ - PREFIX="$out" PREFIXSHORTCUT="$out" \ - ../fmit.pro - runHook postConfigure + PREFIXSHORTCUT=$out" ''; enableParallelBuilding = true; From eb3a5a300213f7bebade0ef60a7492b012f6b402 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:19 +0300 Subject: [PATCH 048/147] iannix: move to qmakeHook This reverts commit bb543e1540e0e70180e60285b7a353f0c32dc101. --- pkgs/applications/audio/iannix/default.nix | 10 +++------- pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/pkgs/applications/audio/iannix/default.nix b/pkgs/applications/audio/iannix/default.nix index f17abf975218..83fd2b14ed2e 100644 --- a/pkgs/applications/audio/iannix/default.nix +++ b/pkgs/applications/audio/iannix/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, alsaLib, pkgconfig, qt5 +{ stdenv, fetchFromGitHub, alsaLib, pkgconfig, qtbase, qtscript, qmakeHook }: stdenv.mkDerivation rec { @@ -11,13 +11,9 @@ stdenv.mkDerivation rec { sha256 = "184ydb9f1303v332k5k3f1ki7cb6nkxhh6ij0yn72v7dp7figrgj"; }; - buildInputs = [ alsaLib pkgconfig qt5.qtbase qt5.qtscript ]; + buildInputs = [ alsaLib pkgconfig qtbase qtscript qmakeHook ]; - configurePhase = '' - runHook preConfigure - qmake PREFIX=/ - runHook postConfigure - ''; + qmakeFlags = [ "PREFIX=/" ]; installFlags = [ "INSTALL_ROOT=$(out)" ]; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index dd2abaa4dc43..90d766c925a7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1939,7 +1939,7 @@ in iasl = callPackage ../development/compilers/iasl { }; - iannix = callPackage ../applications/audio/iannix { }; + iannix = qt5.callPackage ../applications/audio/iannix { }; icecast = callPackage ../servers/icecast { }; From c579c21b04d0607c4f895db9c42232958461de70 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:19 +0300 Subject: [PATCH 049/147] keyfinder: move to qmakeHook This reverts commit 6d9147abab8840c61b14be13aa029ff9275cb700. --- pkgs/applications/audio/keyfinder/default.nix | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/pkgs/applications/audio/keyfinder/default.nix b/pkgs/applications/audio/keyfinder/default.nix index 049920d28079..0cacd7724939 100644 --- a/pkgs/applications/audio/keyfinder/default.nix +++ b/pkgs/applications/audio/keyfinder/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, libav_0_8, libkeyfinder, qtbase, qtxmlpatterns, taglib }: +{ stdenv, fetchFromGitHub, libav_0_8, libkeyfinder, qtbase, qtxmlpatterns, qmakeHook, taglib }: stdenv.mkDerivation rec { name = "keyfinder-${version}"; @@ -11,21 +11,14 @@ stdenv.mkDerivation rec { owner = "ibsh"; }; - buildInputs = [ libav_0_8 libkeyfinder qtbase qtxmlpatterns taglib ]; + buildInputs = [ libav_0_8 libkeyfinder qtbase qtxmlpatterns qmakeHook taglib ]; postPatch = '' substituteInPlace is_KeyFinder.pro \ --replace "keyfinder.0" "keyfinder" \ - --replace '$$[QT_INSTALL_PREFIX]' "$out" \ --replace "-stdlib=libc++" "" ''; - configurePhase = '' - runHook preConfigure - qmake - runHook postConfigure - ''; - enableParallelBuilding = true; meta = with stdenv.lib; { From 22a09f1f71d656ada326ec7b9c958f6304d2714c Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:25:36 +0300 Subject: [PATCH 050/147] qtscrobbler: move to qmake4Hook --- pkgs/applications/audio/qtscrobbler/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/audio/qtscrobbler/default.nix b/pkgs/applications/audio/qtscrobbler/default.nix index e7108ebe4871..453da89953e0 100644 --- a/pkgs/applications/audio/qtscrobbler/default.nix +++ b/pkgs/applications/audio/qtscrobbler/default.nix @@ -1,4 +1,4 @@ -{ stdenv, lib, fetchurl, withMtp ? true, libmtp, pkgconfig, which, qt4 }: +{ stdenv, lib, fetchurl, withMtp ? true, libmtp, pkgconfig, which, qt4, qmake4Hook }: stdenv.mkDerivation rec { name = "qtscrobbler-${version}"; @@ -9,18 +9,16 @@ stdenv.mkDerivation rec { sha256 = "01c8e48f616ed09504833d27d92fd62f455bd645ea2d1cc2a5f4c287d641daba"; }; - nativeBuildInputs = lib.optionals withMtp [ pkgconfig which ]; + nativeBuildInputs = [ qmake4Hook ] ++ lib.optionals withMtp [ pkgconfig which ]; buildInputs = [ qt4 ] ++ lib.optional withMtp libmtp; enableParallelBuilding = true; postPatch = '' cd src - sed -i "s,/usr/local,$out," common.pri + sed -i -e "s,/usr/local,$out," -e "s,/usr,," common.pri ''; - configurePhase = "qmake"; - meta = with lib; { description = "Qt based last.fm scrobbler"; longDescription = '' From 395a4b819be6f59ec8fdb841071b0508e7b7c0be Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:26:19 +0300 Subject: [PATCH 051/147] sonic-visualiser: move to qmakeHook --- pkgs/applications/audio/sonic-visualiser/default.nix | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/audio/sonic-visualiser/default.nix b/pkgs/applications/audio/sonic-visualiser/default.nix index ae7a39240a54..31a95c51fc50 100644 --- a/pkgs/applications/audio/sonic-visualiser/default.nix +++ b/pkgs/applications/audio/sonic-visualiser/default.nix @@ -3,7 +3,7 @@ { stdenv, fetchurl, alsaLib, bzip2, fftw, libjack2, libX11, liblo , libmad, libogg, librdf, librdf_raptor, librdf_rasqal, libsamplerate , libsndfile, pkgconfig, libpulseaudio, makeQtWrapper, qtbase, redland -, rubberband, serd, sord, vampSDK, fftwFloat +, qmakeHook, rubberband, serd, sord, vampSDK, fftwFloat }: stdenv.mkDerivation rec { @@ -16,7 +16,7 @@ stdenv.mkDerivation rec { }; buildInputs = - [ libsndfile qtbase fftw fftwFloat bzip2 librdf rubberband + [ libsndfile qtbase qmakeHook fftw fftwFloat bzip2 librdf rubberband libsamplerate vampSDK alsaLib librdf_raptor librdf_rasqal redland serd sord @@ -32,13 +32,12 @@ stdenv.mkDerivation rec { libX11 ]; - nativeBuildInputs = [ makeQtWrapper ]; + nativeBuildInputs = [ makeQtWrapper qmakeHook ]; - buildPhase = '' + configurePhase = '' for i in sonic-visualiser svapp svcore svgui; - do cd $i && qmake -makefile PREFIX=$out && cd ..; + do cd $i && qmake PREFIX=$out && cd ..; done - make ''; installPhase = '' From 448100fe83ac36a4355f5fa9136c2c77aac1270e Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:26:41 +0300 Subject: [PATCH 052/147] focuswriter: move to qmake4Hook --- pkgs/applications/editors/focuswriter/default.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/editors/focuswriter/default.nix b/pkgs/applications/editors/focuswriter/default.nix index bc9163e63cb4..eedb674b472c 100644 --- a/pkgs/applications/editors/focuswriter/default.nix +++ b/pkgs/applications/editors/focuswriter/default.nix @@ -1,4 +1,4 @@ -{stdenv, fetchurl, qt4, pkgconfig, hunspell}: +{ stdenv, fetchurl, qt4, qmake4Hook, pkgconfig, hunspell }: stdenv.mkDerivation rec { name = "focuswriter-${version}"; @@ -9,11 +9,11 @@ stdenv.mkDerivation rec { sha256 = "1i58jxbiy95ijf81g8c3gwxhcg3irzssna3wv7vhrd57g4lcfj0w"; }; - buildInputs = [ qt4 pkgconfig hunspell ]; + buildInputs = [ qt4 qmake4Hook pkgconfig hunspell ]; - configurePhase = "qmake PREFIX=/"; + qmakeFlags = [ "PREFIX=/" ]; - installPhase = "make install INSTALL_ROOT=$out"; + installFlags = [ "INSTALL_ROOT=$(out)" ]; meta = { description = "Simple, distraction-free writing environment"; From b1dcfeeeebde011361d6a211fe4a3ab7eaee4a5a Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:26:57 +0300 Subject: [PATCH 053/147] texmaker: move to qmake4Hook --- pkgs/applications/editors/texmaker/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/editors/texmaker/default.nix b/pkgs/applications/editors/texmaker/default.nix index 04ebf195108f..83165f0a5054 100644 --- a/pkgs/applications/editors/texmaker/default.nix +++ b/pkgs/applications/editors/texmaker/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4, poppler_qt4, zlib, pkgconfig, poppler}: +{ stdenv, fetchurl, qt4, qmake4Hook, poppler_qt4, zlib, pkgconfig, poppler }: stdenv.mkDerivation rec { pname = "texmaker"; @@ -11,11 +11,11 @@ stdenv.mkDerivation rec { }; buildInputs = [ qt4 poppler_qt4 zlib ]; - nativeBuildInputs = [ pkgconfig poppler ]; + nativeBuildInputs = [ pkgconfig poppler qmake4Hook ]; NIX_CFLAGS_COMPILE="-I${poppler}/include/poppler"; preConfigure = '' - qmake PREFIX=$out DESKTOPDIR=$out/share/applications ICONDIR=$out/share/pixmaps texmaker.pro + qmakeFlags="$qmakeFlags DESKTOPDIR=$out/share/applications ICONDIR=$out/share/pixmaps" ''; meta = with stdenv.lib; { From 6d96f2f3b4722b894d1338fc75410f02f2be4352 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:27:11 +0300 Subject: [PATCH 054/147] texstudio: move to qmake4Hook --- pkgs/applications/editors/texstudio/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/editors/texstudio/default.nix b/pkgs/applications/editors/texstudio/default.nix index 4b0cccae3648..4accf1cad677 100644 --- a/pkgs/applications/editors/texstudio/default.nix +++ b/pkgs/applications/editors/texstudio/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4, poppler_qt4, zlib, pkgconfig}: +{ stdenv, fetchurl, qt4, qmake4Hook, poppler_qt4, zlib, pkgconfig}: stdenv.mkDerivation rec { pname = "texstudio"; @@ -11,11 +11,9 @@ stdenv.mkDerivation rec { sha256 = "1smmc4xqs8x8qzp6iqj2wr4xarfnxxxp6rq6chx1kb256w75jwfw"; }; - buildInputs = [ qt4 poppler_qt4 zlib pkgconfig]; + buildInputs = [ qt4 qmake4Hook poppler_qt4 zlib pkgconfig ]; - preConfigure = '' - qmake PREFIX=$out NO_APPDATA=True texstudio.pro - ''; + qmakeFlags = [ "NO_APPDATA=True" ]; meta = with stdenv.lib; { description = "TeX and LaTeX editor"; From de7d8e64cf1895fa3153608295400e3b70a64b5e Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:27:26 +0300 Subject: [PATCH 055/147] tiled: move to qmakeHook --- pkgs/applications/editors/tiled/default.nix | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/editors/tiled/default.nix b/pkgs/applications/editors/tiled/default.nix index 059b85cee5f7..e4b2f0461c24 100644 --- a/pkgs/applications/editors/tiled/default.nix +++ b/pkgs/applications/editors/tiled/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qtbase, qttools, pkgconfig, python }: +{ stdenv, fetchurl, qtbase, qttools, qmakeHook, pkgconfig, python }: let version = "0.12.3"; @@ -13,9 +13,7 @@ stdenv.mkDerivation rec { inherit sha256; }; - buildInputs = [ qtbase qttools pkgconfig python ]; - - preConfigure = "qmake -r PREFIX=$out"; + buildInputs = [ qtbase qttools qmakeHook pkgconfig python ]; meta = { description = "A free, easy to use and flexible tile map editor"; From 62e3430b132397c57b154db3f4c871212a0d813d Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 23:01:16 +0300 Subject: [PATCH 056/147] antimony: move to qmakeHook This reverts commit 9fa8fb1dec426ad79ff67e01f20d831c322d8525. --- pkgs/applications/graphics/antimony/default.nix | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/graphics/antimony/default.nix b/pkgs/applications/graphics/antimony/default.nix index fa9a7e0fdd3f..50b33096e3d2 100644 --- a/pkgs/applications/graphics/antimony/default.nix +++ b/pkgs/applications/graphics/antimony/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchgit, libpng, python3, boost, mesa, qtbase, ncurses }: +{ stdenv, fetchgit, libpng, python3, boost, mesa, qtbase, qmakeHook, ncurses }: let gitRev = "745eca3a2d2657c495d5509e9083c884e021d09c"; @@ -31,16 +31,14 @@ in mesa qtbase ncurses ]; - configurePhase = '' - runHook preConfigure + nativeBuildHooks = [ qmakeHook ]; + + preConfigure = '' export GITREV=${gitRev} export GITBRANCH=${gitBranch} export GITTAG=${gitTag} cd qt - export sourceRoot=$sourceRoot/qt - qmake antimony.pro PREFIX=$out - runHook postConfigure ''; enableParallelBuilding = true; From b0c5221ce3bd0196f17d57e70e9f3205fb0c6c3e Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:28:56 +0300 Subject: [PATCH 057/147] awesomebump: move to qmakeHook --- pkgs/applications/graphics/awesomebump/default.nix | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/graphics/awesomebump/default.nix b/pkgs/applications/graphics/awesomebump/default.nix index c71b1f9335b4..b89e18ed148c 100644 --- a/pkgs/applications/graphics/awesomebump/default.nix +++ b/pkgs/applications/graphics/awesomebump/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchurl, qtbase, makeWrapper }: +{ lib, stdenv, fetchurl, qtbase, qmakeHook, makeWrapper }: stdenv.mkDerivation { name = "awesomebump-4.0"; @@ -10,9 +10,7 @@ stdenv.mkDerivation { setSourceRoot = "sourceRoot=$(echo */Sources)"; - buildInputs = [ qtbase makeWrapper ]; - - preBuild = "qmake"; + buildInputs = [ qtbase qmakeHook makeWrapper ]; enableParallelBuilding = true; From 7b08f65f57296ba9c16aaa428bed86677f53cfd6 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:29:11 +0300 Subject: [PATCH 058/147] leocad: move to qmake4Hook --- pkgs/applications/graphics/leocad/default.nix | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/graphics/leocad/default.nix b/pkgs/applications/graphics/leocad/default.nix index 9ca9c5921028..884dc1158534 100644 --- a/pkgs/applications/graphics/leocad/default.nix +++ b/pkgs/applications/graphics/leocad/default.nix @@ -3,7 +3,7 @@ To use aditional parts libraries set the variable LEOCAD_LIB=/path/to/libs/ or use option -l /path/to/libs/ */ -{ stdenv, fetchsvn, qt4, zlib }: +{ stdenv, fetchsvn, qt4, qmake4Hook, zlib }: stdenv.mkDerivation rec { name = "leocad-${version}"; @@ -14,12 +14,11 @@ stdenv.mkDerivation rec { sha256 = "1190gb437ls51hhfiwa79fq131026kywpy3j3k4fkdgfr8a9v3q8"; }; - buildInputs = [ qt4 zlib ]; + buildInputs = [ qt4 qmake4Hook zlib ]; - prefixKey = "INSTALL_PREFIX="; - configureScript = "qmake leocad.pro"; postPatch = '' substituteInPlace common/camera.cpp --replace "isnan(" "std::isnan(" + export qmakeFlags="$qmakeFlags INSTALL_PREFIX=$out" ''; meta = with stdenv.lib; { From 2a7a4ec079405c01b0e504aaacff1cdd52637789 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:29:52 +0300 Subject: [PATCH 059/147] meshlab: use system vcg --- pkgs/applications/graphics/meshlab/default.nix | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/graphics/meshlab/default.nix b/pkgs/applications/graphics/meshlab/default.nix index 49bfb47c85a4..d8434de5a77e 100644 --- a/pkgs/applications/graphics/meshlab/default.nix +++ b/pkgs/applications/graphics/meshlab/default.nix @@ -1,4 +1,4 @@ -{stdenv, fetchurl, qt4, bzip2, lib3ds, levmar, muparser, unzip}: +{ stdenv, fetchurl, qt4, bzip2, lib3ds, levmar, muparser, unzip, vcg }: stdenv.mkDerivation rec { name = "meshlab-1.3.3"; @@ -16,8 +16,6 @@ stdenv.mkDerivation rec { buildPhase = '' mkdir -p "$out/include" - cp -r vcglib "$out/include" - export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -I$out/include/vcglib" export NIX_LDFLAGS="-rpath $out/opt/meshlab $NIX_LDFLAGS" cd meshlab/src pushd external @@ -38,7 +36,7 @@ stdenv.mkDerivation rec { sourceRoot = "."; - buildInputs = [ qt4 unzip ]; + buildInputs = [ qt4 unzip vcg ]; meta = { description = "System for the processing and editing of unstructured 3D triangular meshes"; From 0b6a6c903ea89e3883faca30c2a8b9cbef225505 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:30:06 +0300 Subject: [PATCH 060/147] openscad: move to qmake4Hook --- pkgs/applications/graphics/openscad/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/graphics/openscad/default.nix b/pkgs/applications/graphics/openscad/default.nix index 7557e19896ff..f3b16a304608 100644 --- a/pkgs/applications/graphics/openscad/default.nix +++ b/pkgs/applications/graphics/openscad/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4, bison, flex, eigen, boost, mesa, glew, opencsg, cgal +{ stdenv, fetchurl, qt4, qmake4Hook, bison, flex, eigen, boost, mesa, glew, opencsg, cgal , mpfr, gmp, glib, pkgconfig, harfbuzz, qscintilla, gettext }: @@ -12,13 +12,11 @@ stdenv.mkDerivation rec { }; buildInputs = [ - qt4 bison flex eigen boost mesa glew opencsg cgal mpfr gmp glib + qt4 qmake4Hook bison flex eigen boost mesa glew opencsg cgal mpfr gmp glib pkgconfig harfbuzz qscintilla gettext ]; - configurePhase = '' - qmake PREFIX="$out" VERSION=${version} - ''; + qmakeFlags = [ "VERSION=${version}" ]; doCheck = false; From 6dc6a549c87c43d780b96c100a9ddf4573a44e10 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:19 +0300 Subject: [PATCH 061/147] phototonic: move to qmakeHook This reverts commit a0dd8d5afed35629c1055661d9262c64fc472402. --- pkgs/applications/graphics/phototonic/default.nix | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/pkgs/applications/graphics/phototonic/default.nix b/pkgs/applications/graphics/phototonic/default.nix index 4ed3a424031d..4782376d1e0b 100644 --- a/pkgs/applications/graphics/phototonic/default.nix +++ b/pkgs/applications/graphics/phototonic/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, qtbase, exiv2 }: +{ stdenv, fetchFromGitHub, qtbase, qmakeHook, exiv2 }: stdenv.mkDerivation rec { name = "phototonic-${version}"; @@ -14,16 +14,12 @@ stdenv.mkDerivation rec { }; buildInputs = [ qtbase exiv2 ]; + nativeBuildInputs = [ qmakeHook ]; - configurePhase = '' - runHook preConfigure - sed -i 's;/usr;;' phototonic.pro - qmake PREFIX="" - runHook postConfigure + preConfigure = '' + sed -i 's;/usr;$$PREFIX/;g' phototonic.pro ''; - installFlags = [ "INSTALL_ROOT=$(out)" ]; - meta = with stdenv.lib; { description = "An image viewer and organizer"; homepage = http://oferkv.github.io/phototonic/; From 0ca9ad08b4b0c9167d405288db6acdb790b2ac19 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:30:33 +0300 Subject: [PATCH 062/147] qtpfsgui: move to qmake4Hook --- pkgs/applications/graphics/qtpfsgui/default.nix | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/graphics/qtpfsgui/default.nix b/pkgs/applications/graphics/qtpfsgui/default.nix index efa245cc7e9a..5223ae14c63e 100644 --- a/pkgs/applications/graphics/qtpfsgui/default.nix +++ b/pkgs/applications/graphics/qtpfsgui/default.nix @@ -1,4 +1,4 @@ -{stdenv, fetchurl, qt4, exiv2, openexr, fftwSinglePrec, libtiff, ilmbase }: +{stdenv, fetchurl, qt4, qmake4Hook, exiv2, openexr, fftwSinglePrec, libtiff, ilmbase }: stdenv.mkDerivation rec { name = "qtpfsgui-1.9.3"; @@ -9,15 +9,19 @@ stdenv.mkDerivation rec { }; buildInputs = [ qt4 exiv2 openexr fftwSinglePrec libtiff ]; + nativeBuildInputs = [ qmake4Hook ]; - configurePhase = '' + preConfigure = '' export CPATH="${ilmbase}/include/OpenEXR:$CPATH" - qmake PREFIX=$out EXIV2PATH=${exiv2}/include/exiv2 \ - OPENEXRDIR=${openexr}/include/OpenEXR \ - FFTW3DIR=${fftwSinglePrec}/include \ - LIBTIFFDIR=${libtiff}/include ''; + qmakeFlags = [ + "EXIV2PATH=${exiv2}/include/exiv2" + "OPENEXRDIR=${openexr}/include/OpenEXR" + "FFTW3DIR=${fftwSinglePrec}/include" + "LIBTIFFDIR=${libtiff}/include" + ]; + meta = { homepage = http://qtpfsgui.sourceforge.net/; description = "Qtpfsqui, a graphical application for high dynamic range (HDR) imaging"; From 6995d0193920685294f97f2b79e3c39b14e985ae Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:19 +0300 Subject: [PATCH 063/147] rapcad: move to qmakeHook This reverts commit 38d5c07b1447e807ab4723a271cbfcfece22c3df. --- pkgs/applications/graphics/rapcad/default.nix | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/pkgs/applications/graphics/rapcad/default.nix b/pkgs/applications/graphics/rapcad/default.nix index 90cb360e7d57..d5d6e27219fa 100644 --- a/pkgs/applications/graphics/rapcad/default.nix +++ b/pkgs/applications/graphics/rapcad/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchgit, cgal, boost, gmp, mpfr, flex, bison, dxflib, readline -, qtbase +, qtbase, qmakeHook, mesa_glu }: stdenv.mkDerivation rec { @@ -12,14 +12,7 @@ stdenv.mkDerivation rec { sha256 = "15c18jvgbwyrfhv7r35ih0gzx35vjlsbi984h1sckgh2z17hjq8l"; }; - buildInputs = [ qtbase cgal boost gmp mpfr flex bison dxflib readline ]; - - configurePhase = '' - runHook preConfigure - qmake - sed -e "s@/usr/@$out/@g" -i $(find . -name Makefile) - runHook postConfigure - ''; + buildInputs = [ qtbase qmakeHook cgal boost gmp mpfr flex bison dxflib readline mesa_glu ]; meta = { license = stdenv.lib.licenses.gpl3; From 1237d0b8208c41b11b0fd60fa7cf90b903d764b9 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:20 +0300 Subject: [PATCH 064/147] cool-retro-term: move to qmakeHook This reverts commit 44a2ca4a34ceb49b339ed8828d1ce6c5ecd493af. --- pkgs/applications/misc/cool-retro-term/default.nix | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/pkgs/applications/misc/cool-retro-term/default.nix b/pkgs/applications/misc/cool-retro-term/default.nix index 67b9b601139d..9ffa36adc123 100644 --- a/pkgs/applications/misc/cool-retro-term/default.nix +++ b/pkgs/applications/misc/cool-retro-term/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchgit, makeQtWrapper, qtbase, qtquick1, qmltermwidget, -qtquickcontrols, qtgraphicaleffects }: +qtquickcontrols, qtgraphicaleffects, qmakeHook }: stdenv.mkDerivation rec { version = "1.0.0"; @@ -17,15 +17,9 @@ stdenv.mkDerivation rec { ''; buildInputs = [ qtbase qtquick1 qmltermwidget qtquickcontrols qtgraphicaleffects ]; - nativeBuildInputs = [ makeQtWrapper ]; + nativeBuildInputs = [ makeQtWrapper qmakeHook ]; - configurePhase = '' - runHook preConfigure - qmake PREFIX=$out - runHook postConfigure - ''; - - installPhase = "make -j $NIX_BUILD_CORES INSTALL_ROOT=$out install"; + installFlags = [ "INSTALL_ROOT=$(out)" ]; preFixup = '' mv $out/usr/share $out/share From c6e6944b95900bb6ada78e1d25d3aebe40c9b751 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:31:25 +0300 Subject: [PATCH 065/147] diffpdf: move to qmake4Hook --- pkgs/applications/misc/diffpdf/default.nix | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/misc/diffpdf/default.nix b/pkgs/applications/misc/diffpdf/default.nix index aefa4f755b8e..666c3a40cdcc 100644 --- a/pkgs/applications/misc/diffpdf/default.nix +++ b/pkgs/applications/misc/diffpdf/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4, poppler_qt4 }: +{ stdenv, fetchurl, qt4, poppler_qt4, qmake4Hook }: stdenv.mkDerivation rec { version = "2.1.3"; @@ -12,13 +12,12 @@ stdenv.mkDerivation rec { patches = [ ./fix_path_poppler_qt4.patch ]; buildInputs = [ qt4 poppler_qt4 ]; + nativeBuildInputs = [ qmake4Hook ]; - preBuild = '' + preConfigure = '' substituteInPlace diffpdf.pro --replace @@NIX_POPPLER_QT4@@ ${poppler_qt4} - [ -e "*.qm" ] && make clean lrelease diffpdf.pro - qmake -makefile PREFIX=\$out - ''; + ''; installPhase = '' mkdir -p $out/bin $out/share/man/man1 From 222950f39b2a28faf86b072dc83a7a897ef31d34 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:31:33 +0300 Subject: [PATCH 066/147] evopedia: move to qmake4Hook --- pkgs/applications/misc/evopedia/default.nix | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/misc/evopedia/default.nix b/pkgs/applications/misc/evopedia/default.nix index b7403d4826b2..b235da697d54 100644 --- a/pkgs/applications/misc/evopedia/default.nix +++ b/pkgs/applications/misc/evopedia/default.nix @@ -1,4 +1,4 @@ -{stdenv, fetchgit, bzip2, qt4, libX11}: +{ stdenv, fetchgit, bzip2, qt4, qmake4Hook, libX11 }: stdenv.mkDerivation rec { name = "evopedia-${version}"; @@ -10,11 +10,8 @@ stdenv.mkDerivation rec { sha256 = "1biq9zaj8nhxx1pixidsn97iwp9qy1yslgl0znpa4d4p35jcg48g"; }; - configurePhase = '' - qmake PREFIX=$out - ''; - buildInputs = [ bzip2 qt4 libX11 ]; + nativeBuildInputs = [ qmake4Hook ]; meta = { description = "Offline Wikipedia Viewer"; From b6016fb6dfac2404a4856d5724665c3d4f00ee3e Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:31:57 +0300 Subject: [PATCH 067/147] freicoin: move to qmake4Hook --- pkgs/applications/misc/freicoin/default.nix | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/misc/freicoin/default.nix b/pkgs/applications/misc/freicoin/default.nix index 65265fc07a5a..b4e71d4bbc75 100644 --- a/pkgs/applications/misc/freicoin/default.nix +++ b/pkgs/applications/misc/freicoin/default.nix @@ -1,4 +1,4 @@ -{ fetchurl, stdenv, db, boost, gmp, mpfr, miniupnpc, qt4, unzip }: +{ fetchurl, stdenv, db, boost, gmp, mpfr, miniupnpc, qt4, qmake4Hook, unzip }: stdenv.mkDerivation rec { version = "0.8.3-1"; @@ -11,9 +11,7 @@ stdenv.mkDerivation rec { # I think that openssl and zlib are required, but come through other # packages - buildInputs = [ db boost gmp mpfr miniupnpc qt4 unzip ]; - - configurePhase = "qmake"; + buildInputs = [ db boost gmp mpfr miniupnpc qt4 unzip qmake4Hook ]; installPhase = '' mkdir -p $out/bin From b6717f466be7d12f34d70299fa9b2fed83104814 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:32:05 +0300 Subject: [PATCH 068/147] goldendict: move to qmake4Hook --- pkgs/applications/misc/goldendict/default.nix | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/misc/goldendict/default.nix b/pkgs/applications/misc/goldendict/default.nix index 9a7fad6a2074..36840c656d34 100644 --- a/pkgs/applications/misc/goldendict/default.nix +++ b/pkgs/applications/misc/goldendict/default.nix @@ -1,4 +1,5 @@ -{ stdenv, fetchFromGitHub, pkgconfig, qt4, libXtst, libvorbis, hunspell, libao, ffmpeg, libeb, lzo, xz, libtiff }: +{ stdenv, fetchFromGitHub, pkgconfig, qt4, qmake4Hook, libXtst, libvorbis, hunspell +, libao, ffmpeg, libeb, lzo, xz, libtiff }: stdenv.mkDerivation rec { name = "goldendict-1.5.0.ec86515"; src = fetchFromGitHub { @@ -8,10 +9,12 @@ stdenv.mkDerivation rec { sha256 = "070majwxbn15cy7sbgz7ljl8rkn7vcgkm10884v97csln7bfzwhr"; }; - buildInputs = [ pkgconfig qt4 libXtst libvorbis hunspell libao ffmpeg libeb lzo xz libtiff ]; - configurePhase = '' - qmake PREFIX=$out 'CONFIG+=zim_support' - ''; + buildInputs = [ + pkgconfig qt4 libXtst libvorbis hunspell libao ffmpeg libeb + lzo xz libtiff qmake4Hook + ]; + + qmakeFlags = [ "CONFIG+=zim_support" ]; meta = { homepage = http://goldendict.org/; From f02e4a72552a346cc309205d20d38f3577839774 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:32:55 +0300 Subject: [PATCH 069/147] gqrx: move to qmake4Hook --- pkgs/applications/misc/gqrx/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/misc/gqrx/default.nix b/pkgs/applications/misc/gqrx/default.nix index d30b6b8e8f96..3fda4d8881af 100644 --- a/pkgs/applications/misc/gqrx/default.nix +++ b/pkgs/applications/misc/gqrx/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, qt4, gnuradio, boost, gnuradio-osmosdr +{ stdenv, fetchFromGitHub, qt4, qmake4Hook, gnuradio, boost, gnuradio-osmosdr # drivers (optional): , rtl-sdr, hackrf , pulseaudioSupport ? true, libpulseaudio @@ -17,12 +17,12 @@ stdenv.mkDerivation rec { sha256 = "02pavd1kc0gsnrl18bfa01r2f3j4j05zly4a8zwss9yrsgf8432x"; }; + nativeBuildInputs = [ qmake4Hook ]; + buildInputs = [ qt4 gnuradio boost gnuradio-osmosdr rtl-sdr hackrf ] ++ stdenv.lib.optionals pulseaudioSupport [ libpulseaudio ]; - configurePhase = ''qmake PREFIX="$out"''; - enableParallelBuilding = true; postInstall = '' From 7a57ce0fbb2bc8c23a2a1a7126d770fdf57b8b48 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:33:06 +0300 Subject: [PATCH 070/147] keepassx: move to qmake4Hook --- pkgs/applications/misc/keepassx/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/misc/keepassx/default.nix b/pkgs/applications/misc/keepassx/default.nix index 3d078d59be62..d0bddbc16102 100644 --- a/pkgs/applications/misc/keepassx/default.nix +++ b/pkgs/applications/misc/keepassx/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, bzip2, qt4, libX11, xextproto, libXtst }: +{ stdenv, fetchurl, bzip2, qt4, qmake4Hook, libX11, xextproto, libXtst }: stdenv.mkDerivation rec { name = "keepassx-${version}"; @@ -9,14 +9,12 @@ stdenv.mkDerivation rec { sha256 = "1i5dq10x28mg7m4c0yacm32xfj4j7imir4ph8x9p0s2ym260c9ry"; }; - configurePhase = '' - qmake PREFIX=$out - ''; - patches = [ ./random.patch ]; buildInputs = [ bzip2 qt4 libX11 xextproto libXtst ]; + nativeBuildInputs = [ qmake4Hook ]; + meta = { description = "Qt password manager compatible with its Win32 and Pocket PC versions"; homepage = http://www.keepassx.org/; From eb386da6da15cce5c37c2c130731130ef81c98b4 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:33:19 +0300 Subject: [PATCH 071/147] librecad: move to qmake4Hook --- pkgs/applications/misc/librecad/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/misc/librecad/default.nix b/pkgs/applications/misc/librecad/default.nix index b41ef70394ec..d5c04ba555a1 100644 --- a/pkgs/applications/misc/librecad/default.nix +++ b/pkgs/applications/misc/librecad/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4, muparser, which, boost, pkgconfig }: +{ stdenv, fetchurl, qt4, qmake4Hook, muparser, which, boost, pkgconfig }: stdenv.mkDerivation rec { version = "2.0.9"; @@ -15,9 +15,7 @@ stdenv.mkDerivation rec { sed -i -e s,/usr/share,$out/share, librecad/src/lib/engine/rs_system.cpp ''; - configurePhase = '' - qmake librecad.pro PREFIX=$out MUPARSER_DIR=${muparser} BOOST_DIR=${boost.dev} - ''; + qmakeFlags = [ "MUPARSER_DIR=${muparser}" "BOOST_DIR=${boost.dev}" ]; installPhase = '' mkdir -p $out/bin $out/share @@ -26,7 +24,7 @@ stdenv.mkDerivation rec { ''; buildInputs = [ qt4 muparser which boost ]; - nativeBuildInputs = [ pkgconfig ]; + nativeBuildInputs = [ pkgconfig qmake4Hook ]; enableParallelBuilding = true; From b9d23f492b6c9cd5d1499e88cfe458026dab05ec Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:33:35 +0300 Subject: [PATCH 072/147] merkaartor: move to qmake4Hook --- pkgs/applications/misc/merkaartor/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/misc/merkaartor/default.nix b/pkgs/applications/misc/merkaartor/default.nix index a270dca910ca..5954316e50fe 100644 --- a/pkgs/applications/misc/merkaartor/default.nix +++ b/pkgs/applications/misc/merkaartor/default.nix @@ -1,4 +1,4 @@ -{stdenv, fetchurl, qt4, boost, proj, gdal_1_11}: +{ stdenv, fetchurl, qt4, qmake4Hook, boost, proj, gdal_1_11 }: stdenv.mkDerivation rec { name = "merkaartor-0.18.1"; @@ -7,12 +7,10 @@ stdenv.mkDerivation rec { sha256 = "17qk45pmlxqigla1915dvn9pp91y85d2bkcaap4g3m8mk1crcsix"; }; - configurePhase = '' - qmake -makefile PREFIX=$out - ''; - buildInputs = [ qt4 boost proj gdal_1_11 ]; + nativeBuildInputs = [ qmake4Hook ]; + meta = { description = "An openstreetmap editor"; homepage = http://merkaartor.org/; From fbb92639810632efaead4013d387651ce0cb6fb4 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:33:50 +0300 Subject: [PATCH 073/147] multimon-ng: move to qmake4Hook --- pkgs/applications/misc/multimon-ng/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/misc/multimon-ng/default.nix b/pkgs/applications/misc/multimon-ng/default.nix index f9aa567ed4b5..a9f0cb2511a4 100644 --- a/pkgs/applications/misc/multimon-ng/default.nix +++ b/pkgs/applications/misc/multimon-ng/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, qt4, libpulseaudio }: +{ stdenv, fetchFromGitHub, qt4, qmake4Hook, libpulseaudio }: let version = "1.0.0"; in @@ -14,7 +14,7 @@ stdenv.mkDerivation { buildInputs = [ qt4 libpulseaudio ]; - preBuild = "qmake multimon-ng.pro"; + nativeBuildInputs = [ qmake4Hook ]; installPhase = '' mkdir -p $out/bin From e9e112817d70eee0d17919b2af7cf39b9c806446 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:34:13 +0300 Subject: [PATCH 074/147] navipowm: move to qmake4Hook --- pkgs/applications/misc/navipowm/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/misc/navipowm/default.nix b/pkgs/applications/misc/navipowm/default.nix index 6d990831a369..447fc4570a76 100644 --- a/pkgs/applications/misc/navipowm/default.nix +++ b/pkgs/applications/misc/navipowm/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4 }: +{ stdenv, fetchurl, qt4, qmake4Hook }: stdenv.mkDerivation rec { name = "navipowm-0.2.4"; @@ -7,9 +7,8 @@ stdenv.mkDerivation rec { sha256 = "1kdih8kwpgcgfh6l6njkr9gq2j5hv39xvzmzgvhip553kn6bss7b"; }; - configurePhase = '' + preConfigure = '' cd Qt/KDevelop - qmake ''; installPhase = '' @@ -20,6 +19,7 @@ stdenv.mkDerivation rec { ''; buildInputs = [ qt4 ]; + nativeBuildInputs = [ qmake4Hook ]; meta = { homepage = http://navipowm.sourceforge.net/; From 4e1d2d9afb34cc2bf4cb14a4262848c1f24279a4 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:34:22 +0300 Subject: [PATCH 075/147] openbrf: move to qmake4Hook --- pkgs/applications/misc/openbrf/default.nix | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/misc/openbrf/default.nix b/pkgs/applications/misc/openbrf/default.nix index 478f02b970e5..70be67a4d288 100644 --- a/pkgs/applications/misc/openbrf/default.nix +++ b/pkgs/applications/misc/openbrf/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, qt4, vcg, glew }: +{ stdenv, fetchFromGitHub, qt4, qmake4Hook, vcg, glew }: stdenv.mkDerivation { name = "openbrf-2016-01-09"; @@ -10,18 +10,16 @@ stdenv.mkDerivation { sha256 = "0laikpz0ljz7l5fgapwj09ygizmvj1iywnpfgfd0i14j46s134xb"; }; - buildInputs = [ qt4 vcg glew ]; + buildInputs = [ qt4 qmake4Hook vcg glew ]; enableParallelBuilding = true; + qmakeFlags = [ "openBrf.pro" ]; + postPatch = '' sed -i 's,^VCGLIB .*,VCGLIB = ${vcg}/include,' openBrf.pro ''; - configurePhase = '' - qmake PREFIX=$out openBrf.pro - ''; - installPhase = '' install -Dm755 openBrf $out/bin/openBrf ''; From eeffa2202a6652e67a3fa2c6ba1234b2e963d530 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:34:33 +0300 Subject: [PATCH 076/147] qtbitcointrader: move to qmake4Hook --- .../applications/misc/qtbitcointrader/default.nix | 15 ++++++++------- pkgs/top-level/all-packages.nix | 4 +--- 2 files changed, 9 insertions(+), 10 deletions(-) diff --git a/pkgs/applications/misc/qtbitcointrader/default.nix b/pkgs/applications/misc/qtbitcointrader/default.nix index 8b527463b228..7de4e3e55a19 100644 --- a/pkgs/applications/misc/qtbitcointrader/default.nix +++ b/pkgs/applications/misc/qtbitcointrader/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, qt }: +{ stdenv, fetchFromGitHub, qt4, qmake4Hook }: let version = "1.08.03"; @@ -13,23 +13,24 @@ stdenv.mkDerivation { sha256 = "0kxb0n11agqid0nyqdspfndm03b8l0nl8x4yx2hsrizs6m5z08h4"; }; - buildInputs = [ qt ]; + buildInputs = [ qt4 ]; + + nativeBuildHooks = [ qmake4Hook ]; postUnpack = "sourceRoot=\${sourceRoot}/src"; - configurePhase = '' - qmake \ - PREFIX=$out \ + preConfigure = '' + qmakeFlags="$qmakeFlags \ DESKTOPDIR=$out/share/applications \ ICONDIR=$out/share/pixmaps \ - QtBitcoinTrader_Desktop.pro + " ''; meta = with stdenv.lib; { description = "Secure bitcoin trading client"; homepage = https://centrabit.com/; license = licenses.lgpl3; - platforms = qt.meta.platforms; + platforms = qt4.meta.platforms; maintainers = [ maintainers.ehmry ]; }; } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 90d766c925a7..7ed4d8859c7f 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -14584,9 +14584,7 @@ in qgroundcontrol = qt55.callPackage ../applications/science/robotics/qgroundcontrol { }; - qtbitcointrader = callPackage ../applications/misc/qtbitcointrader { - qt = qt4; - }; + qtbitcointrader = callPackage ../applications/misc/qtbitcointrader { }; pahole = callPackage ../development/tools/misc/pahole {}; From f3384e5ea9fbef6eeaad3f1046c1193d81dd2b05 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:19 +0300 Subject: [PATCH 077/147] qtpass: move to qmakeHook This reverts commit 0cfff33f59131ec124b0e1c0de2a8a69ef4af896. --- pkgs/applications/misc/qtpass/default.nix | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/misc/qtpass/default.nix b/pkgs/applications/misc/qtpass/default.nix index 69730759d084..15f249ac9061 100644 --- a/pkgs/applications/misc/qtpass/default.nix +++ b/pkgs/applications/misc/qtpass/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, git, gnupg, makeQtWrapper, pass, qtbase, qtsvg, qttools }: +{ stdenv, fetchurl, git, gnupg, makeQtWrapper, pass, qtbase, qtsvg, qttools, qmakeHook }: stdenv.mkDerivation rec { name = "qtpass-${version}"; @@ -9,12 +9,10 @@ stdenv.mkDerivation rec { sha256 = "60b458062f54184057e55dbd9c93958a8bf845244ffd70b9cb31bf58697f0dc6"; }; - buildInputs = [ git gnupg makeQtWrapper pass qtbase qtsvg qttools ]; + buildInputs = [ git gnupg makeQtWrapper pass qtbase qtsvg qttools qmakeHook ]; - configurePhase = '' - runHook preConfigure - qmake CONFIG+=release PREFIX=$out DESTDIR=$out - runHook postConfigure + preConfigure = '' + qmakeFlags="$qmakeFlags CONFIG+=release DESTDIR=$out" ''; installPhase = '' From bc428f9429d0b5ac31e99cc190195749070945fd Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:34:52 +0300 Subject: [PATCH 078/147] tpmmanager: move to qmake4Hook --- pkgs/applications/misc/tpmmanager/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/misc/tpmmanager/default.nix b/pkgs/applications/misc/tpmmanager/default.nix index 85a1c72b349d..09322b47506b 100644 --- a/pkgs/applications/misc/tpmmanager/default.nix +++ b/pkgs/applications/misc/tpmmanager/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchgit, qt4, trousers }: +{ stdenv, fetchgit, qt4, qmake4Hook, trousers }: stdenv.mkDerivation rec { version = "0.8.1"; @@ -10,11 +10,9 @@ stdenv.mkDerivation rec { sha256 = "24a606f88fed67ed0d0e61dc220295e9e1ab8db3ef3d028fa34b04ff30652d8e"; }; - buildInputs = [ qt4 trousers ]; + nativeBuildInputs = [ qmake4Hook ]; - preBuild = '' - qmake -makefile PREFIX=\$out - ''; + buildInputs = [ qt4 trousers ]; installPhase = '' mkdir -p $out/bin From 9f3368e52d1fa1445fa88b07df7b0961b00413eb Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:18 +0300 Subject: [PATCH 079/147] twmn: move to qmakeHook This reverts commit fab7c7edbf5ad756b60c975dd6c4fd0362719e13. --- pkgs/applications/misc/twmn/default.nix | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/misc/twmn/default.nix b/pkgs/applications/misc/twmn/default.nix index fbbf45877d23..665e23237d8e 100644 --- a/pkgs/applications/misc/twmn/default.nix +++ b/pkgs/applications/misc/twmn/default.nix @@ -1,4 +1,4 @@ -{ fetchurl, stdenv, fetchgit, qtbase, qtx11extras, pkgconfig, boost }: +{ fetchurl, stdenv, fetchgit, qtbase, qtx11extras, qmakeHook, pkgconfig, boost }: stdenv.mkDerivation rec { name = "twmn-git-2014-09-23"; @@ -9,13 +9,10 @@ stdenv.mkDerivation rec { sha256 = "9c91e9d3d6d7f9d90d34da6f1a4b9f3dee65605c1e43729417d6921c54dded6b"; }; - buildInputs = [ qtbase qtx11extras pkgconfig boost ]; + buildInputs = [ qtbase qtx11extras pkgconfig boost qmakeHook ]; - configurePhase = '' - runHook preConfigure + postPatch = '' sed -i s/-Werror// twmnd/twmnd.pro - qmake - runHook postConfigure ''; installPhase = '' From 23e3372feafc40a389aa19852a8c2e56aac542c9 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:35:11 +0300 Subject: [PATCH 080/147] vym: move to qmake4Hook --- pkgs/applications/misc/vym/default.nix | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/misc/vym/default.nix b/pkgs/applications/misc/vym/default.nix index 62f741f9eeac..97fa47399f50 100644 --- a/pkgs/applications/misc/vym/default.nix +++ b/pkgs/applications/misc/vym/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, pkgconfig, qt4 }: +{ stdenv, fetchurl, pkgconfig, qt4, qmake4Hook }: stdenv.mkDerivation rec { name = "vym-${version}"; @@ -9,11 +9,7 @@ stdenv.mkDerivation rec { sha256 = "1x4qp6wpszscbbs4czkfvskm7qjglvxm813nqv281bpy4y1hhvgs"; }; - buildInputs = [ pkgconfig qt4 ]; - - configurePhase = '' - qmake PREFIX="$out" - ''; + buildInputs = [ pkgconfig qt4 qmake4Hook ]; meta = with stdenv.lib; { description = "A mind-mapping software"; From bab152826fee66f0518660067198a77e41ac9af7 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:35:18 +0300 Subject: [PATCH 081/147] arora: move to qmake4Hook --- pkgs/applications/networking/browsers/arora/default.nix | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/networking/browsers/arora/default.nix b/pkgs/applications/networking/browsers/arora/default.nix index d812078b6aad..8bcefe4fe7b0 100644 --- a/pkgs/applications/networking/browsers/arora/default.nix +++ b/pkgs/applications/networking/browsers/arora/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4 }: +{ stdenv, fetchurl, qt4, qmake4Hook }: stdenv.mkDerivation rec { name = "arora-${version}"; @@ -10,8 +10,7 @@ stdenv.mkDerivation rec { }; buildInputs = [ qt4 ]; - - configurePhase = "qmake PREFIX=$out"; + nativeBuildInputs = [ qmake4Hook ]; meta = with stdenv.lib; { platforms = qt4.meta.platforms; From 87397b770c4b9dbd2faef8c6c2df021048c2aa83 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:35:28 +0300 Subject: [PATCH 082/147] qtox: move to qmakeHook --- .../instant-messengers/qtox/default.nix | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/qtox/default.nix b/pkgs/applications/networking/instant-messengers/qtox/default.nix index e08a112664ac..d244c4d11c41 100644 --- a/pkgs/applications/networking/instant-messengers/qtox/default.nix +++ b/pkgs/applications/networking/instant-messengers/qtox/default.nix @@ -1,7 +1,7 @@ { stdenv, fetchFromGitHub, pkgconfig, libtoxcore-dev, openal, opencv, libsodium, libXScrnSaver, glib, gdk_pixbuf, gtk2, cairo, - pango, atk, qrencode, ffmpeg, filter-audio, makeWrapper, - qtbase, qtsvg, qttools, qttranslations, sqlcipher }: + pango, atk, qrencode, ffmpeg, filter-audio, makeQtWrapper, + qtbase, qtsvg, qttools, qmakeHook, qttranslations, sqlcipher }: let version = "1.3.0"; @@ -22,11 +22,11 @@ stdenv.mkDerivation rec { [ libtoxcore-dev openal opencv libsodium filter-audio qtbase qttools qtsvg libXScrnSaver glib gtk2 cairo - pango atk qrencode ffmpeg qttranslations makeWrapper + pango atk qrencode ffmpeg qttranslations makeQtWrapper sqlcipher ]; - nativeBuildInputs = [ pkgconfig ]; + nativeBuildInputs = [ pkgconfig qmakeHook ]; preConfigure = '' # patch .pro file for proper set of the git hash @@ -42,16 +42,10 @@ stdenv.mkDerivation rec { export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE $(pkg-config --cflags sqlcipher)" ''; - configurePhase = '' - runHook preConfigure - qmake - ''; - installPhase = '' mkdir -p $out/bin cp qtox $out/bin - wrapProgram $out/bin/qtox \ - --prefix QT_PLUGIN_PATH : ${qtsvg}/lib/qt5/plugins + wrapQtProgram $out/bin/qtox ''; enableParallelBuilding = true; From 46cf871c3d40ec8f7774302e3e2cb7c9c371053c Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:35:53 +0300 Subject: [PATCH 083/147] ricochet: move to qmakeHook --- .../networking/instant-messengers/ricochet/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/ricochet/default.nix b/pkgs/applications/networking/instant-messengers/ricochet/default.nix index 81e8d1b76a9c..52da021000db 100644 --- a/pkgs/applications/networking/instant-messengers/ricochet/default.nix +++ b/pkgs/applications/networking/instant-messengers/ricochet/default.nix @@ -1,6 +1,6 @@ { stdenv, fetchurl, pkgconfig, makeDesktopItem, unzip , qtbase, qttools, makeQtWrapper, qtmultimedia, qtquick1, qtquickcontrols -, openssl, protobuf +, openssl, protobuf, qmakeHook }: stdenv.mkDerivation rec { @@ -27,15 +27,13 @@ stdenv.mkDerivation rec { openssl protobuf ]; - nativeBuildInputs = [ pkgconfig makeQtWrapper ]; + nativeBuildInputs = [ pkgconfig makeQtWrapper qmakeHook ]; preConfigure = '' export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE $(pkg-config --cflags openssl)" ''; - configureScript = "qmake"; - dontAddPrefix = true; - configureFlags = [ "PREFIX=$(out)" "DEFINES+=RICOCHET_NO_PORTABLE" ]; + qmakeFlags = [ "DEFINES+=RICOCHET_NO_PORTABLE" ]; installPhase = '' mkdir -p $out/bin From 5faed29fa8f4c437bbf0d8ecbf045cadecf6e172 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:20 +0300 Subject: [PATCH 084/147] cutegram: move to qmakeHook This reverts commit 7f4ab1cb72cc4779b91384474b6b23e4744033d1. --- .../instant-messengers/telegram/cutegram/default.nix | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/telegram/cutegram/default.nix b/pkgs/applications/networking/instant-messengers/telegram/cutegram/default.nix index 07bfcf3a03e0..bc517cadf522 100644 --- a/pkgs/applications/networking/instant-messengers/telegram/cutegram/default.nix +++ b/pkgs/applications/networking/instant-messengers/telegram/cutegram/default.nix @@ -3,7 +3,7 @@ , qtimageformats, qtgraphicaleffects , telegram-qml, libqtelegram-aseman-edition , gst_all_1 -, makeQtWrapper }: +, makeQtWrapper, qmakeHook }: stdenv.mkDerivation rec { name = "cutegram-${meta.version}"; @@ -20,16 +20,10 @@ stdenv.mkDerivation rec { telegram-qml libqtelegram-aseman-edition ] ++ (with gst_all_1; [ gst-plugins-base gst-plugins-good gst-plugins-bad gst-plugins-ugly ]); - nativeBuildInputs = [ makeQtWrapper ]; + nativeBuildInputs = [ makeQtWrapper qmakeHook ]; enableParallelBuilding = true; - configurePhase = '' - runHook preConfigure - qmake -r PREFIX=$out - runHook postConfigure - ''; - fixupPhase = '' wrapQtProgram $out/bin/cutegram \ --prefix GST_PLUGIN_SYSTEM_PATH_1_0 : "$GST_PLUGIN_SYSTEM_PATH_1_0" From 56b63b91b425ed846867959441b07618a0a50406 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:20 +0300 Subject: [PATCH 085/147] libqtelegram-aseman-edition: move to qmakeHook This reverts commit 080b54d766dbbcdad3cf3998585788510510cefd. --- .../telegram/libqtelegram-aseman-edition/default.nix | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/telegram/libqtelegram-aseman-edition/default.nix b/pkgs/applications/networking/instant-messengers/telegram/libqtelegram-aseman-edition/default.nix index 470724876ed9..322c40afc7dc 100644 --- a/pkgs/applications/networking/instant-messengers/telegram/libqtelegram-aseman-edition/default.nix +++ b/pkgs/applications/networking/instant-messengers/telegram/libqtelegram-aseman-edition/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchFromGitHub -, qtbase, qtmultimedia, qtquick1 }: +, qtbase, qtmultimedia, qtquick1, qmakeHook }: stdenv.mkDerivation rec { name = "libqtelegram-aseman-edition-${meta.version}"; @@ -12,6 +12,7 @@ stdenv.mkDerivation rec { }; buildInputs = [ qtbase qtmultimedia qtquick1 ]; + nativeBuildInputs = [ qmakeHook ]; enableParallelBuilding = true; patchPhase = '' @@ -19,12 +20,6 @@ stdenv.mkDerivation rec { substituteInPlace libqtelegram-ae.pro --replace "/\$\$LIB_PATH" "" ''; - configurePhase = '' - runHook preConfigure - qmake -r PREFIX=$out - runHook postConfigure - ''; - meta = with stdenv.lib; { version = "6.1"; description = "A fork of libqtelegram by Aseman, using qmake"; From 82bf15393d1af2cc2ce0309a4774a9f26d1d2571 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:36:28 +0300 Subject: [PATCH 086/147] tdesktop: move to qmakeHook --- .../instant-messengers/telegram/tdesktop/default.nix | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/telegram/tdesktop/default.nix b/pkgs/applications/networking/instant-messengers/telegram/tdesktop/default.nix index 77a0d9ee0aac..e734ddc57009 100644 --- a/pkgs/applications/networking/instant-messengers/telegram/tdesktop/default.nix +++ b/pkgs/applications/networking/instant-messengers/telegram/tdesktop/default.nix @@ -1,7 +1,7 @@ { stdenv, lib, fetchFromGitHub, fetchgit, qtbase, qtimageformats , breakpad, ffmpeg, openalSoft, openssl, zlib, libexif, lzma, libopus , gtk2, glib, cairo, pango, gdk_pixbuf, atk, libappindicator-gtk2 -, libunity, dee, libdbusmenu-glib, libva +, libunity, dee, libdbusmenu-glib, libva, qmakeHook , pkgconfig, libxcb, xcbutilwm, xcbutilimage, xcbutilkeysyms , libxkbcommon, libpng, libjpeg, freetype, harfbuzz, pcre16 @@ -31,7 +31,7 @@ in stdenv.mkDerivation rec { buildInputs = [ breakpad ffmpeg openalSoft openssl zlib libexif lzma libopus gtk2 glib libappindicator-gtk2 libunity cairo pango gdk_pixbuf atk - dee libdbusmenu-glib libva + dee libdbusmenu-glib libva qmakeHook # Qt dependencies libxcb xcbutilwm xcbutilimage xcbutilkeysyms libxkbcommon libpng libjpeg freetype harfbuzz pcre16 xproto libX11 @@ -73,10 +73,9 @@ in stdenv.mkDerivation rec { qtSrcs = qtbase.srcs ++ [ qtimageformats.src ]; qtPatches = qtbase.patches; - buildCommand = '' - # We don't use nativeBuildInputs to avoid adding system Qt 5 libraries to various paths. - export PATH="${qtbase}/bin:$PATH" + dontUseQmakeConfigure = true; + buildCommand = '' unpackPhase cd "$sourceRoot" patchPhase From a6af80b42102a8879ef72daacbc02d4323948e2a Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:20 +0300 Subject: [PATCH 087/147] telegram-qml: move to qmakeHook This reverts commit c275fc610e087a416d018cd63ff420d724f0bbc2. --- .../instant-messengers/telegram/telegram-qml/default.nix | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/telegram/telegram-qml/default.nix b/pkgs/applications/networking/instant-messengers/telegram/telegram-qml/default.nix index 5412b0db4d6b..854648d97862 100644 --- a/pkgs/applications/networking/instant-messengers/telegram/telegram-qml/default.nix +++ b/pkgs/applications/networking/instant-messengers/telegram/telegram-qml/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchFromGitHub -, qtbase, qtmultimedia, qtquick1 +, qtbase, qtmultimedia, qtquick1, qmakeHook , libqtelegram-aseman-edition }: stdenv.mkDerivation rec { @@ -13,6 +13,7 @@ stdenv.mkDerivation rec { }; propagatedBuildInputs = [ qtbase qtmultimedia qtquick1 libqtelegram-aseman-edition ]; + nativeBuildInputs = [ qmakeHook ]; enableParallelBuilding = true; patchPhase = '' @@ -20,11 +21,7 @@ stdenv.mkDerivation rec { substituteInPlace telegramqml.pro --replace "INSTALL_HEADERS_PREFIX/telegramqml" "INSTALL_HEADERS_PREFIX" ''; - configurePhase = '' - runHook preConfigure - qmake -r PREFIX=$out BUILD_MODE+=lib - runHook postConfigure - ''; + qmakeFlags = [ "BUILD_MODE+=lib" ]; meta = with stdenv.lib; { version = "0.9.2"; From 837c573f2718ca18a352f6699b5ff3e3ff133c8f Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:36:53 +0300 Subject: [PATCH 088/147] vacuum: move to qmake4Hook --- .../networking/instant-messengers/vacuum/default.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/vacuum/default.nix b/pkgs/applications/networking/instant-messengers/vacuum/default.nix index d7798273e7c6..2b5ce5f4142c 100644 --- a/pkgs/applications/networking/instant-messengers/vacuum/default.nix +++ b/pkgs/applications/networking/instant-messengers/vacuum/default.nix @@ -1,5 +1,5 @@ { stdenv, lib, fetchurl - , qt4, openssl + , qt4, qmake4Hook, openssl , xproto, libX11, libXScrnSaver, scrnsaverproto , xz, zlib }: @@ -16,8 +16,10 @@ stdenv.mkDerivation rec { qt4 openssl xproto libX11 libXScrnSaver scrnsaverproto xz zlib ]; - configurePhase = '' - qmake INSTALL_PREFIX=$out -recursive vacuum.pro + nativeBuildInputs = [ qmake4Hook ]; + + preConfigure = '' + qmakeFlags="$qmakeFlags INSTALL_PREFIX=$out" ''; meta = with stdenv.lib; { From 6b6768f455667f7006bcdaeec9c01293a23b86f7 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:20 +0300 Subject: [PATCH 089/147] communi: move to qmakeHook This reverts commit 0fefa9939e5db2057d9e6418cb68946ca2a12721. --- .../applications/networking/irc/communi/default.nix | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/pkgs/applications/networking/irc/communi/default.nix b/pkgs/applications/networking/irc/communi/default.nix index 4d2605acdc9e..4a8dc44dbf92 100644 --- a/pkgs/applications/networking/irc/communi/default.nix +++ b/pkgs/applications/networking/irc/communi/default.nix @@ -1,4 +1,4 @@ -{ fetchgit, libcommuni, makeQtWrapper, qt5, stdenv }: +{ fetchgit, libcommuni, makeQtWrapper, qtbase, qmakeHook, stdenv }: stdenv.mkDerivation rec { name = "communi-${version}"; @@ -10,23 +10,22 @@ stdenv.mkDerivation rec { sha256 = "0gk6gck09zb44qfsal7bs4ln2vl9s9x3vfxh7jvfc7mmf7l3sspd"; }; - nativeBuildInputs = [ makeQtWrapper ]; + nativeBuildInputs = [ makeQtWrapper qmakeHook ]; - buildInputs = [ libcommuni qt5.qtbase ]; + buildInputs = [ libcommuni qtbase ]; enableParallelBuild = true; - configurePhase = '' - runHook preConfigure + preConfigure = '' export QMAKEFEATURES=${libcommuni}/features - qmake -r \ + qmakeFlags="$qmakeFlags \ COMMUNI_INSTALL_PREFIX=$out \ COMMUNI_INSTALL_BINS=$out/bin \ COMMUNI_INSTALL_PLUGINS=$out/lib/communi/plugins \ COMMUNI_INSTALL_ICONS=$out/share/icons/hicolor \ COMMUNI_INSTALL_DESKTOP=$out/share/applications \ COMMUNI_INSTALL_THEMES=$out/share/communi/themes - runHook postConfigure + " ''; postInstall = '' From d52c326fd0554442372d501488d28be8c0c57d07 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:18 +0300 Subject: [PATCH 090/147] linssid: move to qmakeHook This reverts commit cf3f891369655cd30431bd4f2975a46f8adb0167. --- pkgs/applications/networking/linssid/default.nix | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/pkgs/applications/networking/linssid/default.nix b/pkgs/applications/networking/linssid/default.nix index 4cbc5c8c7967..d35c2e100e4c 100644 --- a/pkgs/applications/networking/linssid/default.nix +++ b/pkgs/applications/networking/linssid/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qtbase, qtsvg, pkgconfig, boost, wirelesstools, iw, qwt6 }: +{ stdenv, fetchurl, qtbase, qtsvg, qmakeHook, pkgconfig, boost, wirelesstools, iw, qwt6 }: stdenv.mkDerivation rec { name = "linssid-${version}"; @@ -9,7 +9,7 @@ stdenv.mkDerivation rec { sha256 = "13d35rlcjncd8lx3khkgn9x8is2xjd5fp6ns5xsn3w6l4xj9b4gl"; }; - buildInputs = [ qtbase qtsvg pkgconfig boost qwt6 ]; + buildInputs = [ qtbase qtsvg pkgconfig boost qwt6 qmakeHook ]; patches = [ ./0001-unbundled-qwt.patch ]; @@ -27,12 +27,6 @@ stdenv.mkDerivation rec { rm -fr qwt-lib ''; - configurePhase = '' - runHook preConfigure - qmake linssid.pro - runHook postConfigure - ''; - meta = with stdenv.lib; { description = "Graphical wireless scanning for Linux"; homepage = http://sourceforge.net/projects/linssid/; From 3c52b4253cd468be7af4291a7c2a051e90a49b83 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:38:29 +0300 Subject: [PATCH 091/147] mumble: move to qmake{,4}Hook --- pkgs/applications/networking/mumble/default.nix | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/pkgs/applications/networking/mumble/default.nix b/pkgs/applications/networking/mumble/default.nix index 646e3dfdd0bb..20a321595201 100644 --- a/pkgs/applications/networking/mumble/default.nix +++ b/pkgs/applications/networking/mumble/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, fetchgit, pkgconfig -, qt4, qt5, avahi, boost, libopus, libsndfile, protobuf, speex, libcap +, qt4, qmake4Hook, qt5, avahi, boost, libopus, libsndfile, protobuf, speex, libcap , alsaLib , jackSupport ? false, libjack2 ? null , speechdSupport ? false, speechd ? null @@ -20,13 +20,13 @@ let patches = optional jackSupport ./mumble-jack-support.patch; nativeBuildInputs = [ pkgconfig ] - ++ { qt4 = [ qt4 ]; qt5 = [ qt5.qtbase ]; }."qt${toString source.qtVersion}" + ++ { qt4 = [ qmake4Hook ]; qt5 = [ qt5.qmakeHook ]; }."qt${toString source.qtVersion}" ++ (overrides.nativeBuildInputs or [ ]); buildInputs = [ boost protobuf avahi ] ++ { qt4 = [ qt4 ]; qt5 = [ qt5.qtbase ]; }."qt${toString source.qtVersion}" ++ (overrides.buildInputs or [ ]); - configureFlags = [ + qmakeFlags = [ "CONFIG+=shared" "CONFIG+=no-g15" "CONFIG+=packaged" @@ -39,10 +39,8 @@ let ++ optional jackSupport "CONFIG+=no-oss CONFIG+=no-alsa CONFIG+=jackaudio" ++ (overrides.configureFlags or [ ]); - configurePhase = '' - runHook preConfigure - qmake $configureFlags DEFINES+="PLUGIN_PATH=$out/lib" - runHook postConfigure + preConfigure = '' + qmakeFlags="$qmakeFlags DEFINES+=PLUGIN_PATH=$out/lib" ''; makeFlags = [ "release" ]; From a1fc9606f2ac655408605cc723cd2a3c3317a84c Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:38:45 +0300 Subject: [PATCH 092/147] ostrinato: move to qmake4Hook --- pkgs/applications/networking/ostinato/default.nix | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/networking/ostinato/default.nix b/pkgs/applications/networking/ostinato/default.nix index 1d5986dbfa64..022096450458 100644 --- a/pkgs/applications/networking/ostinato/default.nix +++ b/pkgs/applications/networking/ostinato/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchgit, fetchurl, writeText -, qt4, protobuf, libpcap +, qt4, qmake4Hook, protobuf, libpcap , wireshark, gzip, diffutils, gawk }: @@ -18,10 +18,9 @@ stdenv.mkDerivation rec { buildInputs = [ qt4 protobuf libpcap ]; - patches = [ ./drone_ini.patch ]; + nativeBuildInputs = [ qmake4Hook ]; - configurePhase = "qmake PREFIX=$out" - + stdenv.lib.optionalString stdenv.isDarwin " -spec macx-g++"; + patches = [ ./drone_ini.patch ]; postInstall = '' cat > $out/bin/ostinato.ini < Date: Sun, 17 Apr 2016 02:39:12 +0300 Subject: [PATCH 093/147] retroshare06: move to qmake4Hook --- pkgs/applications/networking/p2p/retroshare/0.6.nix | 10 +++++----- pkgs/top-level/all-packages.nix | 4 +--- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/pkgs/applications/networking/p2p/retroshare/0.6.nix b/pkgs/applications/networking/p2p/retroshare/0.6.nix index 020d00170531..67028fb5dec1 100644 --- a/pkgs/applications/networking/p2p/retroshare/0.6.nix +++ b/pkgs/applications/networking/p2p/retroshare/0.6.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, cmake, qt, libupnp, gpgme, gnome3, glib, libssh, pkgconfig, protobuf, bzip2 +{ stdenv, fetchFromGitHub, cmake, qt4, qmake4Hook, libupnp, gpgme, gnome3, glib, libssh, pkgconfig, protobuf, bzip2 , libXScrnSaver, speex, curl, libxml2, libxslt, sqlcipher, libmicrohttpd, opencv }: stdenv.mkDerivation { @@ -11,7 +11,7 @@ stdenv.mkDerivation { sha256 = "189qndkfq9kgv3qi3wx8ivla4j8fxr4iv7c8y9rjrjaz8jwdkn5x"; }; - NIX_CFLAGS_COMPILE = "-I${glib.dev}/include/glib-2.0 -I${glib.dev}/lib/glib-2.0/include -I${libxml2.dev}/include/libxml2 -I${sqlcipher}/include/sqlcipher"; + NIX_CFLAGS_COMPILE = [ "-I${glib.dev}/include/glib-2.0" "-I${glib.dev}/lib/glib-2.0/include" "-I${libxml2.dev}/include/libxml2" "-I${sqlcipher}/include/sqlcipher" ]; patchPhase = '' # Fix build error @@ -29,11 +29,11 @@ stdenv.mkDerivation { # retroshare-gui/src/retroshare-gui.pro \ # retroshare-nogui/src/retroshare-nogui.pro - buildInputs = [ speex qt libupnp gpgme gnome3.libgnome_keyring glib libssh pkgconfig + buildInputs = [ speex qt4 libupnp gpgme gnome3.libgnome_keyring glib libssh pkgconfig qmake4Hook protobuf bzip2 libXScrnSaver curl libxml2 libxslt sqlcipher libmicrohttpd opencv ]; - configurePhase = '' - qmake PREFIX=$out DESTDIR=$out RetroShare.pro + preConfigure = '' + qmakeFlags="$qmakeFlags DESTDIR=$out" ''; enableParallelBuilding = true; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 7ed4d8859c7f..78c4e3d3fdcc 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -13660,9 +13660,7 @@ in qt = qt4; }; - retroshare06 = lowPrio (callPackage ../applications/networking/p2p/retroshare/0.6.nix { - qt = qt4; - }); + retroshare06 = lowPrio (callPackage ../applications/networking/p2p/retroshare/0.6.nix { }); RhythmDelay = callPackage ../applications/audio/RhythmDelay { }; From 04e1b8eac42c90c213f7ffc880a29b3e78e73f5f Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:39:30 +0300 Subject: [PATCH 094/147] retroshare: move to qmake4Hook --- .../applications/networking/p2p/retroshare/default.nix | 10 +++++----- pkgs/top-level/all-packages.nix | 4 +--- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/pkgs/applications/networking/p2p/retroshare/default.nix b/pkgs/applications/networking/p2p/retroshare/default.nix index e7fe79d66a56..314d0557e9f9 100644 --- a/pkgs/applications/networking/p2p/retroshare/default.nix +++ b/pkgs/applications/networking/p2p/retroshare/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, cmake, qt, libupnp, gpgme, gnome3, glib, libssh, pkgconfig, protobuf, bzip2 +{ stdenv, fetchurl, cmake, qt4, qmake4Hook, libupnp, gpgme, gnome3, glib, libssh, pkgconfig, protobuf, bzip2 , libXScrnSaver, speex, curl, libxml2, libxslt }: stdenv.mkDerivation { @@ -9,7 +9,7 @@ stdenv.mkDerivation { sha256 = "0l2n4pr1hq66q6qa073hrdx3s3d7iw54z8ay1zy82zhk2rwhsavp"; }; - NIX_CFLAGS_COMPILE = "-I${glib.dev}/include/glib-2.0 -I${glib.dev}/lib/glib-2.0/include -I${libxml2.dev}/include/libxml2"; + NIX_CFLAGS_COMPILE = [ "-I${glib.dev}/include/glib-2.0" "-I${glib.dev}/lib/glib-2.0/include" "-I${libxml2.dev}/include/libxml2" ]; patchPhase = '' sed -i 's/UpnpString_get_String(es_event->PublisherUrl)/es_event->PublisherUrl/' \ @@ -22,13 +22,13 @@ stdenv.mkDerivation { libretroshare/src/rsserver/rsinit.cc ''; - buildInputs = [ speex qt libupnp gpgme gnome3.libgnome_keyring glib libssh pkgconfig + buildInputs = [ speex qt4 qmake4Hook libupnp gpgme gnome3.libgnome_keyring glib libssh pkgconfig protobuf bzip2 libXScrnSaver curl libxml2 libxslt ]; sourceRoot = "retroshare-0.5.5/src"; - configurePhase = '' - qmake PREFIX=$out DESTDIR=$out RetroShare.pro + preConfigure = '' + qmakeFlags="$qmakeFlags DESTDIR=$out" ''; postInstall = '' diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 78c4e3d3fdcc..510ccc46e8c2 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -13656,9 +13656,7 @@ in remotebox = callPackage ../applications/virtualization/remotebox { }; - retroshare = callPackage ../applications/networking/p2p/retroshare { - qt = qt4; - }; + retroshare = callPackage ../applications/networking/p2p/retroshare { }; retroshare06 = lowPrio (callPackage ../applications/networking/p2p/retroshare/0.6.nix { }); From 83406bc171ca2b385c49838e6ed5e89007a875b5 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:39:58 +0300 Subject: [PATCH 095/147] x2goclient: move to qmake4Hook --- .../applications/networking/remote/x2goclient/default.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/networking/remote/x2goclient/default.nix b/pkgs/applications/networking/remote/x2goclient/default.nix index 02a25b9a2704..09d4cf8dac5a 100644 --- a/pkgs/applications/networking/remote/x2goclient/default.nix +++ b/pkgs/applications/networking/remote/x2goclient/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, cups, libssh, libXpm, nxproxy, openldap, makeWrapper, qt4 }: +{ stdenv, fetchurl, cups, libssh, libXpm, nxproxy, openldap, makeWrapper, qt4, qmake4Hook }: stdenv.mkDerivation rec { name = "x2goclient-${version}"; @@ -10,7 +10,7 @@ stdenv.mkDerivation rec { }; buildInputs = [ cups libssh libXpm nxproxy openldap qt4 ]; - nativeBuildInputs = [ makeWrapper ]; + nativeBuildInputs = [ makeWrapper qmake4Hook ]; patchPhase = '' substituteInPlace Makefile \ @@ -19,7 +19,9 @@ stdenv.mkDerivation rec { --replace "-o root -g root" "" ''; - makeFlags = [ "PREFIX=$(out)" "ETCDIR=$(out)/etc" ]; + preConfigure = '' + qmakeFlags="$qmakeFlags ETCDIR=$out/etc" + ''; enableParallelBuilding = true; From 0b88755d3751271dc544833d61888b5809f0bba2 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:18 +0300 Subject: [PATCH 096/147] fritzing: move to qmakeHook This reverts commit 81fc546df3e9549aaba1581ea8c5425ddd0f0e34. --- .../science/electronics/fritzing/default.nix | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/pkgs/applications/science/electronics/fritzing/default.nix b/pkgs/applications/science/electronics/fritzing/default.nix index ff0502ac0cbb..110759ea292c 100644 --- a/pkgs/applications/science/electronics/fritzing/default.nix +++ b/pkgs/applications/science/electronics/fritzing/default.nix @@ -1,7 +1,6 @@ -{ stdenv, fetchurl, qtbase, qtsvg, boost }: +{ stdenv, fetchurl, qtbase, qtsvg, qmakeHook, boost }: stdenv.mkDerivation rec { - version = "0.9.0b"; name = "fritzing-${version}"; @@ -10,19 +9,7 @@ stdenv.mkDerivation rec { sha256 = "181qnknq1j5x075icpw2qk0sc4wcj9f2hym533vs936is0wxp2gk"; }; - unpackPhase = '' - tar xjf ${src} - ''; - - buildInputs = [ qtbase qtsvg boost ]; - - configurePhase = '' - runHook preConfigure - cd fritzing-${version}.source - echo $PATH - qmake PREFIX=$out phoenix.pro - runHook postConfigure - ''; + buildInputs = [ qtbase qtsvg boost qmakeHook ]; meta = { description = "An open source prototyping tool for Arduino-based projects"; From fb2c651647a6de71d4ab036215b1cf1758addcc2 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:18 +0300 Subject: [PATCH 097/147] qgroundcontrol: move to qmakeHook This reverts commit 11294eaf168b524da9601c8b35d71b72ba3ad040. --- .../science/robotics/qgroundcontrol/default.nix | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/pkgs/applications/science/robotics/qgroundcontrol/default.nix b/pkgs/applications/science/robotics/qgroundcontrol/default.nix index 692be0a88b12..cac9fef182cf 100644 --- a/pkgs/applications/science/robotics/qgroundcontrol/default.nix +++ b/pkgs/applications/science/robotics/qgroundcontrol/default.nix @@ -1,6 +1,6 @@ { stdenv, fetchgit, git, espeak, SDL, udev, doxygen, cmake, overrideCC#, gcc48 , qtbase, qtlocation, qtserialport, qtdeclarative, qtconnectivity, qtxmlpatterns - , qtsvg, qtquick1, qtquickcontrols, qtgraphicaleffects + , qtsvg, qtquick1, qtquickcontrols, qtgraphicaleffects, qmakeHook , makeQtWrapper, lndir , gst_all_1, qt_gstreamer1, pkgconfig, glibc , version ? "2.9.4" @@ -23,21 +23,11 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; nativeBuildInputs = [ - pkgconfig makeQtWrapper + pkgconfig makeQtWrapper qmakeHook ] ++ qtInputs; patches = [ ./0001-fix-gcc-cmath-namespace-issues.patch ]; - configurePhase = '' - runHook preConfigure - mkdir build - (cd build && qmake ../qgroundcontrol.pro) - runHook postConfigure - ''; - - preBuild = "pushd build/"; - postBuild = "popd"; - installPhase = '' mkdir -p $out/share/applications cp -v qgroundcontrol.desktop $out/share/applications From 661641aeb7e2b789c81ef206debd9bd902ec1fda Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:41:47 +0300 Subject: [PATCH 098/147] git-and-tools: move to callPackage --- .../git-and-tools/default.nix | 41 ++++--------------- 1 file changed, 9 insertions(+), 32 deletions(-) diff --git a/pkgs/applications/version-management/git-and-tools/default.nix b/pkgs/applications/version-management/git-and-tools/default.nix index fa8f43a45c6f..e193701ff958 100644 --- a/pkgs/applications/version-management/git-and-tools/default.nix +++ b/pkgs/applications/version-management/git-and-tools/default.nix @@ -3,12 +3,7 @@ */ args @ {pkgs}: with args; with pkgs; let - inherit (pkgs) stdenv fetchgit fetchurl subversion; - - gitBase = lib.makeOverridable (import ./git) { - inherit fetchurl stdenv curl openssl zlib expat perl python gettext gnugrep - asciidoc xmlto docbook2x docbook_xsl docbook_xml_dtd_45 libxslt cpio tcl - tk makeWrapper subversionClient gzip openssh libiconv; + gitBase = callPackage ./git { texinfo = texinfo5; svnSupport = false; # for git-svn support guiSupport = false; # requires tcl/tk @@ -64,44 +59,28 @@ rec { git-stree = callPackage ./git-stree { }; - git2cl = import ./git2cl { - inherit fetchgit stdenv perl; - }; + git2cl = callPackage ./git2cl { }; - gitFastExport = import ./fast-export { - inherit fetchgit stdenv mercurial coreutils git makeWrapper subversion; - }; + gitFastExport = callPackage ./fast-export { }; gitRemoteGcrypt = callPackage ./git-remote-gcrypt { }; gitflow = callPackage ./gitflow { }; - hub = import ./hub { - inherit go; - inherit stdenv fetchgit; + hub = callPackage ./hub { inherit (darwin) Security; }; - qgit = import ./qgit { - inherit fetchurl stdenv; - inherit (xorg) libXext libX11; - qt = qt4; - }; + qgit = callPackage ./qgit { }; - qgitGit = import ./qgit/qgit-git.nix { - inherit fetchurl sourceFromHead stdenv; - inherit (xorg) libXext libX11; - qt = qt4; - }; + qgitGit = callPackage ./qgit/qgit-git.nix { }; - stgit = import ./stgit { - inherit fetchurl stdenv python git; + stgit = callPackage ./stgit { }; subgit = callPackage ./subgit { }; - svn2git = import ./svn2git { - inherit stdenv fetchurl ruby makeWrapper; + svn2git = callPackage ./svn2git { git = gitSVN; }; @@ -109,9 +88,7 @@ rec { tig = callPackage ./tig { }; - topGit = lib.makeOverridable (import ./topgit) { - inherit stdenv fetchurl; - }; + topGit = callPackage ./topgit { }; transcrypt = callPackage ./transcrypt { }; } From a4e868a1022eb67b81088c0d2085b26948bf0fb2 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:42:02 +0300 Subject: [PATCH 099/147] qgit: move to qmake4Hook --- .../git-and-tools/qgit/default.nix | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/version-management/git-and-tools/qgit/default.nix b/pkgs/applications/version-management/git-and-tools/qgit/default.nix index a7e6a62ce5f5..3f5f9a2dbe1b 100644 --- a/pkgs/applications/version-management/git-and-tools/qgit/default.nix +++ b/pkgs/applications/version-management/git-and-tools/qgit/default.nix @@ -1,21 +1,26 @@ -{stdenv, fetchurl, qt, libXext, libX11}: +{ stdenv, fetchurl, qt4, qmake4Hook, libXext, libX11 }: stdenv.mkDerivation rec { name = "qgit-2.5"; + meta = { license = stdenv.lib.licenses.gpl2; homepage = "http://libre.tibirna.org/projects/qgit/wiki/QGit"; description = "Graphical front-end to Git"; - inherit (qt.meta) platforms; + inherit (qt4.meta) platforms; }; + src = fetchurl { url = "http://libre.tibirna.org/attachments/download/9/${name}.tar.gz"; sha256 = "25f1ca2860d840d87b9919d34fc3a1b05d4163671ed87d29c3e4a8a09e0b2499"; }; - buildInputs = [qt libXext libX11]; - configurePhase = "qmake PREFIX=$out"; + + buildInputs = [ qt4 libXext libX11 ]; + + nativeBuildInputs = [ qmake4Hook ]; + installPhase = '' install -s -D -m 755 bin/qgit "$out/bin/qgit" ''; From 93253939599e149c321e9e49ff369b602fe414ae Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:42:14 +0300 Subject: [PATCH 100/147] qgit-git: move to qmake4Hook --- .../git-and-tools/qgit/qgit-git.nix | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/version-management/git-and-tools/qgit/qgit-git.nix b/pkgs/applications/version-management/git-and-tools/qgit/qgit-git.nix index 590e090de48c..c3d3c77ad336 100644 --- a/pkgs/applications/version-management/git-and-tools/qgit/qgit-git.nix +++ b/pkgs/applications/version-management/git-and-tools/qgit/qgit-git.nix @@ -1,20 +1,21 @@ -{stdenv, fetchurl, qt, libXext, libX11, sourceFromHead}: +{ stdenv, fetchurl, qt4, qmake4Hook, libXext, libX11, sourceFromHead }: stdenv.mkDerivation rec { name = "qgit-git"; + meta = { license = stdenv.lib.licenses.gpl2; homepage = "http://digilander.libero.it/mcostalba/"; description = "Graphical front-end to Git"; }; + # REGION AUTO UPDATE: { name="qgit"; type="git"; url="git://git.kernel.org/pub/scm/qgit/qgit4.git"; } src = sourceFromHead "qgit-a0252ed2a6a72b50e65d027adce8afa22e874277.tar.gz" (fetchurl { url = "http://mawercer.de/~nix/repos/qgit-a0252ed2a6a72b50e65d027adce8afa22e874277.tar.gz"; sha256 = "17e4727ac68b4f2e8503289d5b6a2c042547e7be133e7f8195b79e33eab61b93"; }); # END - buildInputs = [qt libXext libX11]; - buildPhase = '' - qmake PREFIX=$out - make - ''; + + buildInputs = [ qt4 libXext libX11 ]; + + nativeBuildInputs = [ qmake4Hook ]; } From e5e09e8cc7a98422f62b4c617efcaaa0e82ed71d Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:42:27 +0300 Subject: [PATCH 101/147] svn2git-kde: move to qmake4Hook --- .../git-and-tools/svn2git-kde/default.nix | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/version-management/git-and-tools/svn2git-kde/default.nix b/pkgs/applications/version-management/git-and-tools/svn2git-kde/default.nix index f282fa6635b8..e8f9078a839e 100644 --- a/pkgs/applications/version-management/git-and-tools/svn2git-kde/default.nix +++ b/pkgs/applications/version-management/git-and-tools/svn2git-kde/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchgit, qt4, subversion, apr}: +{ stdenv, fetchgit, qt4, qmake4Hook, subversion, apr }: stdenv.mkDerivation rec { name = "svn2git-kde-1.0.5"; @@ -9,10 +9,10 @@ stdenv.mkDerivation rec { sha256 = "818673fe751b00a42b6ed3e78a783549fb09b5245a01dee47b3dded667bfc582"; }; - buildPhase = '' + NIX_CFLAGS_COMPILE = [ "-I${apr}/include/apr-1" "-I${subversion.dev}/include/subversion-1" "-DVER=\"${src.rev}\"" ]; + + patchPhase = '' sed -i 's|/bin/cat|cat|' ./src/repository.cpp - qmake - make CXXFLAGS='-I${apr}/include/apr-1 -I${subversion.dev}/include/subversion-1 -DVER="\"${src.rev}\""' ''; installPhase = '' @@ -22,5 +22,7 @@ stdenv.mkDerivation rec { buildInputs = [ subversion apr qt4 ]; + nativeBuildInputs = [ qmake4Hook ]; + meta.broken = true; } From 9a8a4b6efeb6cd90f4504b06b8d05a2f5b77316f Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:42:39 +0300 Subject: [PATCH 102/147] guitone: move to qmake4Hook --- pkgs/applications/version-management/guitone/default.nix | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/version-management/guitone/default.nix b/pkgs/applications/version-management/guitone/default.nix index 135e7c7e1efd..8731cbfde19b 100644 --- a/pkgs/applications/version-management/guitone/default.nix +++ b/pkgs/applications/version-management/guitone/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, fetchmtn, qt4, pkgconfig, graphviz }: +{ stdenv, fetchurl, fetchmtn, qt4, qmake4Hook, pkgconfig, graphviz }: let version = "1.0-mtn-head"; in stdenv.mkDerivation rec { @@ -16,10 +16,7 @@ stdenv.mkDerivation rec { branch = "net.venge.monotone.guitone"; }; - buildInputs = [ qt4 pkgconfig graphviz ]; - - prefixKey="PREFIX="; - configureScript = "qmake guitone.pro"; + buildInputs = [ qt4 qmake4Hook pkgconfig graphviz ]; meta = { description = "Qt4 based GUI for monotone"; From 2816ad29e512cec244e28f95e909177fbe9d8f69 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:42:48 +0300 Subject: [PATCH 103/147] bomi: move to qmakeHook --- pkgs/applications/video/bomi/default.nix | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/video/bomi/default.nix b/pkgs/applications/video/bomi/default.nix index f9301781fc10..c017ed4cda32 100644 --- a/pkgs/applications/video/bomi/default.nix +++ b/pkgs/applications/video/bomi/default.nix @@ -1,6 +1,6 @@ { stdenv, fetchurl, fetchFromGitHub, pkgconfig, perl, python, which, makeQtWrapper , libX11, libxcb, mesa -, qtbase, qtdeclarative, qtquickcontrols, qttools, qtx11extras +, qtbase, qtdeclarative, qtquickcontrols, qttools, qtx11extras, qmakeHook , ffmpeg , libchardet , mpg123 @@ -76,6 +76,8 @@ stdenv.mkDerivation rec { ${optionalString youtubeSupport "--prefix PATH ':' '${youtube-dl}/bin'"} ''; + dontUseQmakeConfigure = true; + configureFlags = with stdenv.lib; [ "--qmake=qmake" ] ++ optional jackSupport "--enable-jack" @@ -84,7 +86,7 @@ stdenv.mkDerivation rec { ++ optional cddaSupport "--enable-cdda" ; - nativeBuildInputs = [ pkgconfig perl python which qttools makeQtWrapper ]; + nativeBuildInputs = [ pkgconfig perl python which qttools makeQtWrapper qmakeHook ]; enableParallelBuilding = true; From 3656842478914d5caacc96c79a6fece854b2ccc1 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:42:56 +0300 Subject: [PATCH 104/147] clipgrab: move to qmake4Hook --- pkgs/applications/video/clipgrab/default.nix | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/video/clipgrab/default.nix b/pkgs/applications/video/clipgrab/default.nix index e634a0caa3f4..b8967323c988 100644 --- a/pkgs/applications/video/clipgrab/default.nix +++ b/pkgs/applications/video/clipgrab/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, makeDesktopItem, ffmpeg, qt4 }: +{ stdenv, fetchurl, makeDesktopItem, ffmpeg, qt4, qmake4Hook }: stdenv.mkDerivation rec { name = "clipgrab-${version}"; @@ -11,6 +11,7 @@ stdenv.mkDerivation rec { }; buildInputs = [ ffmpeg qt4 ]; + nativeBuildInputs = [ qmake4Hook ]; postPatch = stdenv.lib.optionalString (ffmpeg != null) '' substituteInPlace converter_ffmpeg.cpp \ @@ -18,9 +19,7 @@ stdenv.mkDerivation rec { --replace '"ffmpeg ' '"${ffmpeg.bin}/bin/ffmpeg ' ''; - configurePhase = '' - qmake clipgrab.pro - ''; + qmakeFlags = [ "clipgrab.pro" ]; enableParallelBuilding = true; From 09394ae019bf1782051e959dc473e1d442a93f1f Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:43:08 +0300 Subject: [PATCH 105/147] linuxstopmotion: move to qmake4Hook --- pkgs/applications/video/linuxstopmotion/default.nix | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/video/linuxstopmotion/default.nix b/pkgs/applications/video/linuxstopmotion/default.nix index 23a033844b38..293bdd835b5d 100644 --- a/pkgs/applications/video/linuxstopmotion/default.nix +++ b/pkgs/applications/video/linuxstopmotion/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchgit, pkgconfig, qt4, SDL, SDL_image, libvorbis, libtar, libxml2 -, gamin +, gamin, qmake4Hook }: stdenv.mkDerivation rec { @@ -12,14 +12,10 @@ stdenv.mkDerivation rec { sha256 = "1xkkrhllgy2d7k0vrdj794ya7y3g3n7xh8c2qgnb26yrarz79dqj"; }; - buildInputs = [ pkgconfig qt4 SDL SDL_image libvorbis libtar libxml2 gamin ]; + buildInputs = [ pkgconfig qt4 SDL SDL_image libvorbis libtar libxml2 gamin qmake4Hook ]; patches = [ ./linuxstopmotion-fix-wrong-isProcess-logic.patch ]; - configurePhase = '' - qmake PREFIX="$out" - ''; - # Installation breaks without this preInstall = '' mkdir -p "$out/share/stopmotion/translations/" From 35ab3d55220d5248d0903f5af6025487c91b6f44 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:43:15 +0300 Subject: [PATCH 106/147] minitube: move to qmake4Hook --- pkgs/applications/video/minitube/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/video/minitube/default.nix b/pkgs/applications/video/minitube/default.nix index f9d887189ec9..1a621032125b 100644 --- a/pkgs/applications/video/minitube/default.nix +++ b/pkgs/applications/video/minitube/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, makeWrapper, phonon, phonon_backend_vlc, qt4 +{ stdenv, fetchFromGitHub, makeWrapper, phonon, phonon_backend_vlc, qt4, qmake4Hook # "Free" API key generated by nckx , withAPIKey ? "AIzaSyBtFgbln3bu1swQC-naMxMtKh384D3xJZE" }: @@ -14,11 +14,9 @@ stdenv.mkDerivation rec { }; buildInputs = [ phonon phonon_backend_vlc qt4 ]; - nativeBuildInputs = [ makeWrapper ]; + nativeBuildInputs = [ makeWrapper qmake4Hook ]; - configurePhase = '' - qmake PREFIX=$out "DEFINES += APP_GOOGLE_API_KEY=${withAPIKey}" - ''; + qmakeFlags = [ "DEFINES+=APP_GOOGLE_API_KEY=${withAPIKey}" ]; enableParallelBuilding = true; From 7e4e4799f49d81a3dafa1d0cbbf5c94b7aef9874 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:43:25 +0300 Subject: [PATCH 107/147] qgifer: move to qmake4Hook --- pkgs/applications/video/qgifer/default.nix | 4 ++-- pkgs/top-level/all-packages.nix | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/video/qgifer/default.nix b/pkgs/applications/video/qgifer/default.nix index f528ce99a8a2..8185e15dcc8b 100644 --- a/pkgs/applications/video/qgifer/default.nix +++ b/pkgs/applications/video/qgifer/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchsvn, cmake, opencv, qt, giflib }: +{ stdenv, fetchsvn, cmake, opencv, qt4, giflib }: stdenv.mkDerivation rec { name = "qgifer-${version}"; @@ -13,7 +13,7 @@ stdenv.mkDerivation rec { substituteInPlace CMakeLists.txt --replace "SET(CMAKE_INSTALL_PREFIX" "#" ''; - buildInputs = [ cmake opencv qt giflib ]; + buildInputs = [ cmake opencv qt4 giflib ]; meta = with stdenv.lib; { description = "Video-based animated GIF creator"; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 510ccc46e8c2..eb2d35866af7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -2976,7 +2976,6 @@ in qgifer = callPackage ../applications/video/qgifer { giflib = giflib_4_1; - qt = qt4; }; qhull = callPackage ../development/libraries/qhull { }; From 577ea10f6865f592429c40cdf0cfd9c3a9287eb3 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:18 +0300 Subject: [PATCH 108/147] shotcut: move to qmakeHook This reverts commit dbc1605deaeafc07c79cddf4d5e756074d8825b3. --- pkgs/applications/video/shotcut/default.nix | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/pkgs/applications/video/shotcut/default.nix b/pkgs/applications/video/shotcut/default.nix index d2400475a0b3..fdadc1d99abe 100644 --- a/pkgs/applications/video/shotcut/default.nix +++ b/pkgs/applications/video/shotcut/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, SDL, frei0r, gettext, makeWrapper, mlt, pkgconfig, qtbase }: +{ stdenv, fetchurl, SDL, frei0r, gettext, makeWrapper, mlt, pkgconfig, qtbase, qmakeHook }: stdenv.mkDerivation rec { name = "shotcut-${version}"; @@ -9,13 +9,7 @@ stdenv.mkDerivation rec { sha256 = "1504ds3ppqmpg84nb2gb74qndqysjwn3xw7n8xv19kd1pppnr10f"; }; - buildInputs = [ SDL frei0r gettext makeWrapper mlt pkgconfig qtbase ]; - - configurePhase = '' - runHook preConfigure - qmake PREFIX=$out - runHook postConfigure - ''; + buildInputs = [ SDL frei0r gettext makeWrapper mlt pkgconfig qtbase qmakeHook ]; postInstall = '' mkdir -p $out/share/shotcut From 6554997eaa1756456f2bfa4952f371e5288e74c3 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:18 +0300 Subject: [PATCH 109/147] zeal: move to qmakeHook This reverts commit 9cfc8d94bb22000d1b648066c3d8b580f27d1271. --- pkgs/data/documentation/zeal/default.nix | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/pkgs/data/documentation/zeal/default.nix b/pkgs/data/documentation/zeal/default.nix index dd681404e856..89e5d83df614 100644 --- a/pkgs/data/documentation/zeal/default.nix +++ b/pkgs/data/documentation/zeal/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchFromGitHub, libarchive, pkgconfig, qtbase -, qtimageformats, qtwebkit, qtx11extras, xorg }: +, qtimageformats, qtwebkit, qtx11extras, xcbutilkeysyms, qmakeHook }: stdenv.mkDerivation rec { version = "0.2.1"; @@ -13,18 +13,12 @@ stdenv.mkDerivation rec { }; buildInputs = [ - xorg.xcbutilkeysyms pkgconfig qtbase qtimageformats qtwebkit qtx11extras libarchive + xcbutilkeysyms pkgconfig qtbase qtimageformats qtwebkit qtx11extras libarchive qmakeHook ]; - configurePhase = '' - runHook preConfigure - qmake PREFIX=/ - runHook postConfigure - ''; + qmakeFlags = [ "PREFIX=/" ]; - installPhase = '' - make INSTALL_ROOT=$out install - ''; + installFlags = [ "INSTALL_ROOT=$(out)" ]; enableParallelBuilding = true; From ba5275115784e9484d0b10f06e422cc9755c06c2 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:44:28 +0300 Subject: [PATCH 110/147] eql: flags is a list of strings --- pkgs/development/compilers/eql/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/compilers/eql/default.nix b/pkgs/development/compilers/eql/default.nix index def60aa295f0..de531e901d98 100644 --- a/pkgs/development/compilers/eql/default.nix +++ b/pkgs/development/compilers/eql/default.nix @@ -11,7 +11,7 @@ stdenv.mkDerivation rec { buildInputs = [ ecl qt4 xorgserver xkbcomp xkeyboard_config ]; - NIX_CFLAGS_COMPILE = "-fPIC"; + NIX_CFLAGS_COMPILE = [ "-fPIC" ]; postPatch = '' sed -re 's@[(]in-home "gui/.command-history"[)]@(concatenate '"'"'string (ext:getenv "HOME") "/.eql-gui-command-history")@' -i gui/gui.lisp From 31d6dd6be0b4d5a376f7ef2cc2039265f71b79dd Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:44:48 +0300 Subject: [PATCH 111/147] CGAL: fix build --- pkgs/development/libraries/CGAL/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/development/libraries/CGAL/default.nix b/pkgs/development/libraries/CGAL/default.nix index 1f964388cbda..b8fd4af812ab 100644 --- a/pkgs/development/libraries/CGAL/default.nix +++ b/pkgs/development/libraries/CGAL/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, cmake, boost, gmp, mpfr }: +{ stdenv, fetchurl, cmake, boost, gmp, mpfr, mesa_glu }: stdenv.mkDerivation rec { version = "4.7"; @@ -12,6 +12,7 @@ stdenv.mkDerivation rec { # note: optional component libCGAL_ImageIO would need zlib and opengl; # there are also libCGAL_Qt{3,4} omitted ATM buildInputs = [ cmake boost gmp mpfr ]; + #propagatedBuildInputs = [ mesa_glu ]; doCheck = false; From 068c7b68a2b9b349f467d3ea18cf8a6726085a94 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:17 +0300 Subject: [PATCH 112/147] accounts-qt: move to qmakeHook This reverts commit 25382a37e38d92113ae671f0f2d6f1be9045015e. --- pkgs/development/libraries/accounts-qt/default.nix | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/pkgs/development/libraries/accounts-qt/default.nix b/pkgs/development/libraries/accounts-qt/default.nix index e82d37f1d3c7..a16a0ef8cf5b 100644 --- a/pkgs/development/libraries/accounts-qt/default.nix +++ b/pkgs/development/libraries/accounts-qt/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitLab, doxygen, glib, libaccounts-glib, pkgconfig, qtbase }: +{ stdenv, fetchFromGitLab, doxygen, glib, libaccounts-glib, pkgconfig, qtbase, qmakeHook }: stdenv.mkDerivation rec { name = "accounts-qt-${version}"; @@ -12,12 +12,10 @@ stdenv.mkDerivation rec { }; buildInputs = [ glib libaccounts-glib qtbase ]; - nativeBuildInputs = [ doxygen pkgconfig ]; + nativeBuildInputs = [ doxygen pkgconfig qmakeHook ]; - configurePhase = '' - runHook preConfigure - qmake PREFIX=$out LIBDIR=$out/lib CMAKE_CONFIG_PATH=$out/lib/cmake - runHook postConfigure + preConfigure = '' + qmakeFlags="$qmakeFlags LIBDIR=$out/lib CMAKE_CONFIG_PATH=$out/lib/cmake" ''; meta = with stdenv.lib; { From 4b5bf1916ad705453b4fbb737d0a1a1dac2aacd4 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:45:09 +0300 Subject: [PATCH 113/147] herqq: move to qmake4Hook --- pkgs/development/libraries/herqq/default.nix | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkgs/development/libraries/herqq/default.nix b/pkgs/development/libraries/herqq/default.nix index fee12592c636..39d5b2c792a2 100644 --- a/pkgs/development/libraries/herqq/default.nix +++ b/pkgs/development/libraries/herqq/default.nix @@ -1,11 +1,9 @@ -{ stdenv, fetchurl, qt4, unzip }: +{ stdenv, fetchurl, qt4, qmake4Hook, unzip }: stdenv.mkDerivation rec { name = "herqq-1.0.0"; - buildInputs = [ qt4 unzip ]; - - configurePhase = "qmake PREFIX=$out herqq.pro"; + buildInputs = [ qt4 unzip qmake4Hook ]; src = fetchurl { url = "mirror://sourceforge/hupnp/${name}.zip"; From ac1a531933a25cce11465bc8cd24f2a6c12a4915 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:20 +0300 Subject: [PATCH 114/147] libcommuni: move to qmakeHook This reverts commit ee1af147f35818f60d3cd6192a4828abdbfdc632. --- pkgs/development/libraries/libcommuni/default.nix | 12 ++++++------ pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/pkgs/development/libraries/libcommuni/default.nix b/pkgs/development/libraries/libcommuni/default.nix index 008311c620c9..7b83be7e911a 100644 --- a/pkgs/development/libraries/libcommuni/default.nix +++ b/pkgs/development/libraries/libcommuni/default.nix @@ -1,4 +1,4 @@ -{ fetchgit, qt5, stdenv +{ fetchgit, qtbase, qmakeHook, stdenv }: stdenv.mkDerivation rec { @@ -11,16 +11,16 @@ stdenv.mkDerivation rec { sha256 = "15sb7vinaaz1v5nclxpnp5p9a0kmfmlgiqibkipnyydizclidpfx"; }; - buildInputs = [ qt5.qtbase ]; + buildInputs = [ qtbase ]; + nativeBuildInputs = [ qmakeHook ]; enableParallelBuild = true; - postPatch = '' - sed -i -e 's|/bin/pwd|pwd|g' -e 's/which/type -P/' configure + configurePhase = '' + sed -i -e 's|/bin/pwd|pwd|g' configure + ./configure -config release -prefix $out -qmake $QMAKE ''; - configureFlags = [ "-config release" ]; - meta = with stdenv.lib; { description = "A cross-platform IRC framework written with Qt"; homepage = https://communi.github.io; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index eb2d35866af7..007c8df4f07e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -7385,7 +7385,7 @@ in libcm = callPackage ../development/libraries/libcm { }; - libcommuni = callPackage ../development/libraries/libcommuni { }; + libcommuni = qt5.callPackage ../development/libraries/libcommuni { }; libconfuse = callPackage ../development/libraries/libconfuse { }; From 9a2bd51a308ea98d7fcc12c8a53f404bfc271d4f Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:17 +0300 Subject: [PATCH 115/147] libkeyfinder: move to qmakeHook This reverts commit f43d8b233621c0a5ac575c6236b0e2c5b58611f4. --- pkgs/development/libraries/libkeyfinder/default.nix | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/pkgs/development/libraries/libkeyfinder/default.nix b/pkgs/development/libraries/libkeyfinder/default.nix index 729df918e579..d95ada04a34b 100644 --- a/pkgs/development/libraries/libkeyfinder/default.nix +++ b/pkgs/development/libraries/libkeyfinder/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, fftw, qtbase }: +{ stdenv, fetchFromGitHub, fftw, qtbase, qmakeHook }: stdenv.mkDerivation rec { name = "libkeyfinder-${version}"; @@ -11,7 +11,7 @@ stdenv.mkDerivation rec { owner = "ibsh"; }; - buildInputs = [ fftw qtbase ]; + buildInputs = [ fftw qtbase qmakeHook ]; postPatch = '' substituteInPlace LibKeyFinder.pro \ @@ -19,12 +19,6 @@ stdenv.mkDerivation rec { --replace "-stdlib=libc++" "" ''; - configurePhase = '' - runHook preConfigure - qmake - runHook postConfigure - ''; - enableParallelBuilding = true; postInstall = '' From 49558b04d256c1010c76b3491e84f3c1e1db7a98 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:45:56 +0300 Subject: [PATCH 116/147] liqglviewer: move to qmake4Hook --- pkgs/development/libraries/libqglviewer/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/development/libraries/libqglviewer/default.nix b/pkgs/development/libraries/libqglviewer/default.nix index 6b40eeb3b1f5..eef9e05ca036 100644 --- a/pkgs/development/libraries/libqglviewer/default.nix +++ b/pkgs/development/libraries/libqglviewer/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4 }: +{ stdenv, fetchurl, qt4, qmake4Hook }: stdenv.mkDerivation rec { name = "libqglviewer-2.6.3"; @@ -9,13 +9,11 @@ stdenv.mkDerivation rec { sha256 = "00jdkyk4wg1356c3ar6nk3hyp494ya3yvshq9m57kfmqpn3inqdy"; }; - buildInputs = [ qt4 ]; + buildInputs = [ qt4 qmake4Hook ]; - buildPhase = + postPatch = '' cd QGLViewer - qmake PREFIX=$out - make ''; meta = with stdenv.lib; { From 005dab1a7afee27358e011906231ad7eed7c4120 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 23:02:33 +0300 Subject: [PATCH 117/147] qmltermwidget: move to qmakeHook This reverts commit 2d6ea2cc3072f9bd86d655bf7e614d556ee0b339. --- pkgs/development/libraries/qmltermwidget/default.nix | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/pkgs/development/libraries/qmltermwidget/default.nix b/pkgs/development/libraries/qmltermwidget/default.nix index 359a4341537d..1620649a3cce 100644 --- a/pkgs/development/libraries/qmltermwidget/default.nix +++ b/pkgs/development/libraries/qmltermwidget/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchgit, qtbase, qtquick1 }: +{ stdenv, fetchgit, qtbase, qtquick1, qmakeHook }: stdenv.mkDerivation rec { version = "0.1.0"; @@ -11,19 +11,14 @@ stdenv.mkDerivation rec { }; buildInputs = [ qtbase qtquick1 ]; + nativeBuildInputs = [ qmakeHook ]; patchPhase = '' substituteInPlace qmltermwidget.pro \ --replace '$$[QT_INSTALL_QML]' "/lib/qt5/qml/" ''; - configurePhase = '' - runHook preConfigure - qmake PREFIX=$out - runHook postConfigure - ''; - - installPhase=''make INSTALL_ROOT="$out" install''; + installFlags = [ "INSTALL_ROOT=$(out)" ]; enableParallelBuilding = true; From e307c3dac2a70e4861ffb54f08ce00c308f27f54 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:46:24 +0300 Subject: [PATCH 118/147] qoauth: move to qmake4Hook --- pkgs/development/libraries/qoauth/default.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/development/libraries/qoauth/default.nix b/pkgs/development/libraries/qoauth/default.nix index f93e4479e71e..5a448d330671 100644 --- a/pkgs/development/libraries/qoauth/default.nix +++ b/pkgs/development/libraries/qoauth/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4, qca2 }: +{ stdenv, fetchurl, qt4, qca2, qmake4Hook }: stdenv.mkDerivation { name = "qoauth-1.0.1"; @@ -9,13 +9,13 @@ stdenv.mkDerivation { sha256 = "1ax0g4dd49a3a1699ams13bkhz690xfwqg8rxp1capbdpf2aa8cp"; }; - configurePhase = "qmake PREFIX=$prefix"; patchPhase = "sed -e 's/lib64/lib/g' -i src/src.pro"; buildInputs = [ qt4 qca2 ]; + nativeBuildInputs = [ qmake4Hook ]; - NIX_CFLAGS_COMPILE="-I${qca2}/include/QtCrypto"; - NIX_LDFLAGS = "-lqca"; + NIX_CFLAGS_COMPILE = [ "-I${qca2}/include/QtCrypto" ]; + NIX_LDFLAGS = [ "-lqca" ]; meta = { description = "Qt library for OAuth authentication"; From b69940ee7686897e743d3083a226314d491b57cc Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:46:33 +0300 Subject: [PATCH 119/147] qscintilla: move to qmake4Hook --- pkgs/development/libraries/qscintilla/default.nix | 6 +++--- pkgs/top-level/all-packages.nix | 4 +--- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/pkgs/development/libraries/qscintilla/default.nix b/pkgs/development/libraries/qscintilla/default.nix index 26d412e5a8cb..bc44f53fa6ef 100644 --- a/pkgs/development/libraries/qscintilla/default.nix +++ b/pkgs/development/libraries/qscintilla/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt }: +{ stdenv, fetchurl, qt4, qmake4Hook }: stdenv.mkDerivation rec { pname = "qscintilla"; @@ -11,7 +11,8 @@ stdenv.mkDerivation rec { sha256 = "d7c32e32582f93779de861006d87467b38b9ebc06e3d0b32e981cb24369fa417"; }; - buildInputs = [ qt ]; + buildInputs = [ qt4 ]; + nativeBuildInputs = [ qmake4Hook ]; preConfigure = '' cd Qt4Qt5 @@ -20,7 +21,6 @@ stdenv.mkDerivation rec { -e "s,\$\$\\[QT_INSTALL_TRANSLATIONS\\],$out/share/qt/translations," \ -e "s,\$\$\\[QT_INSTALL_DATA\\],$out/share/qt," \ qscintilla.pro - qmake qscintilla.pro ''; meta = { diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 007c8df4f07e..ded7ed829d63 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -2986,9 +2986,7 @@ in qprint = callPackage ../tools/text/qprint { }; - qscintilla = callPackage ../development/libraries/qscintilla { - qt = qt4; - }; + qscintilla = callPackage ../development/libraries/qscintilla { }; qshowdiff = callPackage ../tools/text/qshowdiff { }; From 4a4567b73191840de2f54f7b8f7a257806c12043 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:47:43 +0300 Subject: [PATCH 120/147] qt54.qtmultimedia: use qmakeFlags --- pkgs/development/libraries/qt-5/5.4/qtmultimedia.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/qt-5/5.4/qtmultimedia.nix b/pkgs/development/libraries/qt-5/5.4/qtmultimedia.nix index 8db8fa5f4b96..9eb68ba6b5ba 100644 --- a/pkgs/development/libraries/qt-5/5.4/qtmultimedia.nix +++ b/pkgs/development/libraries/qt-5/5.4/qtmultimedia.nix @@ -8,7 +8,7 @@ qtSubmodule { buildInputs = [ pkgconfig alsaLib gstreamer gst-plugins-base libpulseaudio ]; - configureFlags = "GST_VERSION=1.0"; + qmakeFlags = [ "GST_VERSION=1.0" ]; postFixup = '' fixQtModuleCMakeConfig "Multimedia" fixQtModuleCMakeConfig "MultimediaWidgets" From 5b17e825594cdf8a0278795a7542fb22914b4673 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:48:35 +0300 Subject: [PATCH 121/147] qt55.qtmultimedia: use qmakeFlags --- pkgs/development/libraries/qt-5/5.5/qtmultimedia.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/qt-5/5.5/qtmultimedia.nix b/pkgs/development/libraries/qt-5/5.5/qtmultimedia.nix index 8db8fa5f4b96..9eb68ba6b5ba 100644 --- a/pkgs/development/libraries/qt-5/5.5/qtmultimedia.nix +++ b/pkgs/development/libraries/qt-5/5.5/qtmultimedia.nix @@ -8,7 +8,7 @@ qtSubmodule { buildInputs = [ pkgconfig alsaLib gstreamer gst-plugins-base libpulseaudio ]; - configureFlags = "GST_VERSION=1.0"; + qmakeFlags = [ "GST_VERSION=1.0" ]; postFixup = '' fixQtModuleCMakeConfig "Multimedia" fixQtModuleCMakeConfig "MultimediaWidgets" From 1875538730d44eda2d078498a5f53ee61fbb1daa Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:49:29 +0300 Subject: [PATCH 122/147] qtscriptgenerator: spaces --- pkgs/development/libraries/qtscriptgenerator/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/qtscriptgenerator/default.nix b/pkgs/development/libraries/qtscriptgenerator/default.nix index b8ed81de487b..5b93fbfaade9 100644 --- a/pkgs/development/libraries/qtscriptgenerator/default.nix +++ b/pkgs/development/libraries/qtscriptgenerator/default.nix @@ -1,4 +1,4 @@ -{stdenv, fetchurl, qt4}: +{ stdenv, fetchurl, qt4 }: stdenv.mkDerivation { name = "qtscriptgenerator-0.1.0"; From 82af8640e36c4b37ff3034f3a410334aa6f19caf Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 23:01:40 +0300 Subject: [PATCH 123/147] quazip: move to qmakeHook This reverts commit d663b3df24b709fd972525ab73855843ff35d09d. --- pkgs/development/libraries/quazip/default.nix | 11 +++-------- pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/pkgs/development/libraries/quazip/default.nix b/pkgs/development/libraries/quazip/default.nix index 7ef1a9212a14..a1eb2ad7084c 100644 --- a/pkgs/development/libraries/quazip/default.nix +++ b/pkgs/development/libraries/quazip/default.nix @@ -1,4 +1,4 @@ -{ fetchurl, stdenv, zip, zlib, qt }: +{ fetchurl, stdenv, zip, zlib, qt, qmakeHook }: stdenv.mkDerivation rec { name = "quazip-0.7.1"; @@ -8,15 +8,10 @@ stdenv.mkDerivation rec { sha256 = "1pijy6zn8kdx9m6wrckid24vkgp250hklbpmgrpixiam6l889jbq"; }; - configurePhase = '' - runHook preConfigure - cd quazip && qmake quazip.pro - runHook postConfigure - ''; - - installFlags = "INSTALL_ROOT=$(out)"; + preConfigure = "cd quazip"; buildInputs = [ zlib qt ]; + nativeBuildInputs = [ qmakeHook ]; meta = { description = "Provides access to ZIP archives from Qt programs"; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index ded7ed829d63..e02186c5212e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -3143,7 +3143,7 @@ in screen-message = callPackage ../tools/X11/screen-message { }; screencloud = callPackage ../applications/graphics/screencloud { - quazip = qt5.quazip.override { qt = qt4; }; + quazip = qt5.quazip.override { qt = qt4; qmakeHook = qmake4Hook; }; }; scrot = callPackage ../tools/graphics/scrot { }; From d441238b52693c8318840a2e3a8a5d9731fe0c1a Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 23:01:26 +0300 Subject: [PATCH 124/147] qt5.qwt: move to qmakeHook This reverts commit 8779e0f2741bb3ae2aaf3b85baa35c9d31a4754b. --- pkgs/development/libraries/qwt/6.nix | 9 +++------ pkgs/development/libraries/qwt/default.nix | 6 +----- 2 files changed, 4 insertions(+), 11 deletions(-) diff --git a/pkgs/development/libraries/qwt/6.nix b/pkgs/development/libraries/qwt/6.nix index a99573ca5e43..cd940b818e92 100644 --- a/pkgs/development/libraries/qwt/6.nix +++ b/pkgs/development/libraries/qwt/6.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qtbase, qtsvg, qttools }: +{ stdenv, fetchurl, qtbase, qtsvg, qttools, qmakeHook }: stdenv.mkDerivation rec { name = "qwt-6.1.2"; @@ -9,16 +9,13 @@ stdenv.mkDerivation rec { }; propagatedBuildInputs = [ qtbase qtsvg qttools ]; + nativeBuildInputs = [ qmakeHook ]; postPatch = '' sed -e "s|QWT_INSTALL_PREFIX.*=.*|QWT_INSTALL_PREFIX = $out|g" -i qwtconfig.pri ''; - configurePhase = '' - runHook preConfigure - qmake -after doc.path=$out/share/doc/${name} -r - runHook postConfigure - ''; + qmakeFlags = [ "-after doc.path=$out/share/doc/${name}" ]; meta = with stdenv.lib; { description = "Qt widgets for technical applications"; diff --git a/pkgs/development/libraries/qwt/default.nix b/pkgs/development/libraries/qwt/default.nix index 451784261f82..4aa7c0bc7d5a 100644 --- a/pkgs/development/libraries/qwt/default.nix +++ b/pkgs/development/libraries/qwt/default.nix @@ -15,11 +15,7 @@ stdenv.mkDerivation rec { sed -e "s|INSTALLBASE.*=.*|INSTALLBASE = $out|g" -i qwtconfig.pri ''; - configurePhase = '' - runHook preConfigure - qmake INSTALLBASE=$out -after doc.path=$out/share/doc/${name} -r - runHook postConfigure - ''; + configurePhase = ''qmake INSTALLBASE=$out -after doc.path=$out/share/doc/${name} -r''; meta = with stdenv.lib; { description = "Qt widgets for technical applications"; From 1b032e5221da9cc56ea2a89950d068173ba7b517 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:50:08 +0300 Subject: [PATCH 125/147] qwt: move to qmake4Hook --- pkgs/development/libraries/qwt/default.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/qwt/default.nix b/pkgs/development/libraries/qwt/default.nix index 4aa7c0bc7d5a..da5769e92cd1 100644 --- a/pkgs/development/libraries/qwt/default.nix +++ b/pkgs/development/libraries/qwt/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4 }: +{ stdenv, fetchurl, qt4, qmake4Hook }: stdenv.mkDerivation rec { name = "qwt-5.2.3"; @@ -9,13 +9,16 @@ stdenv.mkDerivation rec { }; propagatedBuildInputs = [ qt4 ]; + nativeBuildInputs = [ qmake4Hook ]; postPatch = '' sed -e "s@\$\$\[QT_INSTALL_PLUGINS\]@$out/lib/qt4/plugins@" -i designer/designer.pro sed -e "s|INSTALLBASE.*=.*|INSTALLBASE = $out|g" -i qwtconfig.pri ''; - configurePhase = ''qmake INSTALLBASE=$out -after doc.path=$out/share/doc/${name} -r''; + preConfigure = '' + qmakeFlags="$qmakeFlags INSTALLBASE=$out -after doc.path=$out/share/doc/${name}" + ''; meta = with stdenv.lib; { description = "Qt widgets for technical applications"; From 79008f6095acaa0b5d5e6c8af708d691e2c7adf8 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:17 +0300 Subject: [PATCH 126/147] signon: move to qmakeHook This reverts commit 96bed5b7aa92157586857255901d29de9ab05723. --- pkgs/development/libraries/signon/default.nix | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/pkgs/development/libraries/signon/default.nix b/pkgs/development/libraries/signon/default.nix index 2da555635b29..f2f7de5b7125 100644 --- a/pkgs/development/libraries/signon/default.nix +++ b/pkgs/development/libraries/signon/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, doxygen, qtbase }: +{ stdenv, fetchurl, doxygen, qtbase, qmakeHook }: stdenv.mkDerivation rec { name = "signon-${version}"; @@ -9,12 +9,10 @@ stdenv.mkDerivation rec { }; buildInputs = [ qtbase ]; - nativeBuildInputs = [ doxygen ]; + nativeBuildInputs = [ doxygen qmakeHook ]; - configurePhase = '' - runHook preConfigure - qmake PREFIX=$out LIBDIR=$out/lib CMAKE_CONFIG_PATH=$out/lib/cmake/SignOnQt5 - runHook postConfigure + preConfigure = '' + qmakeFlags="$qmakeFlags LIBDIR=$out/lib CMAKE_CONFIG_PATH=$out/lib/cmake/SignOnQt5" ''; } From c161258003eee0d60618dd4bc39f543185f4517a Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:17 +0300 Subject: [PATCH 127/147] pyqt5: move to qmakeHook This reverts commit f1c2572479265d121d55d9e3270dc1ebfee4aa00. --- pkgs/development/python-modules/pyqt/5.x.nix | 6 ++---- pkgs/top-level/python-packages.nix | 3 +-- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/pyqt/5.x.nix b/pkgs/development/python-modules/pyqt/5.x.nix index b11e87fe1d93..0e5f5604a988 100644 --- a/pkgs/development/python-modules/pyqt/5.x.nix +++ b/pkgs/development/python-modules/pyqt/5.x.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, python, pkgconfig, qtbase, qtsvg, qtwebkit, sip, pythonDBus -, lndir, makeWrapper }: +, lndir, makeWrapper, qmakeHook }: let version = "5.5.1"; @@ -21,13 +21,12 @@ in stdenv.mkDerivation { buildInputs = [ python pkgconfig makeWrapper lndir - qtbase qtsvg qtwebkit + qtbase qtsvg qtwebkit qmakeHook ]; propagatedBuildInputs = [ sip ]; configurePhase = '' - runHook preConfigure mkdir -p $out lndir ${pythonDBus} $out @@ -45,7 +44,6 @@ in stdenv.mkDerivation { --destdir=$out/lib/${python.libPrefix}/site-packages \ --sipdir=$out/share/sip \ --designer-plugindir=$out/plugins/designer - runHook postConfigure ''; postInstall = '' diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 3d1e2026a823..0771e4d1728d 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -166,10 +166,9 @@ in modules // { pythonPackages = self; }; - pyqt5 = callPackage ../development/python-modules/pyqt/5.x.nix { + pyqt5 = pkgs.qt55.callPackage ../development/python-modules/pyqt/5.x.nix { sip = self.sip_4_16; pythonDBus = self.dbus; - inherit (pkgs.qt55) qtbase qtsvg qtwebkit; }; pyside = callPackage ../development/python-modules/pyside { }; From a9662f8c4576e31b5f1294c6a7cb95f7b9944ca6 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:50:41 +0300 Subject: [PATCH 128/147] qtcreator: move to qmakeHook --- pkgs/development/qtcreator/default.nix | 21 ++++++--------------- 1 file changed, 6 insertions(+), 15 deletions(-) diff --git a/pkgs/development/qtcreator/default.nix b/pkgs/development/qtcreator/default.nix index a5dde0a580b5..18e06cb81263 100644 --- a/pkgs/development/qtcreator/default.nix +++ b/pkgs/development/qtcreator/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, makeWrapper -, qtbase, qtquickcontrols, qtscript, qtdeclarative +, qtbase, makeQtWrapper, qtquickcontrols, qtscript, qtdeclarative, qmakeHook , withDocumentation ? false }: @@ -21,18 +21,15 @@ stdenv.mkDerivation rec { buildInputs = [ makeWrapper qtbase qtscript qtquickcontrols qtdeclarative ]; + nativeBuildInputs = [ qmakeHook makeQtWrapper ]; + doCheck = false; enableParallelBuilding = true; - preConfigure = '' - qmake -spec linux-g++ qtcreator.pro - ''; + buildFlags = optional withDocumentation "docs"; - buildFlags = optionalString withDocumentation " docs"; - - installFlags = "INSTALL_ROOT=$(out)" - + optionalString withDocumentation " install_docs"; + installFlags = [ "INSTALL_ROOT=$(out)" ] ++ optional withDocumentation "install_docs"; postInstall = '' # Install desktop file @@ -47,13 +44,7 @@ stdenv.mkDerivation rec { Type=Application Categories=Qt;Development;IDE; __EOF__ - # Wrap the qtcreator binary - addToSearchPath QML2_IMPORT_PATH "${qtquickcontrols}/lib/qt5/qml" - addToSearchPath QML2_IMPORT_PATH "${qtdeclarative}/lib/qt5/qml" - wrapProgram $out/bin/qtcreator \ - --prefix QT_PLUGIN_PATH : "$QT_PLUGIN_PATH" \ - --prefix QML_IMPORT_PATH : "$QML_IMPORT_PATH" \ - --prefix QML2_IMPORT_PATH : "$QML2_IMPORT_PATH" + wrapQtProgram $out/bin/qtcreator ''; meta = { From f3e8653647f62088e5a6835d96fcc0be0bc631c2 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:50:54 +0300 Subject: [PATCH 129/147] valkyrie: move to qmake4Hook --- pkgs/development/tools/analysis/valkyrie/default.nix | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/pkgs/development/tools/analysis/valkyrie/default.nix b/pkgs/development/tools/analysis/valkyrie/default.nix index 76becca74cff..1da6c6a1e864 100644 --- a/pkgs/development/tools/analysis/valkyrie/default.nix +++ b/pkgs/development/tools/analysis/valkyrie/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4 }: +{ stdenv, fetchurl, qt4, qmake4Hook }: stdenv.mkDerivation rec { name = "valkyrie-2.0.0"; @@ -9,8 +9,7 @@ stdenv.mkDerivation rec { }; buildInputs = [ qt4 ]; - - configurePhase = "qmake PREFIX=$out"; + nativeBuildInputs = [ qmake4Hook ]; meta = { homepage = http://www.valgrind.org/; From f8d96d19836d010cecdb902917b5037118e0691f Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:51:03 +0300 Subject: [PATCH 130/147] chessx: move to qmakeHook --- pkgs/games/chessx/default.nix | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkgs/games/chessx/default.nix b/pkgs/games/chessx/default.nix index 39ec3670e54e..63a1adb7155a 100644 --- a/pkgs/games/chessx/default.nix +++ b/pkgs/games/chessx/default.nix @@ -1,4 +1,4 @@ -{ stdenv, pkgconfig, zlib, qtbase, qtsvg, qttools, qtmultimedia, fetchurl }: +{ stdenv, pkgconfig, zlib, qtbase, qtsvg, qttools, qtmultimedia, qmakeHook, fetchurl }: stdenv.mkDerivation rec { name = "chessx-${version}"; version = "1.3.2"; @@ -6,9 +6,6 @@ stdenv.mkDerivation rec { url = "mirror://sourceforge/chessx/chessx-${version}.tgz"; sha256 = "b136cf56d37d34867cdb9538176e1703b14f61b3384885b6f100580d0af0a3ff"; }; - preConfigure = '' - qmake -spec linux-g++ chessx.pro - ''; buildInputs = [ stdenv pkgconfig @@ -17,6 +14,7 @@ stdenv.mkDerivation rec { qttools qtmultimedia zlib + qmakeHook ]; enableParallelBuilding = true; From 02014ea0aaf59e92dcd69d61445f488b1aa9b683 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:51:15 +0300 Subject: [PATCH 131/147] mudlet: move to qmakeHook --- pkgs/games/mudlet/default.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pkgs/games/mudlet/default.nix b/pkgs/games/mudlet/default.nix index 8b51d6174039..d684cc22c38f 100644 --- a/pkgs/games/mudlet/default.nix +++ b/pkgs/games/mudlet/default.nix @@ -1,5 +1,5 @@ -{ fetchurl, pkgs, stdenv, makeWrapper, qtbase, yajl, libzip, hunspell -, boost, lua5_1, luafilesystem, luazip, lrexlib, luasqlite3 }: +{ fetchurl, unzip, stdenv, makeWrapper, qtbase, yajl, libzip, hunspell +, boost, lua5_1, luafilesystem, luazip, lrexlib, luasqlite3, qmakeHook }: stdenv.mkDerivation rec { name = "mudlet-${version}"; @@ -11,11 +11,11 @@ stdenv.mkDerivation rec { }; buildInputs = [ - pkgs.unzip qtbase lua5_1 hunspell libzip yajl boost makeWrapper - luafilesystem luazip lrexlib luasqlite3 + unzip qtbase lua5_1 hunspell libzip yajl boost makeWrapper + luafilesystem luazip lrexlib luasqlite3 qmakeHook ]; - configurePhase = "cd src && qmake"; + preConfigure = "cd src"; installPhase = let luaZipPath = "${luazip}/lib/lua/5.1/?.so"; From 34625f646c6407a354bc8ecaa17e204aa0b0e616 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:51:25 +0300 Subject: [PATCH 132/147] ppsspp: move to qmake4Hook --- pkgs/misc/emulators/ppsspp/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/misc/emulators/ppsspp/default.nix b/pkgs/misc/emulators/ppsspp/default.nix index 439566de0cad..87ae977c7cc7 100644 --- a/pkgs/misc/emulators/ppsspp/default.nix +++ b/pkgs/misc/emulators/ppsspp/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchgit, zlib, libpng, qt4, pkgconfig +{ stdenv, fetchgit, zlib, libpng, qt4, qmake4Hook, pkgconfig , withGamepads ? true, SDL # SDL is used for gamepad functionality }: @@ -19,10 +19,10 @@ stdenv.mkDerivation rec{ sha256 = "71dfa0be045f31969b1d6ab4f1adf6a208f9ef4834d708bc7bf6d9195efb5f80"; }; - buildInputs = [ zlib libpng pkgconfig qt4 ] + buildInputs = [ zlib libpng pkgconfig qt4 qmake4Hook ] ++ (if withGamepads then [ SDL ] else [ ]); - configurePhase = "cd Qt && qmake PPSSPPQt.pro"; + preConfigure = "cd Qt"; installPhase = "mkdir -p $out/bin && cp ppsspp $out/bin"; meta = { From de1ce6a102a53881fffff61b3888babf32320899 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:51:46 +0300 Subject: [PATCH 133/147] l7z: spaces --- pkgs/os-specific/linux/i7z/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/os-specific/linux/i7z/default.nix b/pkgs/os-specific/linux/i7z/default.nix index 1fe1f48f4ef3..1ca200a11210 100644 --- a/pkgs/os-specific/linux/i7z/default.nix +++ b/pkgs/os-specific/linux/i7z/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4, ncurses}: +{ stdenv, fetchurl, qt4, ncurses }: stdenv.mkDerivation rec { name = "i7z-0.27.2"; @@ -8,7 +8,7 @@ stdenv.mkDerivation rec { sha256 = "1wa7ix6m75wl3k2n88sz0x8cckvlzqklja2gvzqfw5rcfdjjvxx7"; }; - buildInputs = [qt4 ncurses]; + buildInputs = [ qt4 ncurses ]; buildPhase = '' make From e282d36143ea73756da19917fba53614118cc1fd Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:51:59 +0300 Subject: [PATCH 134/147] wpa_supplicant_gui: move to qmake4Hook --- pkgs/os-specific/linux/wpa_supplicant/gui.nix | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/pkgs/os-specific/linux/wpa_supplicant/gui.nix b/pkgs/os-specific/linux/wpa_supplicant/gui.nix index 59a3c51c4d6e..a75367f0bb0c 100644 --- a/pkgs/os-specific/linux/wpa_supplicant/gui.nix +++ b/pkgs/os-specific/linux/wpa_supplicant/gui.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4, inkscape, wpa_supplicant }: +{ stdenv, fetchurl, qt4, qmake4Hook, inkscape, wpa_supplicant }: stdenv.mkDerivation { name = "wpa_gui-${wpa_supplicant.version}"; @@ -7,14 +7,13 @@ stdenv.mkDerivation { buildInputs = [ qt4 ]; - nativeBuildInputs = [ inkscape ]; + nativeBuildInputs = [ inkscape qmake4Hook ]; prePatch = "cd wpa_supplicant/wpa_gui-qt4"; - configurePhase = + preConfigure = '' lrelease wpa_gui.pro - qmake ''; # We do not install .xpm icons. First of all, I don't know where they should From c48dd664ffb3ec497a1af400c9c2db95c23e9879 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:52:09 +0300 Subject: [PATCH 135/147] jom: move to qmake4Hook --- pkgs/os-specific/windows/jom/default.nix | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/pkgs/os-specific/windows/jom/default.nix b/pkgs/os-specific/windows/jom/default.nix index 4b118a5a7cdc..6537503add8f 100644 --- a/pkgs/os-specific/windows/jom/default.nix +++ b/pkgs/os-specific/windows/jom/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchgit, qt48, flex, cmake }: +{ stdenv, fetchgit, qt48, qmake4Hook, flex }: # At the time of committing this, the expression fails for me to cross-build in # both mingw32 and mingw64. @@ -13,12 +13,9 @@ stdenv.mkDerivation { }; buildInputs = [ qt48 ]; - nativeBuildInputs = [ flex /*cmake*/ ]; + nativeBuildInputs = [ flex qmake4Hook ]; QTDIR = qt48; - configurePhase = '' - qmake PREFIX=$out - ''; crossAttrs = { # cmakeFlags = "-DWIN32=1 -DCMAKE_SYSTEM_NAME=Windows -DCMAKE_RC_COMPILER=${stdenv.cross.config}-windres"; From a3a40c027c1ed3d07ebb76d885e25f95cdfa5e54 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:52:16 +0300 Subject: [PATCH 136/147] qastools: move to qmake4Hook --- pkgs/tools/audio/qastools/default.nix | 4 ++-- pkgs/top-level/all-packages.nix | 4 +--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/tools/audio/qastools/default.nix b/pkgs/tools/audio/qastools/default.nix index 3743b38a2103..3fe5b4b8d1a6 100644 --- a/pkgs/tools/audio/qastools/default.nix +++ b/pkgs/tools/audio/qastools/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, cmake, alsaLib, udev, qt }: +{ stdenv, fetchurl, cmake, alsaLib, udev, qt4 }: let version = "0.18.1"; @@ -13,7 +13,7 @@ stdenv.mkDerivation { }; buildInputs = [ - cmake alsaLib udev qt + cmake alsaLib udev qt4 ]; cmakeFlags = [ diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index e02186c5212e..55c5d4a54fb6 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -2970,9 +2970,7 @@ in qalculate-gtk = callPackage ../applications/science/math/qalculate-gtk { }; - qastools = callPackage ../tools/audio/qastools { - qt = qt4; - }; + qastools = callPackage ../tools/audio/qastools { }; qgifer = callPackage ../applications/video/qgifer { giflib = giflib_4_1; From cef0e565e3b983942582ee14867655b69703ba52 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:52:24 +0300 Subject: [PATCH 137/147] unetbootin: move to qmake4Hook --- pkgs/tools/cd-dvd/unetbootin/default.nix | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pkgs/tools/cd-dvd/unetbootin/default.nix b/pkgs/tools/cd-dvd/unetbootin/default.nix index 1234ecd770bb..bf8cefd057ef 100644 --- a/pkgs/tools/cd-dvd/unetbootin/default.nix +++ b/pkgs/tools/cd-dvd/unetbootin/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, makeWrapper, qt4, utillinux, coreutils, which +{ stdenv, fetchurl, makeWrapper, qt4, utillinux, coreutils, which, qmake4Hook , p7zip, mtools, syslinux }: stdenv.mkDerivation rec { @@ -12,7 +12,7 @@ stdenv.mkDerivation rec { sourceRoot = "."; - buildInputs = [ makeWrapper qt4 ]; + buildInputs = [ makeWrapper qt4 qmake4Hook ]; # Lots of nice hard-coded paths... postUnpack = '' @@ -30,11 +30,9 @@ stdenv.mkDerivation rec { --replace /usr/bin $out/bin ''; - buildPhase = '' + preConfigure = '' lupdate unetbootin.pro lrelease unetbootin.pro - qmake - make ''; installPhase = '' From 5a4cccd7e7f26361fc3829b8867474915d393b90 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:52:35 +0300 Subject: [PATCH 138/147] nifskope: move to qmake4Hook --- pkgs/tools/graphics/nifskope/default.nix | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/pkgs/tools/graphics/nifskope/default.nix b/pkgs/tools/graphics/nifskope/default.nix index 13dc27921a43..decd6fb56fd3 100644 --- a/pkgs/tools/graphics/nifskope/default.nix +++ b/pkgs/tools/graphics/nifskope/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, qt4 }: +{ stdenv, fetchurl, qt4, qmake4Hook }: stdenv.mkDerivation rec { name = "nifskope-1.1.3"; @@ -10,14 +10,16 @@ stdenv.mkDerivation rec { buildInputs = [ qt4 ]; - configurePhase = + nativeBuildInputs = [ qmake4Hook ]; + + preConfigure = '' for i in *.cpp gl/*.cpp widgets/*.cpp; do substituteInPlace $i --replace /usr/share/nifskope $out/share/nifskope done + ''; - qmake -after TARGET=nifskope - ''; # */ + qmakeFlags = [ "-after TARGET=nifskope" ]; enableParallelBuilding = true; From 6adce0a785b2876f48a9d73c02251b101f69c30b Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:52:46 +0300 Subject: [PATCH 139/147] touchegg: move to qmake4Hook --- pkgs/tools/inputmethods/touchegg/default.nix | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/pkgs/tools/inputmethods/touchegg/default.nix b/pkgs/tools/inputmethods/touchegg/default.nix index 4ac3c02d4103..6ab53f9d7633 100644 --- a/pkgs/tools/inputmethods/touchegg/default.nix +++ b/pkgs/tools/inputmethods/touchegg/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, xorg, xorgserver, qt4, mesa, geis }: +{ stdenv, fetchurl, xorg, xorgserver, qt4, mesa, geis, qmake4Hook }: stdenv.mkDerivation rec { name = "touchegg-${version}"; @@ -10,10 +10,11 @@ stdenv.mkDerivation rec { buildInputs = [ xorgserver mesa xorg.libX11 xorg.libXtst xorg.libXext qt4 geis ]; - configurePhase = '' + nativeBuildInputs = [ qmake4Hook ]; + + preConfigure = '' sed -e "s@/usr/@$out/@g" -i $(find . -name touchegg.pro) sed -e "s@/usr/@$out/@g" -i $(find ./src/touchegg/config/ -name Config.cpp) - qmake touchegg.pro ''; meta = { @@ -22,4 +23,4 @@ stdenv.mkDerivation rec { license = stdenv.lib.licenses.gpl2; platforms = stdenv.lib.platforms.linux; }; -} \ No newline at end of file +} From ea56bb7331221efa6be1bc290cd6ee8b6be17536 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:52:55 +0300 Subject: [PATCH 140/147] rockbox-utility: move to qmake4Hook --- pkgs/tools/misc/rockbox-utility/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/tools/misc/rockbox-utility/default.nix b/pkgs/tools/misc/rockbox-utility/default.nix index c9c0cf6949f8..54a6b0309b00 100644 --- a/pkgs/tools/misc/rockbox-utility/default.nix +++ b/pkgs/tools/misc/rockbox-utility/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, libusb1, qt4 }: +{ stdenv, fetchurl, libusb1, qt4, qmake4Hook }: stdenv.mkDerivation rec { name = "rockbox-utility-${version}"; @@ -10,10 +10,10 @@ stdenv.mkDerivation rec { }; buildInputs = [ libusb1 qt4 ]; + nativeBuildInputs = [ qmake4Hook ]; - preBuild = '' + preConfigure = '' cd rbutil/rbutilqt - qmake ''; installPhase = '' From 8ab48c32e7a3053ea5198c22c5881c93644c8a9c Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sun, 17 Apr 2016 02:53:07 +0300 Subject: [PATCH 141/147] yubikey-personalization-gui: move to qmake4Hook --- .../tools/misc/yubikey-personalization-gui/default.nix | 10 +++------- pkgs/top-level/all-packages.nix | 4 +--- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/pkgs/tools/misc/yubikey-personalization-gui/default.nix b/pkgs/tools/misc/yubikey-personalization-gui/default.nix index 57952b80daf5..4bc68aba29df 100644 --- a/pkgs/tools/misc/yubikey-personalization-gui/default.nix +++ b/pkgs/tools/misc/yubikey-personalization-gui/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, pkgconfig, yubikey-personalization, qt, libyubikey }: +{ stdenv, fetchurl, pkgconfig, yubikey-personalization, qt4, qmake4Hook, libyubikey }: stdenv.mkDerivation rec { name = "yubikey-personalization-gui-3.1.24"; @@ -8,13 +8,9 @@ stdenv.mkDerivation rec { sha256 = "0aj8cvajswkwzig0py0mjnfw0m8xsilisdcnixpjx9xxsxz5yacq"; }; - nativeBuildInputs = [ pkgconfig ]; - buildInputs = [ yubikey-personalization qt libyubikey ]; + nativeBuildInputs = [ pkgconfig qmake4Hook ]; + buildInputs = [ yubikey-personalization qt4 libyubikey ]; - configurePhase = '' - qmake - ''; - installPhase = '' mkdir -p $out/bin cp build/release/yubikey-personalization-gui $out/bin diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 55c5d4a54fb6..7eb9741b2404 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -9162,9 +9162,7 @@ in libusb = libusb1; }; - yubikey-personalization-gui = callPackage ../tools/misc/yubikey-personalization-gui { - qt = qt4; - }; + yubikey-personalization-gui = callPackage ../tools/misc/yubikey-personalization-gui { }; zeitgeist = callPackage ../development/libraries/zeitgeist { }; From 294d1f4c704fd82f25ea9652a3a30811ae082aa0 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Sat, 16 Apr 2016 22:59:17 +0300 Subject: [PATCH 142/147] cmst: move to qmakeHook This reverts commit 2c024d28a219f3283d8adb10049162bd45332eb8. --- pkgs/tools/networking/cmst/default.nix | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/pkgs/tools/networking/cmst/default.nix b/pkgs/tools/networking/cmst/default.nix index 5c8b801dbbe3..d9c6c2630fa6 100644 --- a/pkgs/tools/networking/cmst/default.nix +++ b/pkgs/tools/networking/cmst/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, qtbase, makeWrapper, libX11 }: +{ stdenv, fetchFromGitHub, qtbase, qmakeHook, makeWrapper, libX11 }: stdenv.mkDerivation rec { name = "cmst-2016.01.28"; @@ -10,10 +10,9 @@ stdenv.mkDerivation rec { owner = "andrew-bibb"; }; - buildInputs = [ qtbase makeWrapper ]; + buildInputs = [ qtbase makeWrapper qmakeHook ]; - configurePhase = '' - runHook preConfigure + preConfigure = '' substituteInPlace ./cmst.pro \ --replace "/usr/bin" "$out/bin" \ --replace "/usr/share" "$out/usr/share" @@ -29,14 +28,6 @@ stdenv.mkDerivation rec { substituteInPlace ./apps/rootapp/rootapp.pro \ --replace "/etc" "$out/etc" \ --replace "/usr/share" "$out/share" - runHook postConfigure - ''; - - buildPhase = '' - runHook preBuild - qmake PREFIX=$out - make - runHook postBuild ''; postInstall = '' From 039ff272ee979e536e0e3a24bfb7bd63c26701fc Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Wed, 20 Apr 2016 19:02:13 +0300 Subject: [PATCH 143/147] qt55: remove configureScript from qt5Submodule --- pkgs/development/libraries/qt-5/5.5/default.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/pkgs/development/libraries/qt-5/5.5/default.nix b/pkgs/development/libraries/qt-5/5.5/default.nix index abbbe8ef7a04..034e25662ea1 100644 --- a/pkgs/development/libraries/qt-5/5.5/default.nix +++ b/pkgs/development/libraries/qt-5/5.5/default.nix @@ -46,7 +46,6 @@ let NIX_QT_SUBMODULE = args.NIX_QT_SUBMODULE or true; dontFixLibtool = args.dontFixLibtool or true; - configureScript = args.configureScript or "qmake"; outputs = args.outputs or [ "dev" "out" ]; setOutputFlags = args.setOutputFlags or false; From 1c8ac5299914c5b2f2387b2012658dce03894c69 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Wed, 20 Apr 2016 20:36:26 +0200 Subject: [PATCH 144/147] groff: now really fix build after --docdir fix I forgot about some later changes around characters permitted in $shareDocName. --- pkgs/tools/text/groff/default.nix | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/pkgs/tools/text/groff/default.nix b/pkgs/tools/text/groff/default.nix index ee8f9b7037f8..728e9de8b488 100644 --- a/pkgs/tools/text/groff/default.nix +++ b/pkgs/tools/text/groff/default.nix @@ -32,13 +32,12 @@ stdenv.mkDerivation rec { ''; }; + # Remove example output with (random?) colors and creation date + # to avoid non-determinism in the output. postInstall = '' - # Remove example output with (random?) colors to - # avoid non-determinism in the output - rm $doc/share/doc/${name}/examples/hdtbl/*color*ps - # Remove creation date - find $doc/share/doc/${name} -type f -print0 | xargs -0 sed -i -e 's/%%CreationDate: .*//' - ''; + rm $doc/share/doc/groff/examples/hdtbl/*color*ps + find $doc/share/doc/groff/ -type f -print0 | xargs -0 sed -i -e 's/%%CreationDate: .*//' + ''; meta = with stdenv.lib; { homepage = http://www.gnu.org/software/groff/; From 4ea23ca27786c1084c64daa4550534ceecd2b149 Mon Sep 17 00:00:00 2001 From: Michiel Leenaars Date: Wed, 20 Apr 2016 22:42:44 +0200 Subject: [PATCH 145/147] gnutls: 3.4.6 -> 3.4.11 --- pkgs/development/libraries/gnutls/3.4.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/gnutls/3.4.nix b/pkgs/development/libraries/gnutls/3.4.nix index 6d196978cdf3..71c3010467ce 100644 --- a/pkgs/development/libraries/gnutls/3.4.nix +++ b/pkgs/development/libraries/gnutls/3.4.nix @@ -1,11 +1,11 @@ { callPackage, fetchurl, autoreconfHook, ... } @ args: callPackage ./generic.nix (args // rec { - version = "3.4.6"; + version = "3.4.11"; src = fetchurl { url = "ftp://ftp.gnutls.org/gcrypt/gnutls/v3.4/gnutls-${version}.tar.xz"; - sha256 = "1v109px1sy1s731fnawzdsvggdswmr7ha9q5lid4v8pzgznmkdgy"; + sha256 = "1f4sbb38xab46h67a3pm6kybgrahjx3vbrn66qq3cbc2jngrrvvh"; }; # This fixes some broken parallel dependencies From b845596f666a8458fb7476e2f861b14cda89be1e Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Thu, 21 Apr 2016 03:12:49 +0300 Subject: [PATCH 146/147] golden-cheetah: use qmakeHook --- pkgs/applications/misc/golden-cheetah/default.nix | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/pkgs/applications/misc/golden-cheetah/default.nix b/pkgs/applications/misc/golden-cheetah/default.nix index 82695bbdd7ee..5c471919f24a 100644 --- a/pkgs/applications/misc/golden-cheetah/default.nix +++ b/pkgs/applications/misc/golden-cheetah/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, qtbase, qtsvg, qtserialport, qtwebkit, qtmultimedia -, qttools, yacc, flex, zlib, config, makeQtWrapper }: +, qttools, yacc, flex, zlib, config, qmakeHook, makeQtWrapper }: stdenv.mkDerivation rec { name = "golden-cheetah-${version}"; version = "V4.0-DEV1603"; @@ -10,20 +10,19 @@ stdenv.mkDerivation rec { buildInputs = [ qtbase qtsvg qtserialport qtwebkit qtmultimedia qttools yacc flex zlib ]; - nativeBuildInputs = [ makeQtWrapper ]; - configurePhase = '' - runHook preConfigure + nativeBuildInputs = [ makeQtWrapper qmakeHook ]; + preConfigure = '' cp src/gcconfig.pri.in src/gcconfig.pri cp qwt/qwtconfig.pri.in qwt/qwtconfig.pri echo 'QMAKE_LRELEASE = ${qttools}/bin/lrelease' >> src/gcconfig.pri sed -i -e '21,23d' qwt/qwtconfig.pri # Removed forced installation to /usr/local - qmake PREFIX=$out build.pro - '' + ( + ''; + postConfigure = with (config.golden-cheetah); stdenv.lib.optionalString (dropbox-client-id != null && dropbox-client-secret != null) '' echo 'DEFINES += GC_DROPBOX_CLIENT_ID=\\\"${config.golden-cheetah.dropbox-client-id}\\\"' >> src/gcconfig.pri echo 'DEFINES += GC_DROPBOX_CLIENT_SECRET=\\\"${config.golden-cheetah.dropbox-client-secret}\\\"' >> src/gcconfig.pri - ''); + ''; installPhase = '' mkdir -p $out/bin cp src/GoldenCheetah $out/bin From 9ea3e371df617725eab1a8beacc05bd5eefdca6f Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Thu, 21 Apr 2016 04:57:01 -0500 Subject: [PATCH 147/147] qt5: handle dev output even without qmake --- .../libraries/qt-5/5.4/qmake-hook.sh | 21 +----------------- .../libraries/qt-5/5.4/qtbase/setup-hook.sh | 22 +++++++++++++++++++ .../libraries/qt-5/5.5/qmake-hook.sh | 21 +----------------- .../libraries/qt-5/5.5/qtbase/setup-hook.sh | 22 +++++++++++++++++++ 4 files changed, 46 insertions(+), 40 deletions(-) diff --git a/pkgs/development/libraries/qt-5/5.4/qmake-hook.sh b/pkgs/development/libraries/qt-5/5.4/qmake-hook.sh index e8838b854b50..a38f9f578e38 100644 --- a/pkgs/development/libraries/qt-5/5.4/qmake-hook.sh +++ b/pkgs/development/libraries/qt-5/5.4/qmake-hook.sh @@ -36,19 +36,6 @@ _qtRmModules() { rm "$out/nix-support/qt-inputs" } -_qtPropagateRuntimeDependencies() { - for dir in "lib/qt5/plugins" "lib/qt5/qml" "lib/qt5/imports"; do - if [ -d "$1/$dir" ]; then - propagateOnce propagatedBuildInputs "$1" - propagateOnce propagatedUserEnvPkgs "$1" - break - fi - done - addToSearchPathOnce QT_PLUGIN_PATH "$1/lib/qt5/plugins" - addToSearchPathOnce QML_IMPORT_PATH "$1/lib/qt5/imports" - addToSearchPathOnce QML2_IMPORT_PATH "$1/lib/qt5/qml" -} - _qtRmQmake() { rm "$qtOut/bin/qmake" "$qtOut/bin/qt.conf" } @@ -68,11 +55,6 @@ _qtMultioutModuleDevs() { moveToOutput "share/doc" "${!outputDev}" } -_qtMultioutDevs() { - # This is necessary whether the package is a Qt module or not - moveToOutput "mkspecs" "${!outputDev}" -} - qmakeConfigurePhase() { runHook preConfigure @@ -102,7 +84,7 @@ EOF export QMAKE="$qtOut/bin/qmake" -envHooks+=(_qtLinkModule _qtPropagateRuntimeDependencies) +envHooks+=(_qtLinkModule) # Set PATH to find qmake first in a preConfigure hook # It must run after all the envHooks! postHooks+=(_qtSetQmakePath) @@ -111,7 +93,6 @@ if [ -z "$dontUseQmakeConfigure" -a -z "$configurePhase" ]; then configurePhase=qmakeConfigurePhase fi -preFixupHooks+=(_qtMultioutDevs) if [ -n "$NIX_QT_SUBMODULE" ]; then postInstallHooks+=(_qtRmQmake _qtRmModules) preFixupHooks+=(_qtMultioutModuleDevs) diff --git a/pkgs/development/libraries/qt-5/5.4/qtbase/setup-hook.sh b/pkgs/development/libraries/qt-5/5.4/qtbase/setup-hook.sh index 645449a89133..a9c4fbc855f7 100644 --- a/pkgs/development/libraries/qt-5/5.4/qtbase/setup-hook.sh +++ b/pkgs/development/libraries/qt-5/5.4/qtbase/setup-hook.sh @@ -24,6 +24,28 @@ propagateOnce() { addToSearchPathOnceWithCustomDelimiter ' ' "$@" } +_qtPropagateRuntimeDependencies() { + for dir in "lib/qt5/plugins" "lib/qt5/qml" "lib/qt5/imports"; do + if [ -d "$1/$dir" ]; then + propagateOnce propagatedBuildInputs "$1" + propagateOnce propagatedUserEnvPkgs "$1" + break + fi + done + addToSearchPathOnce QT_PLUGIN_PATH "$1/lib/qt5/plugins" + addToSearchPathOnce QML_IMPORT_PATH "$1/lib/qt5/imports" + addToSearchPathOnce QML2_IMPORT_PATH "$1/lib/qt5/qml" +} + +envHooks+=(_qtPropagateRuntimeDependencies) + +_qtMultioutDevs() { + # This is necessary whether the package is a Qt module or not + moveToOutput "mkspecs" "${!outputDev}" +} + +preFixupHooks+=(_qtMultioutDevs) + if [[ -z "$NIX_QT_PIC" ]]; then export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE${NIX_CFLAGS_COMPILE:+ }-fPIC" export NIX_QT_PIC=1 diff --git a/pkgs/development/libraries/qt-5/5.5/qmake-hook.sh b/pkgs/development/libraries/qt-5/5.5/qmake-hook.sh index 209dcd8a062a..f059c19e03bb 100644 --- a/pkgs/development/libraries/qt-5/5.5/qmake-hook.sh +++ b/pkgs/development/libraries/qt-5/5.5/qmake-hook.sh @@ -36,19 +36,6 @@ _qtRmModules() { rm "$out/nix-support/qt-inputs" } -_qtPropagateRuntimeDependencies() { - for dir in "lib/qt5/plugins" "lib/qt5/qml" "lib/qt5/imports"; do - if [ -d "$1/$dir" ]; then - propagateOnce propagatedBuildInputs "$1" - propagateOnce propagatedUserEnvPkgs "$1" - break - fi - done - addToSearchPathOnce QT_PLUGIN_PATH "$1/lib/qt5/plugins" - addToSearchPathOnce QML_IMPORT_PATH "$1/lib/qt5/imports" - addToSearchPathOnce QML2_IMPORT_PATH "$1/lib/qt5/qml" -} - _qtRmQmake() { rm "$qtOut/bin/qmake" "$qtOut/bin/qt.conf" } @@ -68,11 +55,6 @@ _qtMultioutModuleDevs() { moveToOutput "share/doc" "${!outputDev}" } -_qtMultioutDevs() { - # This is necessary whether the package is a Qt module or not - moveToOutput "mkspecs" "${!outputDev}" -} - qmakeConfigurePhase() { runHook preConfigure @@ -102,7 +84,7 @@ EOF export QMAKE="$qtOut/bin/qmake" -envHooks+=(_qtLinkModule _qtPropagateRuntimeDependencies) +envHooks+=(_qtLinkModule) # Set PATH to find qmake first in a preConfigure hook # It must run after all the envHooks! postHooks+=(_qtSetQmakePath) @@ -111,7 +93,6 @@ if [ -z "$dontUseQmakeConfigure" -a -z "$configurePhase" ]; then configurePhase=qmakeConfigurePhase fi -preFixupHooks+=(_qtMultioutDevs) if [ -n "$NIX_QT_SUBMODULE" ]; then postInstallHooks+=(_qtRmQmake _qtRmModules) preFixupHooks+=(_qtMultioutModuleDevs) diff --git a/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh b/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh index 645449a89133..a9c4fbc855f7 100644 --- a/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh +++ b/pkgs/development/libraries/qt-5/5.5/qtbase/setup-hook.sh @@ -24,6 +24,28 @@ propagateOnce() { addToSearchPathOnceWithCustomDelimiter ' ' "$@" } +_qtPropagateRuntimeDependencies() { + for dir in "lib/qt5/plugins" "lib/qt5/qml" "lib/qt5/imports"; do + if [ -d "$1/$dir" ]; then + propagateOnce propagatedBuildInputs "$1" + propagateOnce propagatedUserEnvPkgs "$1" + break + fi + done + addToSearchPathOnce QT_PLUGIN_PATH "$1/lib/qt5/plugins" + addToSearchPathOnce QML_IMPORT_PATH "$1/lib/qt5/imports" + addToSearchPathOnce QML2_IMPORT_PATH "$1/lib/qt5/qml" +} + +envHooks+=(_qtPropagateRuntimeDependencies) + +_qtMultioutDevs() { + # This is necessary whether the package is a Qt module or not + moveToOutput "mkspecs" "${!outputDev}" +} + +preFixupHooks+=(_qtMultioutDevs) + if [[ -z "$NIX_QT_PIC" ]]; then export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE${NIX_CFLAGS_COMPILE:+ }-fPIC" export NIX_QT_PIC=1