From df99ec18dce556627fb01ce571e6fc3f2ae24c40 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= <vcunat@gmail.com>
Date: Fri, 18 Jul 2014 11:54:10 +0200
Subject: [PATCH] inkscape: enableParallelBuilding, doCheck, add meta

---
 pkgs/applications/graphics/inkscape/default.nix | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/pkgs/applications/graphics/inkscape/default.nix b/pkgs/applications/graphics/inkscape/default.nix
index 43a4d86b48d7..bc55b0ff6800 100644
--- a/pkgs/applications/graphics/inkscape/default.nix
+++ b/pkgs/applications/graphics/inkscape/default.nix
@@ -13,6 +13,9 @@ stdenv.mkDerivation rec {
 
   patches = [ ./configure-python-libs.patch ];
 
+  postPatch = stdenv.lib.optionalString doCheck
+    ''sed -i 's:#include "../../src:#include "src:' src/cxxtests.cpp'';
+
   propagatedBuildInputs = [
     # Python is used at run-time to execute scripts, e.g., those from
     # the "Effects" menu.
@@ -27,6 +30,10 @@ stdenv.mkDerivation rec {
 
   configureFlags = "--with-python";
 
+  enableParallelBuilding = true;
+  doCheck = true;
+  checkFlags = "-j1";
+
   postInstall = ''
     # Make sure PyXML modules can be found at run-time.
     for i in "$out/bin/"*
@@ -40,9 +47,11 @@ stdenv.mkDerivation rec {
 
   NIX_LDFLAGS = "-lX11";
 
-  meta = {
+  meta = with stdenv.lib; {
     license = "GPL";
     homepage = http://www.inkscape.org;
+    description = "Vector graphics editor";
+    platforms = platforms.all;
     longDescription = ''
       Inkscape is a feature-rich vector graphics editor that edits
       files in the W3C SVG (Scalable Vector Graphics) file format.