]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
wafsamba: let reduce_objects() not remove duplicates of BUILTINS even if there are...
authorStefan Metzmacher <metze@samba.org>
Fri, 20 Aug 2021 14:25:02 +0000 (16:25 +0200)
committerStefan Metzmacher <metze@samba.org>
Tue, 30 Nov 2021 15:53:34 +0000 (15:53 +0000)
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14780

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
buildtools/wafsamba/samba_deps.py

index cb8acfae34e8b5615fce839b9f44237b032f3e8b..8d76e2e434eb48ddc7f1458d23f8cd4823813570 100644 (file)
@@ -718,8 +718,12 @@ def reduce_objects(bld, tgt_list):
                     dup = dup.difference(rely_on[t.sname])
                 if dup:
                     # Do not remove duplicates of BUILTINS
-                    d = next(iter(dup))
-                    if BUILTIN_LIBRARY(bld, d):
+                    for d in iter(dup.copy()):
+                        if BUILTIN_LIBRARY(bld, d):
+                            debug('deps: BUILTIN_LIBRARY SKIP: removing dups from %s of type %s: %s also in %s %s',
+                                  t.sname, t.samba_type, d, t2.samba_type, l)
+                            dup.remove(d)
+                    if len(dup) == 0:
                         continue
 
                     debug('deps: removing dups from %s of type %s: %s also in %s %s',