source: clfs-embedded/BOOK/beyond/common/zlib.xml@ 0b3adee

Last change on this file since 0b3adee was faf50d8, checked in by Andrew Bradford <andrew@…>, 7 years ago

beyond: zlib: Install into both cross-tools and targetfs

So that we have headers and libs all provided in the cross tools to
enable compiling things that use zlib but also so we have the runtime
shared object in the targetfs.

  • Property mode set to 100644
File size: 2.6 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-beyond-zlib" role="wrap">
9 <?dbhtml filename="zlib.html"?>
10
11 <title>Zlib-&zlib-version;</title>
12
13 <indexterm zone="ch-beyond-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="c">Prepare Zlib for compilation and set to optimize for size:</para>
29
30<screen os="d"><userinput>CFLAGS="-Os" ./configure --shared</userinput></screen>
31
32 <variablelist os="aa">
33 <title>The meaning of the configure options:</title>
34
35 <varlistentry os="aa1">
36 <term><parameter>--shared</parameter></term>
37 <listitem>
38 <para>Tells Zlib to build its shared library.</para>
39 </listitem>
40 </varlistentry>
41
42 </variablelist>
43
44 <para os="c">Compile the package:</para>
45
46<screen os="d"><userinput>make</userinput></screen>
47
48 <para os="e">Install the package into the cross-tools:</para>
49
50<screen os="f"><userinput>make prefix=${CLFS}/cross-tools/${CLFS_TARGET} install</userinput></screen>
51
52 <para os="g">Copy only the shared library into the target file system and
53 ensure that its symlink is present so the runtime loader can find it:</para>
54
55 <screen os="h"><userinput>cp -v ${CLFS}/cross-tools/${CLFS_TARGET}/lib/libz.so.&zlib-version; ${CLFS}/targetfs/lib/
56ln -sv libz.so.&zlib-version; ${CLFS}/targetfs/lib/libz.so.1</userinput></screen>
57
58 </sect2>
59
60 <sect2 id="contents-zlib" role="content">
61 <title>Contents of Zlib</title>
62
63 <segmentedlist>
64 <segtitle>Installed libraries</segtitle>
65
66 <seglistitem>
67 <seg>libz.[a,so]</seg>
68 </seglistitem>
69 </segmentedlist>
70
71 <variablelist>
72 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
73 <?dbfo list-presentation="list"?>
74 <?dbhtml list-presentation="table"?>
75
76 <varlistentry id="libz">
77 <term><filename class="libraryfile">libz</filename></term>
78 <listitem>
79 <para>Contains compression and decompression
80 functions used by some programs</para>
81 <indexterm zone="ch-beyond-zlib libz">
82 <primary sortas="c-libz">libz</primary>
83 </indexterm>
84 </listitem>
85 </varlistentry>
86
87 </variablelist>
88
89 </sect2>
90
91</sect1>
Note: See TracBrowser for help on using the repository browser.