source: clfs-sysroot/BOOK/final-system/common/zlib.xml@ fa397e4

Last change on this file since fa397e4 was 3349a3a, checked in by Jim Gifford <clfs@…>, 18 years ago

r3669@server (orig r1667): jciccone | 2006-05-27 18:13:38 -0700
Various text and command fixes

  • Property mode set to 100644
File size: 2.9 KB
Line 
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-zlib" role="wrap">
9 <?dbhtml filename="zlib.html"?>
10
11 <title>Zlib-&zlib-version;</title>
12
13 <indexterm zone="ch-system-zlib">
14 <primary sortas="a-Zlib">Zlib</primary>
15 </indexterm>
16
17 <sect2 role="package">
18 <title/>
19
20 <para>The Zlib package contains compression and decompression routines
21 used by some programs.</para>
22
23 </sect2>
24
25 <sect2 role="installation">
26 <title>Installation of Zlib</title>
27
28 <para os="p1">This patch will add -fPIC to our build and allow us to build
29 a static and shared library at the same time:</para>
30
31<screen os="p2"><userinput>patch -Np1 -i ../&zlib-fpic-patch;</userinput></screen>
32
33 <para os="s1">The following sed tells the Makefile to pass r to AR:</para>
34
35<screen os="s2"><userinput>cp Makefile.in{,.orig}
36sed 's/$(AR) $@/$(AR) r $@/' Makefile.in.orig &gt; Makefile.in</userinput></screen>
37
38 <para os="a">Prepare Zlib for compilation:</para>
39
40<screen os="b"><userinput>./configure --prefix=/usr --shared</userinput></screen>
41
42 <para os="c">Compile the package:</para>
43
44<screen os="d"><userinput>make</userinput></screen>
45
46 <para os="e">Install the pacakge:</para>
47
48<screen os="f"><userinput>make prefix=${LFS}/usr install</userinput></screen>
49
50 <para os="g">The previous command installed a <filename
51 class="extension">.so</filename> file in <filename
52 class="directory">/usr/lib</filename>. We will move it into
53 <filename class="directory">/lib</filename> and then relink it
54 to <filename class="directory">/usr/lib</filename>:</para>
55
56<screen os="h"><userinput>mv -v ${LFS}/usr/lib/libz.so.* ${LFS}/lib
57ln -svf ../../lib/libz.so.1 ${LFS}/usr/lib/libz.so</userinput></screen>
58
59 <para os="i">Now we fix the permissions on the static library:</para>
60
61<screen os="j"><userinput>chmod -v 644 ${LFS}/usr/lib/libz.a</userinput></screen>
62
63 </sect2>
64
65 <sect2 id="contents-zlib" role="content">
66 <title>Contents of Zlib</title>
67
68 <segmentedlist>
69 <segtitle>Installed libraries</segtitle>
70
71 <seglistitem>
72 <seg>libz.[a,so]</seg>
73 </seglistitem>
74 </segmentedlist>
75
76 <variablelist>
77 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
78 <?dbfo list-presentation="list"?>
79 <?dbhtml list-presentation="table"?>
80
81 <varlistentry id="libz">
82 <term><filename class="libraryfile">libz</filename></term>
83 <listitem>
84 <para>Contains compression and decompression
85 functions used by some programs</para>
86 <indexterm zone="ch-system-zlib libz">
87 <primary sortas="c-libz">libz</primary>
88 </indexterm>
89 </listitem>
90 </varlistentry>
91
92 </variablelist>
93
94 </sect2>
95
96</sect1>
Note: See TracBrowser for help on using the repository browser.