summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard W.M. Jones <rjones@redhat.com>2012-02-09 08:56:44 +0000
committerRichard W.M. Jones <rjones@redhat.com>2012-02-09 10:10:30 +0000
commitb0be22cc5182f49084419392248f7b2de8a0781c (patch)
treeed43b85fd12d218b75614067cc0604c33ffe35b0
parentf03d46334bb318fad7a7b71900d6a3c11586b68f (diff)
downloadfebootstrap-b0be22cc5182f49084419392248f7b2de8a0781c.tar.gz
febootstrap-b0be22cc5182f49084419392248f7b2de8a0781c.tar.xz
febootstrap-b0be22cc5182f49084419392248f7b2de8a0781c.zip
Allow two config files in different packages, if exactly one is %ghost.
This works around this Fedora problem: https://bugzilla.redhat.com/show_bug.cgi?id=733117#c4
-rw-r--r--src/febootstrap.ml9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/febootstrap.ml b/src/febootstrap.ml
index 7e48206..65198f5 100644
--- a/src/febootstrap.ml
+++ b/src/febootstrap.ml
@@ -95,10 +95,15 @@ let () =
if ft1.ft_config || ft2.ft_config then (
(* It's a fairly frequent bug in Fedora for two packages to
* incorrectly list the same config file. Allow this, provided
- * the size of both files is 0.
- *)
+ * the size of both files is 0; or one is a ghost file and the
+ * other is not.
+ *)
if ft1.ft_size = 0 && ft2.ft_size = 0 then
(name1, ft1, pkg1)
+ else if not ft1.ft_ghost && ft2.ft_ghost then
+ (name1, ft1, pkg1)
+ else if ft1.ft_ghost && not ft2.ft_ghost then
+ (name2, ft2, pkg2)
else (
eprintf "febootstrap: error: %s is a config file which is listed in two packages (%s, %s)\n"
name1 pkg1 pkg2;