summary refs log tree commit diff
path: root/pkgs/development
diff options
context:
space:
mode:
authorJohn Ericson <John.Ericson@Obsidian.Systems>2018-05-10 01:38:34 -0400
committerJohn Ericson <John.Ericson@Obsidian.Systems>2018-05-10 01:57:49 -0400
commit7d0906eea89f94b24d9df9af90579a88422dc126 (patch)
tree25bca7ad55bb6c4a3d5a6676fcef154c6941e376 /pkgs/development
parentfeb648ce59ffbed94c58133eb7aa2761992a35e1 (diff)
downloadnixpkgs-7d0906eea89f94b24d9df9af90579a88422dc126.tar
nixpkgs-7d0906eea89f94b24d9df9af90579a88422dc126.tar.gz
nixpkgs-7d0906eea89f94b24d9df9af90579a88422dc126.tar.bz2
nixpkgs-7d0906eea89f94b24d9df9af90579a88422dc126.tar.lz
nixpkgs-7d0906eea89f94b24d9df9af90579a88422dc126.tar.xz
nixpkgs-7d0906eea89f94b24d9df9af90579a88422dc126.tar.zst
nixpkgs-7d0906eea89f94b24d9df9af90579a88422dc126.zip
fontconfig: Clean up cross
Diffstat (limited to 'pkgs/development')
-rw-r--r--pkgs/development/libraries/fontconfig/2.10.nix12
-rw-r--r--pkgs/development/libraries/fontconfig/default.nix12
2 files changed, 2 insertions, 22 deletions
diff --git a/pkgs/development/libraries/fontconfig/2.10.nix b/pkgs/development/libraries/fontconfig/2.10.nix
index 5fb0ea4429e..6f711341fad 100644
--- a/pkgs/development/libraries/fontconfig/2.10.nix
+++ b/pkgs/development/libraries/fontconfig/2.10.nix
@@ -17,23 +17,13 @@ stdenv.mkDerivation rec {
   buildInputs = [ expat ];
 
   configureFlags = [
+    "--with-arch=${hostPlatform.parsed.cpu.name}"
     "--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 = if stdenv.hostPlatform != stdenv.buildPlatform
-    then hostPlatform.parsed.cpu.name
-    else null;
-
-  preConfigure = ''
-    if test -n "$crossConfig"; then
-      configureFlags="$configureFlags --with-arch=$crossArch";
-    fi
-  '';
-
   enableParallelBuilding = true;
 
   doCheck = true;
diff --git a/pkgs/development/libraries/fontconfig/default.nix b/pkgs/development/libraries/fontconfig/default.nix
index a4f6fe007d0..4d0b1a7f115 100644
--- a/pkgs/development/libraries/fontconfig/default.nix
+++ b/pkgs/development/libraries/fontconfig/default.nix
@@ -40,23 +40,13 @@ stdenv.mkDerivation rec {
   buildInputs = [ expat ];
 
   configureFlags = [
+    "--with-arch=${hostPlatform.parsed.cpu.name}"
     "--with-cache-dir=/var/cache/fontconfig" # otherwise the fallback is in $out/
     "--disable-docs"
     # just <1MB; this is what you get when loading config fails for some reason
     "--with-default-fonts=${dejavu_fonts.minimal}"
   ];
 
-  # We should find a better way to access the arch reliably.
-  crossArch = if stdenv.hostPlatform != stdenv.buildPlatform
-    then hostPlatform.parsed.cpu.name
-    else null;
-
-  preConfigure = ''
-    if test -n "$crossConfig"; then
-      configureFlags="$configureFlags --with-arch=$crossArch";
-    fi
-  '';
-
   enableParallelBuilding = true;
 
   doCheck = true;