https://gcc.gnu.org/g:4f9e72dd364915dafc03202cc6ad9ddffaee93f3

commit r15-8670-g4f9e72dd364915dafc03202cc6ad9ddffaee93f3
Author: Iain Sandoe <i...@sandoe.co.uk>
Date:   Fri Mar 21 15:31:21 2025 +0000

    Darwin: We do not need libdl, it is provided in libSystem.
    
    Darwin provides this support as part of libSystem which is always
    linked with user-space DSOs (including exes).
    
    gcc/ChangeLog:
    
            * config/darwin.h (DL_LIBRARY): New.
    
    Signed-off-by: Iain Sandoe <i...@sandoe.co.uk>

Diff:
---
 gcc/config/darwin.h | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/gcc/config/darwin.h b/gcc/config/darwin.h
index 3d2ced5fca31..8c164fd4b75b 100644
--- a/gcc/config/darwin.h
+++ b/gcc/config/darwin.h
@@ -45,9 +45,12 @@ see the files COPYING3 and COPYING.RUNTIME respectively.  If 
not, see
 
 #define OBJECT_FORMAT_MACHO 1
 
-/* Suppress g++ attempt to link in the math library automatically. */
+/* Suppress language-specific specs attempt to link in libm automatically. */
 #define MATH_LIBRARY ""
 
+/* Likewise libdl.  */
+#define DL_LIBRARY ""
+
 /* We have atexit.  */
 
 #define HAVE_ATEXIT

Reply via email to