[PATCH] ld.so.8: update and expand

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



    ld.so.8: update and expand

    * Discuss possible observable effects of running on a multiarch-capable
      system (the linker may be in a different directory under a different
      name, for instance).

    * Add some basic background material for the novice reader.

    * Call out use of shell glob in filenames, particularly in the topic of
      the man page itself since this is a little unusual.

    * Connect discussion of --audit option and LD_AUDIT environment
      variable.

    * Explain where shared object dependencies are declared and connec to
      elf(5) (already mentioned in See Also section).

-- 
Regards,
Branden
diff --git a/man8/ld.so.8 b/man8/ld.so.8
index a4b405bb7..eb261a008 100644
--- a/man8/ld.so.8
+++ b/man8/ld.so.8
@@ -23,8 +23,22 @@ The programs
 .B ld.so
 and
 .BR ld-linux * .so *
+(where * indicates a shell wild card)
 find and load the shared objects (shared libraries) needed by a program,
 prepare the program to run, and then run it.
+The tool is called a loader because it loads object files into memory, and a
+linker because it resolves symbolic references like
+.I printf
+into machine addresses in the memory map of a running program.
+In this discussion, we refer to these programs simply as the \(lqdynamic
+linker\(rq even though both functions are essential.
+.PP
+The dynamic linker's name and location may vary to indicate the machine
+architecture and operating system it supports, and to permit linkers for
+different configurations to exist on the same system.
+For example, the dynamic linker for an x86-64-based GNU/Linux host with support
+for multiple architectures might be located at
+.IR /lib/x86_64\-linux\-gnu/ld\-linux\-x86\-64.so.2 .
 .PP
 Linux binaries require dynamic linking (linking at run time)
 unless the
@@ -52,6 +66,11 @@ support files and programs
 and
 .IR /etc/ld.so.conf .
 .PP
+Each dynamically-linked object lists its shared object dependencies in an
+ELF section called
+.IR .dynamic ;
+see
+.BR elf (5).
 When resolving shared object dependencies,
 the dynamic linker first inspects each dependency
 string to see if it contains a slash (this can occur if
@@ -193,6 +212,9 @@ This option is ignored when running in secure-execution mode (see below).
 Use objects named in
 .I list
 as auditors.
+See the discussion of the
+.BR LD_AUDIT
+environment variable, below.
 .SH ENVIRONMENT
 Various environment variables influence the operation of the dynamic linker.
 .\"
@@ -636,7 +658,14 @@ is always disabled in secure-execution mode.
 a.out dynamic linker/loader
 .TP
 .IR /lib/ld\-linux.so. { 1 , 2 }
-ELF dynamic linker/loader
+ELF dynamic linker/loader (traditional location)
+.TP
+.IR /lib/ gnu-target-triplet /ld\-linux\- machine .so.2
+ELF dynamic linker/loader (multi-architecture location), where
+.I gnu-target-triplet
+is a string like \(lqx86_64\-linux\-gnu\(rq and
+.I machine
+is \(lqx86\-64\(rq, for example.
 .TP
 .I /etc/ld.so.cache
 File containing a compiled list of directories in which to search for

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Kernel Documentation]     [Netdev]     [Linux Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux