From 9729387a99fcff79e06dfd631f74a2923a84d585 Mon Sep 17 00:00:00 2001 From: K900 Date: Fri, 30 Aug 2024 08:56:00 +0300 Subject: [PATCH] fontconfig: fix properly, remove NixOS module hack This reverts 49d33d4a6b15330b492a194edc4b67fb20a15fa1. --- nixos/modules/config/fonts/fontconfig.nix | 8 +------- pkgs/development/libraries/fontconfig/default.nix | 1 + 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/nixos/modules/config/fonts/fontconfig.nix b/nixos/modules/config/fonts/fontconfig.nix index a44b1fecd29a..9a9ac08eefeb 100644 --- a/nixos/modules/config/fonts/fontconfig.nix +++ b/nixos/modules/config/fonts/fontconfig.nix @@ -180,14 +180,8 @@ let mkdir -p $dst # fonts.conf - cp ${pkg.out}/etc/fonts/fonts.conf \ + ln -s ${pkg.out}/etc/fonts/fonts.conf \ $dst/../fonts.conf - - # horrible sed hack to add the line that was accidentally removed - # from the default config in #324516 - # FIXME: fix that, revert this - sed "5i /etc/fonts/conf.d" -i $dst/../fonts.conf - # TODO: remove this legacy symlink once people stop using packages built before #95358 was merged mkdir -p $out/etc/fonts/2.11 ln -s /etc/fonts/fonts.conf \ diff --git a/pkgs/development/libraries/fontconfig/default.nix b/pkgs/development/libraries/fontconfig/default.nix index 569c2716f0e5..83c5e3afc271 100644 --- a/pkgs/development/libraries/fontconfig/default.nix +++ b/pkgs/development/libraries/fontconfig/default.nix @@ -69,6 +69,7 @@ stdenv.mkDerivation (finalAttrs: { postInstall = '' cd "$out/etc/fonts" xsltproc --stringparam fontDirectories "${dejavu_fonts.minimal}" \ + --stringparam includes /etc/fonts/conf.d \ --path $out/share/xml/fontconfig \ ${./make-fonts-conf.xsl} $out/etc/fonts/fonts.conf \ > fonts.conf.tmp