public inbox for
help / color / mirror / Atom feed
From: Florian Weimer <>
Subject: [glibc/release/2.36/master] scripts/ Generate program run-time dependencies
Date: Tue, 20 Sep 2022 09:43:00 +0000 (GMT)	[thread overview]
Message-ID: <> (raw);h=7a3f8c8a7aeb41d4bbfeec07d0be1e92c3019919

commit 7a3f8c8a7aeb41d4bbfeec07d0be1e92c3019919
Author: Florian Weimer <>
Date:   Tue Sep 6 07:38:10 2022 +0200

    scripts/ Generate program run-time dependencies
    The main program needs to depend on all shared objects, even objects
    that have link-time dependencies among shared objects.  Filtering
    out shared objects that already have an link-time dependencies is not
    necessary here; make will do this automatically.
    Reviewed-by: Adhemerval Zanella  <>
    (cherry picked from commit 183d99737298bb3200f0610fdcd1c7549c8ed560)

 scripts/ | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)

diff --git a/scripts/ b/scripts/
index 2dd6bfda18..b87cf2f809 100644
--- a/scripts/
+++ b/scripts/
@@ -707,13 +707,12 @@ def process_testcase(t):
                 "\t$(compile.c) $(OUTPUT_OPTION)\n")
         makefile.write (rule)
-        not_depended_objs = find_objs_not_depended_on(test_descr)
-        if not_depended_objs:
-            depstr = ""
-            for dep in not_depended_objs:
-                depstr += (" $(objpfx)" + test_subdir + "/"
-                           + test_name + "-" + dep + ".so")
-            makefile.write("$(objpfx)%s.out:%s\n" % (base_test_name, depstr))
+        # Ensure that all shared objects are built before running the
+        # test, whether there link-time dependencies or not.
+        depobjs = ["$(objpfx){}/{}-{}.so".format(test_subdir, test_name, dep)
+                   for dep in test_descr.objs]
+        makefile.write("$(objpfx){}.out: {}\n".format(
+            base_test_name, " ".join(depobjs)))
         # Add main executable to test-srcs
         makefile.write("test-srcs += %s/%s\n" % (test_subdir, test_name))

                 reply	other threads:[~2022-09-20  9:43 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).