⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 0287-0288.html

📁 linux-unix130.linux.and.unix.ebooks130 linux and unix ebookslinuxLearning Linux - Collection of 12 E
💻 HTML
字号:
<HTML>



<HEAD>

<TITLE>Linux Complete Command Reference:User Commands:EarthWeb Inc.-</TITLE>

</HEAD>

<META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">
<SCRIPT>
<!--
function displayWindow(url, width, height) {
        var Win = window.open(url,"displayWindow",'width=' + width +
',height=' + height + ',resizable=1,scrollbars=yes');
}
//-->
</SCRIPT>
</HEAD>

 -->




<!-- ISBN=0672311046 //-->

<!-- TITLE=Linux Complete Command Reference//-->

<!-- AUTHOR=Red Hat//-->

<!-- PUBLISHER=Macmillan Computer Publishing//-->

<!-- IMPRINT=Sams//-->

<!-- CHAPTER=01 //-->

<!-- PAGES=0001-0736 //-->

<!-- UNASSIGNED1 //-->

<!-- UNASSIGNED2 //-->



<P><CENTER>

<a href="0285-0286.html">Previous</A> | <a href="../ewtoc.html">Table of Contents</A> | <a href="0289-0290.html">Next</A></CENTER></P>







<A NAME="PAGENUM-287"><P>Page 287</P></A>



<P><B>EXAMPLES</B></P>





<P>To setup lbxproxy, start the X server as usual, and then start the proxy. The

lbxproxy is a pseudo-server, so any clients that wish to use it need to adjust their

DISPLAY. By default, the proxy will listen on

&lt;hostname&gt;:1. This can be changed with the

:displaynumber argument.

</P>



<P>If the proxy is to be running on a host named

sharedhost, connecting to an LBX-capable X server on a desktop

machine named mydesktop, you could use the following command to start the proxy (which would be known as display

sharedhost:7):

</P>



<!-- CODE SNIP //-->

<PRE>mydesktop% rlogin sharedhost

sharedhost% lbxproxy -display mydesktop:0 :7 &amp;

sharedhost% xclient -display sharedhost:7

</PRE>

<!-- END CODE SNIP //-->





<P>If you are running LBX over a TERM connection between

mydesktop and sharedhost, try something like this:

</P>



<!-- CODE SNIP //-->

<PRE WIDTH="1">mydesktop% trsh

sharedhost% tredir -r 6008 6000

sharedhost% lbxproxy -display sharedhost:8 :7 &amp;

sharedhost% xclient -display sharedhost:7

</PRE>

<!-- END CODE SNIP //-->





<P><B>SEE ALSO</B></P>



<P>General information: X(1)

</P>



<!-- CODE SNIP //-->

<PRE>Server-specific man pages: Xserver(1), Xdec(1),

XmacII(1), Xsun(1), Xnest(1), Xvfb(1), XF86_Accel(1),

XF86_Mono(1), XF86_SVGA(1), XF86_VGA16(1), XFree86(1)

</PRE>

<!-- END CODE SNIP //-->



<P><B>AUTHORs</B></P>



<P>The LBX team includes Dave Lemke, Dale Tonogai, Keith Packard, Jim Fulton from NCD, and Chris Kanterjiev

from Xerox.

</P>



<P>X Version 11 Release 6

</P>



<H3><A NAME="ch01_ 140">

ld

</A></H3>





<P>ld&#151;The GNU linker

</P>



<P><B>SYNOPSIS</B></P>



<!-- CODE //-->

<PRE>ld [ _o.I output ] .I objfile . . . .br .RB [&quot;_A output ] objfile ...

[_A architecture ][_b\ input-format ][_Bstatic ][_c\ commandfile ]

[ _d|_dc|_dp ]

[ _defsym\ symbol = expression ][_e\ entry ][_F ][_F\ format ][_

format\ input-format ][_g ][_G size ][--help ][_i ][_l ar ][_

L searchdir ][_M][_Map mapfile ][_m emulation ][_n|_N][_

noinhibit-exec ][_oformat\ output-format ][_R\ filename ][_relax ]

[ _r|_Ur][_S ][_s ][_sort_common][_T\ commandfile ][_Ttext\

textorg ][_Tdata\ dataorg ][_Tbss\ bssorg ][_t ][_u\ sym ][_V ][_

v][--verbose ][--version ][_warn_common][_warn_once][_X ]

