[committed] hppa64: Search for milli.a archive

John David Anglin dave.anglin@bell.net
Sat Apr 4 18:11:22 GMT 2026


Tested on hppa64-hp-hpux11.11 and a x86_64-pc-linux-gnu cross.
Committed to trunk.

Dave
---

hppa64: Search for milli.a archive

Instead of hard coding the path to milli.a, add the input file
as a lang_input_file_is_search_file_enum.  This allows adding
a dummy archive in the testsuite.

2026-04-04  John David Anglin  <danglin@gcc.gnu.org>

ld/ChangeLog:

	* emultempl/hppa64elf.em (hppa64elf_after_parse): Search
	for milli.a.  Add "/lib/pa20_64" and "/usr/lib/pa20_64"
	library search paths.

diff --git a/ld/emultempl/hppa64elf.em b/ld/emultempl/hppa64elf.em
index 1aa00944604..c10eb5f4f9a 100644
--- a/ld/emultempl/hppa64elf.em
+++ b/ld/emultempl/hppa64elf.em
@@ -39,10 +39,14 @@ hppa64elf_after_parse (void)
     lang_add_unique (".text");
 
   /* We always need to link against milli.a on HP-UX.  */
-  lang_add_input_file ("/lib/pa20_64/milli.a",
-		       lang_input_file_is_file_enum,
+  lang_add_input_file ("milli.a",
+		       lang_input_file_is_search_file_enum,
 		       NULL);
 
+  /* Default 64-bit search paths on HP-UX.  */
+  ldfile_add_library_path ("/lib/pa20_64", false);
+  ldfile_add_library_path ("/usr/lib/pa20_64", false);
+
   /* HP-UX shared libraries have some unresolved symbols.  We need to
      ignore unresolved symbols in shared libraries.  */
   link_info.unresolved_syms_in_shared_libs = RM_IGNORE;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20260404/f8e07aa8/attachment.sig>


More information about the Binutils mailing list