You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by zw...@apache.org on 2022/11/01 10:20:00 UTC

[trafficserver] branch 9.2.x updated: Remove deprecated ld option (--add-needed) (#9141)

This is an automated email from the ASF dual-hosted git repository.

zwoop pushed a commit to branch 9.2.x
in repository https://gitbox.apache.org/repos/asf/trafficserver.git


The following commit(s) were added to refs/heads/9.2.x by this push:
     new c9d6e9948 Remove deprecated ld option (--add-needed) (#9141)
c9d6e9948 is described below

commit c9d6e9948390fb33e7dcb6cd2a28946c0564a061
Author: Masaori Koshiba <ma...@apache.org>
AuthorDate: Tue Oct 25 08:22:31 2022 +0900

    Remove deprecated ld option (--add-needed) (#9141)
    
    (cherry picked from commit 875c73e53e4d5eae6b6587e26943528314ea885b)
---
 build/jemalloc.m4 | 2 +-
 build/mimalloc.m4 | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/build/jemalloc.m4 b/build/jemalloc.m4
index 2af684859..7acf1ebec 100644
--- a/build/jemalloc.m4
+++ b/build/jemalloc.m4
@@ -58,7 +58,7 @@ if test "$has_jemalloc" != "no"; then
   if test "$jemalloc_base_dir" != "/usr"; then
     TS_ADDTO(CPPFLAGS, [-I${jemalloc_include}])
     TS_ADDTO(LDFLAGS, [-L${jemalloc_ldflags}])
-    TS_ADDTO(LDFLAGS, [-Wl,--add-needed -L${jemalloc_ldflags} -Wl,-rpath,${jemalloc_ldflags} -Wl,--no-as-needed])
+    TS_ADDTO(LDFLAGS, [-Wl,--as-needed -L${jemalloc_ldflags} -Wl,-rpath,${jemalloc_ldflags} -Wl,--no-as-needed])
     TS_ADDTO_RPATH(${jemalloc_ldflags})
   fi
   # On Darwin, jemalloc symbols are prefixed with je_. Search for that first, then fall back
diff --git a/build/mimalloc.m4 b/build/mimalloc.m4
index 5e6c1485c..78a9b7d0a 100644
--- a/build/mimalloc.m4
+++ b/build/mimalloc.m4
@@ -61,7 +61,7 @@ if test "$has_mimalloc" != "no"; then
   if test "$mimalloc_base_dir" != "/usr"; then
     TS_ADDTO(CPPFLAGS, [-I${mimalloc_include}])
     TS_ADDTO(LDFLAGS, [-L${mimalloc_ldflags}])
-    TS_ADDTO(LDFLAGS, [-Wl,--add-needed -L${mimalloc_ldflags} -Wl,-rpath,${mimalloc_ldflags} -Wl,--no-as-needed])
+    TS_ADDTO(LDFLAGS, [-Wl,--as-needed -L${mimalloc_ldflags} -Wl,-rpath,${mimalloc_ldflags} -Wl,--no-as-needed])
     TS_ADDTO_RPATH(${mimalloc_ldflags})
   fi
   AC_SEARCH_LIBS([mi_malloc], [mimalloc], [mimalloc_has_libs=1])