]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Check whether gnatmake can link with -shared
authorTom Tromey <tromey@adacore.com>
Wed, 12 Feb 2025 17:57:13 +0000 (10:57 -0700)
committerTom Tromey <tromey@adacore.com>
Tue, 4 Mar 2025 14:42:54 +0000 (07:42 -0700)
Currently, gnat-llvm does not ship a shared libgnat.  This patch
changes the relevant test to check whether linking with -shared
actually works.

gdb/testsuite/gdb.ada/win_fu_syms.exp
gdb/testsuite/lib/ada.exp

index 527a449664983444436a6f6633d98e871b95a6ea..77c636b2eb21fe97633678b3d554f002a8d0a2f2 100644 (file)
@@ -16,6 +16,7 @@
 load_lib "ada.exp"
 
 require allow_ada_tests
+require ada_shared_link
 
 standard_ada_testfile foo
 
index 00ea570fdd78c05fa072621ff90ea3d79f22b601..0a1231b1d592c0f09688897ab6002b6e2a5b2948 100644 (file)
@@ -289,3 +289,12 @@ gdb_caching_proc ada_minimal_encodings {} {
 gdb_caching_proc ada_og {} {
     return [ada_simple_compile gnat_og additional_flags=-Og]
 }
+
+# Return 1 if GNAT can link with -shared.
+gdb_caching_proc ada_shared_link {} {
+    return [ada_simple_compile ada_shared_link {
+       additional_flags=-bargs
+       additional_flags=-shared
+       additional_flags=-margs
+    }]
+}