about summary refs log tree commit diff
path: root/pkgs/applications/misc/xca
diff options
context:
space:
mode:
authorPeter Hoeg <peter@speartail.com>2016-10-21 12:27:01 +0800
committerPeter Hoeg <peter@speartail.com>2017-01-02 00:17:48 +0800
commitaec8872e2398ddc83916ca9eab30d55cacb96c06 (patch)
tree2629dc35b7a5b3d0fda728d641fa4d5171ae3aa4 /pkgs/applications/misc/xca
parentd15c62a2a0135bb8968f17326ebda271748cb7f6 (diff)
xca: qt4 -> qt5
Compile against qt5 instead of qt4.
Diffstat (limited to 'pkgs/applications/misc/xca')
-rw-r--r--pkgs/applications/misc/xca/default.nix26
1 files changed, 19 insertions, 7 deletions
diff --git a/pkgs/applications/misc/xca/default.nix b/pkgs/applications/misc/xca/default.nix
index e861973b13cc2..8515efc56bce8 100644
--- a/pkgs/applications/misc/xca/default.nix
+++ b/pkgs/applications/misc/xca/default.nix
@@ -1,4 +1,7 @@
-{ stdenv, fetchurl, pkgconfig, which, openssl, qt4, libtool, gcc, makeWrapper }:
+{ stdenv, fetchurl, pkgconfig, which, makeQtWrapper,
+  libtool, openssl, qtbase, qttools }:
+
+with stdenv.lib;
 
 stdenv.mkDerivation rec {
   name = "xca-${version}";
@@ -9,19 +12,28 @@ stdenv.mkDerivation rec {
     sha256 = "1r2w9gpahjv221j963bd4vn0gj4cxmb9j42f3cd9qdn890hizw84";
   };
 
-  postInstall = ''
-    wrapProgram "$out/bin/xca" \
-      --prefix LD_LIBRARY_PATH : \
-        "${gcc.cc.lib}/lib64:${stdenv.lib.makeLibraryPath [ qt4 gcc.cc openssl libtool ]}"
+  enableParallelBuilding = false;
+
+  buildInputs = [ libtool openssl qtbase qttools ];
+
+  nativeBuildInputs = [ makeQtWrapper pkgconfig which ];
+
+  preBuild = ''
+    substituteInPlace Local.mak \
+      --replace ${qtbase}/bin/moc ${qtbase.dev}/bin/moc \
+      --replace ${qtbase}/bin/uic ${qtbase.dev}/bin/uic
   '';
 
-  buildInputs = [ openssl qt4 libtool gcc makeWrapper ];
-  nativeBuildInputs = [ pkgconfig ];
+  postInstall = ''
+    wrapQtProgram "$out/bin/xca"
+    wrapQtProgram "$out/bin/xca_db_stat"
+  '';
 
   meta = with stdenv.lib; {
     description = "Interface for managing asymetric keys like RSA or DSA";
     homepage = http://xca.sourceforge.net/;
     platforms = platforms.all;
     license = licenses.bsd3;
+    maintainers = with maintainers; [ offline peterhoeg ];
   };
 }