aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--guix/build/union.scm17
1 files changed, 13 insertions, 4 deletions
diff --git a/guix/build/union.scm b/guix/build/union.scm
index 24b366af45..fff795c4d3 100644
--- a/guix/build/union.scm
+++ b/guix/build/union.scm
@@ -81,14 +81,23 @@ identical, #f otherwise."
(or (eof-object? n1)
(loop))))))))))))))
+(define %harmless-collisions
+ ;; This is a list of files that are known to collide, but for which emitting
+ ;; a warning doesn't make sense. For example, "icon-theme.cache" is
+ ;; regenerated by a profile hook which shadows the file provided by
+ ;; individual packages, and "gschemas.compiled" is made available to
+ ;; applications via 'glib-or-gtk-build-system'.
+ '("icon-theme.cache" "gschemas.compiled"))
+
(define (warn-about-collision files)
"Handle the collision among FILES by emitting a warning and choosing the
first one of THEM."
- (format (current-error-port)
- "~%warning: collision encountered:~%~{ ~a~%~}"
- files)
(let ((file (first files)))
- (format (current-error-port) "warning: choosing ~a~%" file)
+ (unless (member (basename file) %harmless-collisions)
+ (format (current-error-port)
+ "~%warning: collision encountered:~%~{ ~a~%~}"
+ files)
+ (format (current-error-port) "warning: choosing ~a~%" file))
file))
(define* (union-build output inputs