unofficial mirror of libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Siddhesh Poyarekar via Libc-alpha <libc-alpha@sourceware.org>
To: libc-alpha@sourceware.org
Subject: [PATCH] Make mcheck tests conditional on GLIBC_2.24 or earlier
Date: Fri,  9 Jul 2021 16:47:19 +0530	[thread overview]
Message-ID: <20210709111719.651791-1-siddhesh@sourceware.org> (raw)

Targets with base versions later than 2.24 won't have
__malloc_initialize_hook because of which the tests will essentially
be the same as the regular malloc tests.  Avoid running them instead
and save time.
---
 malloc/Makefile | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/malloc/Makefile b/malloc/Makefile
index 37a9a4efab..76c996bb4d 100644
--- a/malloc/Makefile
+++ b/malloc/Makefile
@@ -77,6 +77,8 @@ tests-exclude-malloc-check = tst-malloc-check tst-malloc-usable \
 # Run all tests with MALLOC_CHECK_=3
 tests-malloc-check = $(filter-out $(tests-exclude-malloc-check),$(tests))
 
+# -lmcheck needs __malloc_initialize_hook, which was deprecated in 2.24.
+ifeq ($(have-GLIBC_2.24)$(build-shared),yesyes)
 # Tests that don't play well with mcheck.  They are either bugs in mcheck or
 # the tests expect specific internal behavior that is changed due to linking to
 # libmcheck.a.
@@ -97,6 +99,7 @@ tests-exclude-mcheck = tst-mallocstate \
 	tst-realloc
 
 tests-mcheck = $(filter-out $(tests-exclude-mcheck), $(tests))
+endif
 
 routines = malloc morecore mcheck mtrace obstack reallocarray \
   scratch_buffer_dupfree \
-- 
2.31.1


                 reply	other threads:[~2021-07-09 11:18 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:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/libc/involved.html

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

  git send-email \
    --in-reply-to=20210709111719.651791-1-siddhesh@sourceware.org \
    --to=libc-alpha@sourceware.org \
    --cc=siddhesh@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* 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).