source: BOOK/final-system/ppc64/yaboot.xml@ 0b15a95

clfs-2.1 clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since 0b15a95 was 2bdaa81, checked in by William Harrington <kb0iic@…>, 12 years ago

Add yaboot stubfuncs patch entries.

  • Property mode set to 100644
File size: 4.3 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-system-yaboot" role="wrap">
9 <?dbhtml filename="yaboot.html"?>
10
11 <title>Yaboot-&yaboot-version;</title>
12
13 <indexterm zone="ch-system-yaboot">
14 <primary sortas="a-Yaboot">Yaboot</primary>
15 </indexterm>
16
17 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
18 href="../ppc/yaboot.xml"
19 xpointer="xpointer(//*[@role='package'])"/>
20
21 <sect2 role="installation">
22 <title>Installation of Yaboot</title>
23
24 <para>Existing multilib distributions alter gcc to default to 32-bit
25 output. Because our gcc defaults to 64-bit, we need to pass appropriate
26 options to both the compiler and the linker. To prevent the build from
27 failing due to compiler warnings, the -Werror flag is removed. The
28 Makefile already overrides any CC and ignores LDFLAGS in favour of
29 its own variables, so we need to use the following seds for a
30 successful compile and install.</para>
31
32<screen><userinput>sed -i -e "s/\(-print-libgcc-file-name\)/${BUILD32} \1/" \
33 -e "s/-Werror//" \
34 -e "s/\(-Bstatic\)/-melf32ppclinux \1/" Makefile
35</userinput></screen>
36
37 <variablelist os="j">
38 <title>The meaning of the sed parameters:</title>
39
40 <varlistentry>
41 <term><parameter>"s/\(-print-libgcc-file-name\)/${BUILD32} \1/"</parameter></term>
42 <listitem>
43 <para>This picks a convenient place within the Makefile's lgcc
44 variable and inserts the flag to force <command>gcc</command> to
45 create 32-bit code when compiling yaboot.</para>
46 </listitem>
47 </varlistentry>
48 <varlistentry>
49 <term><parameter>"s/-Werror//"</parameter></term>
50 <listitem>
51 <para>This deletes the -Werror flag from the Makefile.</para>
52 </listitem>
53 </varlistentry>
54 <varlistentry>
55 <term><parameter>"s/\(-Bstatic\)/-melf32ppclinux \1/"</parameter></term>
56 <listitem>
57 <para>This picks the end of the LFLAGS which the Makefile passes to
58 the linker to create the second-stage linux loader, and inserts a
59 flag to force <command>ld</command> to use a suitable 32-bit
60 emulation picked from the output of <command>'ld -V'</command>.</para>
61 </listitem>
62 </varlistentry>
63
64 </variablelist>
65
66 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
67 href="../ppc/yaboot.xml"
68 xpointer="xpointer(//*[@os='p3'])"/>
69
70 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
71 href="../ppc/yaboot.xml"
72 xpointer="xpointer(//*[@os='p4'])"/>
73
74 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
75 href="../ppc/yaboot.xml"
76 xpointer="xpointer(//*[@os='a'])"/>
77
78 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
79 href="../ppc/yaboot.xml"
80 xpointer="xpointer(//*[@os='b'])"/>
81
82 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
83 href="../ppc/yaboot.xml"
84 xpointer="xpointer(//*[@os='c'])"/>
85
86<screen os="d"><userinput>CFLAGS="${BUILD32}" make PREFIX=/usr</userinput></screen>
87
88 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
89 href="../ppc/yaboot.xml"
90 xpointer="xpointer(//*[@os='e'])"/>
91
92 <important os="j0">
93 <para>The multilib install of yaboot can fail if you miss any of the
94 patches or seds, or omit the CFLAGS variable. <command>ld</command> will
95 issue warnings, but the install will appear to complete successfully.
96 That would result in an unbootable system, so you need to log the output
97 to check it.</para>
98 </important>
99
100<screen os='f'><userinput>make PREFIX=/usr install 2&gt;&amp;1 | tee instlog</userinput></screen>
101
102 <para os='g'>To ensure that the install was successful, run the following
103 command:</para>
104
105<screen os='h'><userinput>grep 'powerpc:common64' instlog</userinput></screen>
106
107 <para os='i'>If the command gave you <emphasis>any</emphasis> output
108 (... is incompatible with powerpc:common output) the build of yaboot is
109 broken and you will have to correct your error(s) and repeat it.</para>
110
111 </sect2>
112
113 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
114 href="../ppc/yaboot.xml"
115 xpointer="xpointer(id('contents-yaboot'))"/>
116
117</sect1>
Note: See TracBrowser for help on using the repository browser.