[ _x ]

</PRE>

<!-- END CODE //-->





<P><B>DESCRIPTION</B></P>





<P>ld combines a number of object and archive FILES, relocates their data, and ties up symbol references. Often the last step

in building a new compiled program to run is a call to

ld.

</P>





<P>ld accepts Linker Command Language FILES to provide explicit and total control over the linking process. This man page

does not describe the command language; see the ld entry in

info, or the manual Ld: The GNU Linker, for full details on

the command language and on other aspects of the GNU linker.

</P>



<A NAME="PAGENUM-288"><P>Page 288</P></A>





<P>This version of ld uses the general-purpose BFD libraries to operate on object FILES. This allows

ld to read, combine, and write object FILES in many different FORMATS, for example, COFF or

a.out. Different FORMATS may be linked together to produce any available kind of object file. You can use

objdump _i to get a list of FORMATS supported on various

architectures; see objdump(1).

</P>



<P>Aside from its flexibility, the GNU linker is more helpful than other linkers in providing diagnostic information.

Many linkers abandon execution immediately upon encountering an error; whenever possible,

ld continues executing, allowing you to identify other errors (or, in some cases, to get an output file in spite of the error).

</P>



<P>The GNU linker ld is meant to cover a broad range of situations, and to be as compatible as possible with other linkers. As

a result, you have many choices to control its behavior through the command line, and through ENVIRONMENT variables.

</P>



<P><B>OPTIONS</B></P>





<P>The plethora of command-line OPTIONS may seem intimidating, but in actual practice few of them are used in any

particular context. For instance, a frequent use of

ld is to link standard UNIX object FILES on a standard, supported UNIX system.

On such a system, this line links a file hello.o :

</P>



<!-- CODE SNIP //-->

<PRE WIDTH="1">$ ld _o output /lib/crt0.o hello.o _lc

</PRE>

<!-- END CODE SNIP //-->





<P>This tells ld to produce a file called output as the result of linking the file

/lib/crt0.o with hello.o and the library libc.a, which will come from the standard search directories.

</P>



<P>The command-line OPTIONS to ld may be specified in any order, and may be repeated at will. For the most part, repeating

an option with a different argument will either have no further effect or override prior occurrences (those further to the left

on the command line) of an option.

</P>



<P>The exceptions&#151;which may meaningfully be used more than once&#151;are

_A, _b (or its synonym _format), _defsym, _L, _l,

_R, and _u.

</P>





<P>The list of object FILES to be linked together, shown as

objfile, may follow, precede, or be mixed in with

command-line OPTIONS, except that an objfile argument may not be placed between an option flag and its argument.

</P>



<P>Usually the linker is invoked with at least one object file, but other forms of binary input FILES can also be specified with

_l,<BR>

_R, and the script command language. If no binary input FILES at all are specified, the linker does not produce any output,

and issues the message No input FILES.

</P>



<P>Option arguments must either follow the option letter without intervening whitespace or be given as separate

arguments immediately following the option that requires them.

</P>





<TABLE>



<TR><TD>

-Aarchitecture

</TD><TD>

In the current release of ld, this option is useful only for the Intel 960 family of

architectures. In that ld configuration, the architecture

argument is one of the two-letter names identifying members of the 960 family; the option specifies the desired output target

and warns of any incompatible instructions in the input FILES. It also modifies the linker's

search strategy for archive libraries to support the use of libraries specific to each

particular architecture, by including in the search loop names suffixed with the string identifying

the architecture.

</TD></TR><TR><TD>

</TD><TD>

For example, if your ld command line included

_ACA as well as _ltry, the linker would look (in its built-in search paths, and in any paths you specify with

_L) for a library with the names

</TD></TR><TR><TD>

</TD><TD>

try

libtry.a

tryca

libtryca.a

</TD></TR><TR><TD>

</TD><TD>

The first two possibilities would be considered in any event; the last two are due to the

use of _ACA.

</TD></TR><TR><TD>

</TD><TD>

Future releases of ld may support similar functionality for other architecture families.

</TD></TR></TABLE>







<P><CENTER>

<a href="0285-0286.html">Previous</A> | <a href="../ewtoc.html">Table of Contents</A> | <a href="0289-0290.html">Next</A></CENTER></P>







</td>
</tr>
</table>

<!-- begin footer information -->







</body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -