source: chapter08/readline.xml@ c04d98d

12.2-rc1 multilib trunk xry111/arm64 xry111/clfs-ng xry111/loongarch
Last change on this file since c04d98d was 2ef9bea, checked in by Xi Ruoyao <xry111@…>, 3 months ago

readline: Get rid of rpath

  • Property mode set to 100644
File size: 5.1 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
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-readline" role="wrap">
9 <?dbhtml filename="readline.html"?>
10
11 <sect1info condition="script">
12 <productname>readline</productname>
13 <productnumber>&readline-version;</productnumber>
14 <address>&readline-url;</address>
15 </sect1info>
16
17 <title>Readline-&readline-version;</title>
18
19 <indexterm zone="ch-system-readline">
20 <primary sortas="a-Readline">Readline</primary>
21 </indexterm>
22
23 <sect2 role="package">
24 <title/>
25
26 <para>The Readline package is a set of libraries that offer command-line
27 editing and history capabilities.</para>
28
29 <segmentedlist>
30 <segtitle>&buildtime;</segtitle>
31 <segtitle>&diskspace;</segtitle>
32
33 <seglistitem>
34 <seg>&readline-fin-sbu;</seg>
35 <seg>&readline-fin-du;</seg>
36 </seglistitem>
37 </segmentedlist>
38
39 </sect2>
40
41 <sect2 role="installation">
42 <title>Installation of Readline</title>
43
44 <para>Reinstalling Readline will cause the old libraries to be moved to
45 &lt;libraryname&gt;.old. While this is normally not a problem, in some cases
46 it can trigger a linking bug in <command>ldconfig</command>. This can be
47 avoided by issuing the following two seds:</para>
48
49<screen><userinput remap="pre">sed -i '/MV.*old/d' Makefile.in
50sed -i '/{OLDSUFF}/c:' support/shlib-install</userinput></screen>
51
52 <para>Prevent hard coding library search paths (rpath) into
53 the shared libraries. This package does not need rpath for an
54 installation into the standard location, and rpath may sometimes cause
55 unwanted effects or even security issues:</para>
56
57<screen><userinput>sed -i 's/-Wl,-rpath,[^ ]*//' support/shobj-conf</userinput></screen>
58
59 <para>Now fix a problem identified upstream:</para>
60
61<screen><userinput remap="pre">patch -Np1 -i ../&readline-fixes-patch;</userinput></screen>
62
63 <para>Prepare Readline for compilation:</para>
64
65<screen><userinput remap="configure">./configure --prefix=/usr \
66 --disable-static \
67 --with-curses \
68 --docdir=/usr/share/doc/readline-&readline-version;</userinput></screen>
69
70 <variablelist>
71 <title>The meaning of the new configure option:</title>
72
73 <varlistentry>
74 <term><parameter>--with-curses</parameter></term>
75 <listitem>
76 <para>This option tells Readline that it can find the termcap
77 library functions in the curses library, not a separate
78 termcap library. This will generate the correct
79 <filename>readline.pc</filename> file.</para>
80 </listitem>
81 </varlistentry>
82
83 </variablelist>
84
85 <para>Compile the package:</para>
86
87<screen><userinput remap="make">make SHLIB_LIBS="-lncursesw"</userinput></screen>
88
89 <variablelist>
90 <title>The meaning of the make option:</title>
91
92 <varlistentry>
93 <term><parameter>SHLIB_LIBS="-lncursesw"</parameter></term>
94 <listitem>
95 <para>This option forces Readline to link against the
96 <filename class="libraryfile">libncursesw</filename> library.</para>
97 </listitem>
98 </varlistentry>
99
100 </variablelist>
101
102 <para>This package does not come with a test suite.</para>
103
104 <para>Install the package:</para>
105
106<screen><userinput remap="install">make SHLIB_LIBS="-lncursesw" install</userinput></screen>
107
108 <para>If desired, install the documentation:</para>
109
110<screen><userinput remap="install">install -v -m644 doc/*.{ps,pdf,html,dvi} /usr/share/doc/readline-&readline-version;</userinput></screen>
111
112 </sect2>
113
114 <sect2 id="contents-readline" role="content">
115 <title>Contents of Readline</title>
116
117 <segmentedlist>
118 <segtitle>Installed libraries</segtitle>
119 <segtitle>Installed directories</segtitle>
120
121 <seglistitem>
122 <seg>libhistory.so and libreadline.so</seg>
123 <seg>/usr/include/readline and
124 /usr/share/doc/readline-&readline-version;</seg>
125 </seglistitem>
126 </segmentedlist>
127
128 <variablelist>
129 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
130 <?dbfo list-presentation="list"?>
131 <?dbhtml list-presentation="table"?>
132
133 <varlistentry id="libhistory">
134 <term><filename class="libraryfile">libhistory</filename></term>
135 <listitem>
136 <para>Provides a consistent user interface for recalling lines
137 of history</para>
138 <indexterm zone="ch-system-readline libhistory">
139 <primary sortas="c-libhistory">libhistory</primary>
140 </indexterm>
141 </listitem>
142 </varlistentry>
143
144 <varlistentry id="libreadline">
145 <term><filename class="libraryfile">libreadline</filename></term>
146 <listitem>
147 <para>Provides a set of commands for manipulating text entered in an
148 interactive session of a program</para>
149 <indexterm zone="ch-system-readline libreadline">
150 <primary sortas="c-libreadline">libreadline</primary>
151 </indexterm>
152 </listitem>
153 </varlistentry>
154
155 </variablelist>
156
157 </sect2>
158
159</sect1>
Note: See TracBrowser for help on using the repository browser.