diff options
| author | Ludovic Courtès <ludo@gnu.org> | 2016-03-20 15:27:44 +0100 |
|---|---|---|
| committer | Ludovic Courtès <ludo@gnu.org> | 2016-03-20 15:27:44 +0100 |
| commit | e71ef7adaece7e132a5059139122b45083ea1b39 (patch) | |
| tree | 24805ba5c5dba0837e421f4d265ddf55a2b74239 /gnu/system | |
| parent | 0bd3597bbe0acb901f63ef386489eebb8e177c1c (diff) | |
system: Make sure fonts are searched for in the system profile.
This fixes a bug whereby fonts in /run/current-system/profile would be
invisible to Fontconfig.
* gnu/packages/fontutils.scm (fontconfig): Add comment about system
profile not being searched.
* gnu/system/shadow.scm (default-skeletons)[fonts.conf-content,
fonts.conf]: New variable.
Add FONTS.CONF to the skeletons.
Diffstat (limited to 'gnu/system')
| -rw-r--r-- | gnu/system/shadow.scm | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/gnu/system/shadow.scm b/gnu/system/shadow.scm index 6e62aeee574..a13ef1192c1 100644 --- a/gnu/system/shadow.scm +++ b/gnu/system/shadow.scm | |||
| @@ -131,6 +131,12 @@ | |||
| 131 | (define (default-skeletons) | 131 | (define (default-skeletons) |
| 132 | "Return the default skeleton files for /etc/skel. These files are copied by | 132 | "Return the default skeleton files for /etc/skel. These files are copied by |
| 133 | 'useradd' in the home directory of newly created user accounts." | 133 | 'useradd' in the home directory of newly created user accounts." |
| 134 | (define fonts.conf-content | ||
| 135 | ;; SXML for ~/.config/fontconfig/fonts.conf. This works around the fact | ||
| 136 | ;; that Fontconfig currently does not such this directory by default, | ||
| 137 | ;; thereby ignoring fonts installed system-wide (FIXME). | ||
| 138 | `(fontconfig (dir "/run/current-system/profile/share/fonts"))) | ||
| 139 | |||
| 134 | (define copy-guile-wm | 140 | (define copy-guile-wm |
| 135 | #~(begin | 141 | #~(begin |
| 136 | (use-modules (guix build utils)) | 142 | (use-modules (guix build utils)) |
| @@ -174,6 +180,22 @@ source /etc/profile\n")) | |||
| 174 | (xdefaults (plain-file "Xdefaults" "\ | 180 | (xdefaults (plain-file "Xdefaults" "\ |
| 175 | XTerm*utf8: always | 181 | XTerm*utf8: always |
| 176 | XTerm*metaSendsEscape: true\n")) | 182 | XTerm*metaSendsEscape: true\n")) |
| 183 | (fonts.conf (computed-file | ||
| 184 | "fonts.conf" | ||
| 185 | #~(begin | ||
| 186 | (use-modules (guix build utils) | ||
| 187 | (sxml simple)) | ||
| 188 | |||
| 189 | (define dir | ||
| 190 | (string-append #$output | ||
| 191 | "/fontconfig")) | ||
| 192 | |||
| 193 | (mkdir-p dir) | ||
| 194 | (call-with-output-file (string-append dir | ||
| 195 | "/fonts.conf") | ||
| 196 | (lambda (port) | ||
| 197 | (sxml->xml '#$fonts.conf-content port)))) | ||
| 198 | #:modules '((guix build utils)))) | ||
| 177 | (gdbinit (plain-file "gdbinit" "\ | 199 | (gdbinit (plain-file "gdbinit" "\ |
| 178 | # Tell GDB where to look for separate debugging files. | 200 | # Tell GDB where to look for separate debugging files. |
| 179 | set debug-file-directory ~/.guix-profile/lib/debug\n"))) | 201 | set debug-file-directory ~/.guix-profile/lib/debug\n"))) |
| @@ -182,6 +204,7 @@ set debug-file-directory ~/.guix-profile/lib/debug\n"))) | |||
| 182 | (".zlogin" ,zlogin) | 204 | (".zlogin" ,zlogin) |
| 183 | (".Xdefaults" ,xdefaults) | 205 | (".Xdefaults" ,xdefaults) |
| 184 | (".guile-wm" ,guile-wm) | 206 | (".guile-wm" ,guile-wm) |
| 207 | (".config" ,fonts.conf) | ||
| 185 | (".gdbinit" ,gdbinit)))) | 208 | (".gdbinit" ,gdbinit)))) |
| 186 | 209 | ||
| 187 | (define (skeleton-directory skeletons) | 210 | (define (skeleton-directory skeletons) |
