summary refs log tree commit diff
path: root/pkgs/development/libraries/fontconfig/2.10.nix
diff options
context:
space:
mode:
authorLuca Bruno <lucabru@src.gnome.org>2014-09-27 20:08:45 +0200
committerVladimír Čunát <vcunat@gmail.com>2014-10-23 10:40:26 +0200
commit0927405a371292e9abddb2365540e46e2f1cc2c7 (patch)
treedc9ea8aa8c6a83844cba7aa4a1cd43a5608e15d0 /pkgs/development/libraries/fontconfig/2.10.nix
parentb772f53acb1acac0e5b1d10f7e53f5e70ed2c581 (diff)
downloadnixpkgs-0927405a371292e9abddb2365540e46e2f1cc2c7.tar
nixpkgs-0927405a371292e9abddb2365540e46e2f1cc2c7.tar.gz
nixpkgs-0927405a371292e9abddb2365540e46e2f1cc2c7.tar.bz2
nixpkgs-0927405a371292e9abddb2365540e46e2f1cc2c7.tar.lz
nixpkgs-0927405a371292e9abddb2365540e46e2f1cc2c7.tar.xz
nixpkgs-0927405a371292e9abddb2365540e46e2f1cc2c7.tar.zst
nixpkgs-0927405a371292e9abddb2365540e46e2f1cc2c7.zip
fontconfig: update 2.10.2 -> 2.11.1. Close #4410, #2050
Diffstat (limited to 'pkgs/development/libraries/fontconfig/2.10.nix')
-rw-r--r--pkgs/development/libraries/fontconfig/2.10.nix61
1 files changed, 61 insertions, 0 deletions
diff --git a/pkgs/development/libraries/fontconfig/2.10.nix b/pkgs/development/libraries/fontconfig/2.10.nix
new file mode 100644
index 00000000000..2951dbb44d4
--- /dev/null
+++ b/pkgs/development/libraries/fontconfig/2.10.nix
@@ -0,0 +1,61 @@
+{ stdenv, fetchurl, pkgconfig, freetype, expat }:
+
+stdenv.mkDerivation rec {
+  name = "fontconfig-2.10.2";
+
+  src = fetchurl {
+    url = "http://fontconfig.org/release/${name}.tar.bz2";
+    sha256 = "0llraqw86jmw4vzv7inskp3xxm2gc64my08iwq5mzncgfdbfza4f";
+  };
+
+  infinality_patch =
+    let subvers = "1";
+      in fetchurl {
+        url = http://www.infinality.net/fedora/linux/zips/fontconfig-infinality-1-20130104_1.tar.bz2;
+        sha256 = "1fm5xx0mx2243jrq5rxk4v0ajw2nawpj23399h710bx6hd1rviq7";
+      }
+    ;
+
+  propagatedBuildInputs = [ freetype ];
+  buildInputs = [ pkgconfig expat ];
+
+  configureFlags = [
+    "--sysconfdir=/etc"
+    "--with-cache-dir=/var/cache/fontconfig"
+    "--disable-docs"
+    "--with-default-fonts="
+  ];
+
+  # We should find a better way to access the arch reliably.
+  crossArch = stdenv.cross.arch or null;
+
+  preConfigure = ''
+    if test -n "$crossConfig"; then
+      configureFlags="$configureFlags --with-arch=$crossArch";
+    fi
+  '';
+
+  enableParallelBuilding = true;
+
+  doCheck = true;
+
+  # Don't try to write to /var/cache/fontconfig at install time.
+  installFlags = "sysconfdir=$(out)/etc fc_cachedir=$(TMPDIR)/dummy RUN_FC_CACHE_TEST=false";
+
+  postInstall = ''
+    cd "$out/etc/fonts" && tar xvf ${infinality_patch}
+  '';
+
+  passthru = {
+    # Empty for backward compatibility, there was no versioning before 2.11
+    configVersion = "";
+  };
+
+  meta = with stdenv.lib; {
+    description = "A library for font customization and configuration";
+    homepage = http://fontconfig.org/;
+    license = licenses.bsd2; # custom but very bsd-like
+    platforms = platforms.all;
+    maintainers = [ maintainers.vcunat ];
+  };
+}