zlib.xml 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119
  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. <sect1 id="ch-system-zlib" role="wrap">
  8. <?dbhtml filename="zlib.html"?>
  9. <sect1info condition="script">
  10. <productname>zlib</productname>
  11. <productnumber>&zlib-version;</productnumber>
  12. <address>&zlib-url;</address>
  13. </sect1info>
  14. <title>Zlib-&zlib-version;</title>
  15. <indexterm zone="ch-system-zlib">
  16. <primary sortas="a-Zlib">Zlib</primary>
  17. </indexterm>
  18. <sect2 role="package">
  19. <title/>
  20. <para>The Zlib package contains compression and decompression routines used by
  21. some programs.</para>
  22. <segmentedlist>
  23. <segtitle>&buildtime;</segtitle>
  24. <segtitle>&diskspace;</segtitle>
  25. <seglistitem>
  26. <seg>&zlib-ch6-sbu;</seg>
  27. <seg>&zlib-ch6-du;</seg>
  28. </seglistitem>
  29. </segmentedlist>
  30. </sect2>
  31. <sect2 role="installation">
  32. <title>Installation of Zlib</title>
  33. <para>First, fix a typo in the package header file:</para>
  34. <screen><userinput remap="pre">sed -i 's/ifdef _LARGEFILE64_SOURCE/ifndef _LARGEFILE64_SOURCE/' zlib.h</userinput></screen>
  35. <para>Prepare Zlib for compilation:</para>
  36. <screen><userinput remap="configure">CFLAGS='-mstackrealign -fPIC -O3' ./configure --prefix=/usr</userinput></screen>
  37. <variablelist>
  38. <title>The meaning of the new configure environment variable:</title>
  39. <varlistentry>
  40. <term><envar>CFLAGS='-mstackrealign -fPIC -O3'</envar></term>
  41. <listitem>
  42. <para>Setting CFLAGS overrides the default optimization in the
  43. package to prevent some run time errors.</para>
  44. </listitem>
  45. </varlistentry>
  46. </variablelist>
  47. <para>Compile the package:</para>
  48. <screen><userinput remap="make">make</userinput></screen>
  49. <para>To test the results, issue:</para>
  50. <screen><userinput remap="test">make check</userinput></screen>
  51. <para>Install the package:</para>
  52. <screen><userinput remap="install">make install</userinput></screen>
  53. <para>The shared library needs to be moved to
  54. <filename class="directory">/lib</filename>, and as a result the
  55. <filename class="extension">.so</filename> file in
  56. <filename class="directory">/usr/lib</filename> will need to be recreated:</para>
  57. <screen><userinput remap="install">mv -v /usr/lib/libz.so.* /lib
  58. ln -sfv ../../lib/libz.so.&zlib-version; /usr/lib/libz.so</userinput></screen>
  59. </sect2>
  60. <sect2 id="contents-zlib" role="content">
  61. <title>Contents of Zlib</title>
  62. <segmentedlist>
  63. <segtitle>Installed libraries</segtitle>
  64. <seglistitem>
  65. <seg>libz.{a,so}</seg>
  66. </seglistitem>
  67. </segmentedlist>
  68. <variablelist>
  69. <bridgehead renderas="sect3">Short Descriptions</bridgehead>
  70. <?dbfo list-presentation="list"?>
  71. <?dbhtml list-presentation="table"?>
  72. <varlistentry id="libz">
  73. <term><filename class="libraryfile">libz</filename></term>
  74. <listitem>
  75. <para>Contains compression and decompression functions used by
  76. some programs</para>
  77. <indexterm zone="ch-system-zlib libz">
  78. <primary sortas="c-libz">libz</primary>
  79. </indexterm>
  80. </listitem>
  81. </varlistentry>
  82. </variablelist>
  83. </sect2>
  84. </sect1>