source: clfs-embedded/BOOK/cross-tools/x86/variables.xml@ f9f2236

Last change on this file since f9f2236 was f96a570, checked in by Andrew Bradford <andrew@…>, 11 years ago

x86/variables: Set arch to x86

i*86 isn't a valid arch in the kernel, x86 is.

  • Property mode set to 100644
File size: 3.1 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="ch-cross-tools-variables">
9 <?dbhtml filename="variables.html"?>
10
11 <title>Build Variables</title>
12
13 <bridgehead renderas="sect4">Setting Host and Target</bridgehead>
14
15 <para os="a">During the building of the cross-compile tools you will need to
16 set a few variables that will be dependent on your particular needs.
17 You will need to set the target triplet for the target architecture, and the
18 CPU type. If you do not know what triplet or CPU type you want,
19 you can use the table as a reference. Set
20 the command using the method listed below:</para>
21
22<screen os="b"><userinput>export CLFS_HOST=$(echo ${MACHTYPE} | sed "s/-[^-]*/-cross/")
23export CLFS_TARGET=<replaceable>[target triplet]</replaceable>
24export CLFS_CPU=<replaceable>[cpu type]</replaceable></userinput></screen>
25
26 <table os="i">
27 <title>Processor Type and Target Triplets</title>
28 <?dbfo table-width="7.5in" ?>
29
30 <tgroup cols="4">
31
32 <colspec colnum="1" colwidth="2.5in" colname="Processor"/>
33 <colspec colnum="2" colwidth="2in" colname="Triplet"/>
34 <colspec colnum="3" colwidth="0.5in" colname="CPU Type"/>
35 <colspec colnum="4" colwidth="2.5in" colname="Note"/>
36
37 <thead>
38 <row>
39 <entry>Processor</entry>
40 <entry>Target Triplet</entry>
41 <entry>CPU Type</entry>
42 <entry>Note</entry>
43 </row>
44 </thead>
45
46 <tbody>
47 <row>
48 <entry>486 Compatibles</entry>
49 <entry>i486-linux-musl</entry>
50 <entry>i486</entry>
51 <entry>Intel's i486</entry>
52 </row>
53 <row>
54 <entry>Pentium, K6, 586 Compatibles</entry>
55 <entry>i586-linux-musl</entry>
56 <entry>i586</entry>
57 <entry>Intel Pentium without MMX</entry>
58 </row>
59 <row>
60 <entry>Pentium II, Pentium III, Pentium 4</entry>
61 <entry>i686-linux-musl</entry>
62 <entry>i686</entry>
63 <entry>PentiumPro instruction set</entry>
64 </row>
65 <row>
66 <entry>Athlon</entry>
67 <entry>i686-linux-musl</entry>
68 <entry>athlon</entry>
69 <entry>AMD 32 bit Athlon</entry>
70 </row>
71 <row>
72 <entry>Opteron</entry>
73 <entry>x86_64-linux-musl</entry>
74 <entry>k8</entry>
75 <entry>AMD K8 processors with x86-64</entry>
76 </row>
77 </tbody>
78
79 </tgroup>
80
81 </table>
82
83 <para os="c">Now set the architecture of the CPU:</para>
84
85<screen os="d"><userinput>export CLFS_ARCH="x86"</userinput></screen>
86
87 <para os="g">Now we will add this to <filename>~/.bashrc</filename>, just in
88 case you have to exit and restart building later:</para>
89
90<screen os="h"><userinput>echo export CLFS_HOST=\""${CLFS_HOST}\"" &gt;&gt; ~/.bashrc
91echo export CLFS_TARGET=\""${CLFS_TARGET}\"" &gt;&gt; ~/.bashrc
92echo export CLFS_ARCH=\""${CLFS_ARCH}\"" &gt;&gt; ~/.bashrc
93echo export CLFS_CPU=\""${CLFS_CPU}\"" &gt;&gt; ~/.bashrc</userinput></screen>
94
95</sect1>
Note: See TracBrowser for help on using the repository browser.