| 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
 | 
|---|
| 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
 | 
|---|
| 3 |   "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
 | 
|---|
| 4 |   <!ENTITY % general-entities SYSTEM "../../general.ent">
 | 
|---|
| 5 |   %general-entities;
 | 
|---|
| 6 | ]>
 | 
|---|
| 7 | 
 | 
|---|
| 8 | <sect1 id="ch-system-adjusting">
 | 
|---|
| 9 |   <?dbhtml filename="adjusting.html"?>
 | 
|---|
| 10 | 
 | 
|---|
| 11 |   <title>Adjusting the Toolchain</title>
 | 
|---|
| 12 | 
 | 
|---|
| 13 |   <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 | 
|---|
| 14 |   href="../mips/adjusting.xml"
 | 
|---|
| 15 |   xpointer="xpointer(//*[@os='a'])"/>
 | 
|---|
| 16 | 
 | 
|---|
| 17 |   <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 | 
|---|
| 18 |   href="../mips/adjusting.xml"
 | 
|---|
| 19 |   xpointer="xpointer(//*[@os='b'])"/>
 | 
|---|
| 20 | 
 | 
|---|
| 21 | <screen os="c"><userinput>gcc -dumpspecs | \
 | 
|---|
| 22 | perl -pi -e 's@/tools/lib/ld@/lib/ld@g;' \
 | 
|---|
| 23 |      -e 's@/tools/lib32/ld@/lib32/ld@g;' \
 | 
|---|
| 24 |      -e 's@/tools/lib64/ld@/lib64/ld@g;' \
 | 
|---|
| 25 |      -e 's@\*startfile_prefix_spec:\n@$_/usr/lib/ @g;' > \
 | 
|---|
| 26 |      `dirname $(gcc --print-libgcc-file-name)`/specs</userinput></screen>
 | 
|---|
| 27 | 
 | 
|---|
| 28 |   <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 | 
|---|
| 29 |   href="../mips/adjusting.xml"
 | 
|---|
| 30 |   xpointer="xpointer(//*[@os='d'])"/>
 | 
|---|
| 31 | 
 | 
|---|
| 32 |   <para>Note that <filename class="directory">/lib</filename>,
 | 
|---|
| 33 |   <filename class="directory">/lib32</filename>, or
 | 
|---|
| 34 |   <filename class="directory">/lib64</filename> is now the prefix
 | 
|---|
| 35 |   of our dynamic linker.</para>
 | 
|---|
| 36 | 
 | 
|---|
| 37 |   <caution>
 | 
|---|
| 38 | 
 | 
|---|
| 39 |     <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 | 
|---|
| 40 |     href="../mips/adjusting.xml"
 | 
|---|
| 41 |     xpointer="xpointer(//*[@os='f'])"/>
 | 
|---|
| 42 | 
 | 
|---|
| 43 |     <para>For 32 bit ABI:</para>
 | 
|---|
| 44 | 
 | 
|---|
| 45 | <screen><userinput>echo 'main(){}' > dummy.c
 | 
|---|
| 46 | cc ${BUILD32} dummy.c
 | 
|---|
| 47 | readelf -l a.out | grep ': /lib'</userinput></screen>
 | 
|---|
| 48 | 
 | 
|---|
| 49 |     <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 | 
|---|
| 50 |     href="../mips/adjusting.xml"
 | 
|---|
| 51 |     xpointer="xpointer(//*[@os='h'])"/>
 | 
|---|
| 52 | 
 | 
|---|
| 53 |     <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 | 
|---|
| 54 |     href="../mips/adjusting.xml"
 | 
|---|
| 55 |     xpointer="xpointer(//*[@os='i'])"/>
 | 
|---|
| 56 | 
 | 
|---|
| 57 |     <para>For N32 ABI:</para>
 | 
|---|
| 58 | 
 | 
|---|
| 59 | <screen><userinput>echo 'main(){}' > dummy.c
 | 
|---|
| 60 | cc ${BUILDN32} dummy.c
 | 
|---|
| 61 | readelf -l a.out | grep ': /lib'</userinput></screen>
 | 
|---|
| 62 | 
 | 
|---|
| 63 |     <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 | 
|---|
| 64 |     href="../mips/adjusting.xml"
 | 
|---|
| 65 |     xpointer="xpointer(//*[@os='h'])"/>
 | 
|---|
| 66 | 
 | 
|---|
| 67 | <screen><computeroutput>[Requesting program interpreter: /lib32/ld.so.1]</computeroutput></screen>
 | 
|---|
| 68 | 
 | 
|---|
| 69 |     <para>For 64 bit ABI:</para>
 | 
|---|
| 70 | 
 | 
|---|
| 71 | <screen><userinput>echo 'main(){}' > dummy.c
 | 
|---|
| 72 | cc ${BUILD64} dummy.c
 | 
|---|
| 73 | readelf -l a.out | grep ': /lib'</userinput></screen>
 | 
|---|
| 74 | 
 | 
|---|
| 75 |     <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 | 
|---|
| 76 |     href="../mips/adjusting.xml"
 | 
|---|
| 77 |     xpointer="xpointer(//*[@os='h'])"/>
 | 
|---|
| 78 | 
 | 
|---|
| 79 | <screen><computeroutput>[Requesting program interpreter: /lib64/ld.so.1]</computeroutput></screen>
 | 
|---|
| 80 | 
 | 
|---|
| 81 |     <para>Note that <filename class="directory">/lib</filename>,
 | 
|---|
| 82 |     <filename class="directory">/lib32</filename> or
 | 
|---|
| 83 |     <filename class="directory">/lib64</filename> is now the prefix
 | 
|---|
| 84 |     of our dynamic linker.</para>
 | 
|---|
| 85 | 
 | 
|---|
| 86 |     <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 | 
|---|
| 87 |     href="../mips/adjusting.xml"
 | 
|---|
| 88 |     xpointer="xpointer(//*[@os='k'])"/>
 | 
|---|
| 89 | 
 | 
|---|
| 90 |     <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 | 
|---|
| 91 |     href="../mips/adjusting.xml"
 | 
|---|
| 92 |     xpointer="xpointer(//*[@os='l'])"/>
 | 
|---|
| 93 | 
 | 
|---|
| 94 |     <xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
 | 
|---|
| 95 |     href="../mips/adjusting.xml"
 | 
|---|
| 96 |     xpointer="xpointer(//*[@os='m'])"/>
 | 
|---|
| 97 | 
 | 
|---|
| 98 |   </caution>
 | 
|---|
| 99 | 
 | 
|---|
| 100 | </sect1>
 | 
|---|