diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm index 0cb4adac76..e1d0e5ec07 100644 --- a/gnu/packages/gnome-xyz.scm +++ b/gnu/packages/gnome-xyz.scm @@ -227,11 +227,10 @@ (define-public papirus-icon-theme (symlink? (lambda (_ stat) (eq? 'symlink (stat:type stat))))) (for-each (lambda (file) - (with-directory-excursion (dirname file) - (let ((target (readlink file))) - (when (eq? 'regular (stat:type (stat target))) - (delete-file file) - (link target file))))) + (let ((target (canonicalize-path file))) + (when (eq? 'regular (stat:type (stat target))) + (delete-file file) + (link target file)))) (find-files out symlink?)))))))) (native-inputs (list `(,gtk+ "bin")))