[673b0d8] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[b06ca36] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[673b0d8] | 4 | <!ENTITY % general-entities SYSTEM "../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 | ]>
|
---|
[2fa922f] | 7 |
|
---|
[81fd230] | 8 | <sect1 id="ch-system-ncurses" role="wrap">
|
---|
[2fa922f] | 9 | <?dbhtml filename="ncurses.html"?>
|
---|
| 10 |
|
---|
[e747759] | 11 | <sect1info condition="script">
|
---|
| 12 | <productname>ncurses</productname>
|
---|
| 13 | <productnumber>&ncurses-version;</productnumber>
|
---|
| 14 | <address>&ncurses-url;</address>
|
---|
| 15 | </sect1info>
|
---|
| 16 |
|
---|
[2fa922f] | 17 | <title>Ncurses-&ncurses-version;</title>
|
---|
| 18 |
|
---|
| 19 | <indexterm zone="ch-system-ncurses">
|
---|
| 20 | <primary sortas="a-Ncurses">Ncurses</primary>
|
---|
| 21 | </indexterm>
|
---|
| 22 |
|
---|
| 23 | <sect2 role="package">
|
---|
| 24 | <title/>
|
---|
[6370fa6] | 25 |
|
---|
[2fa922f] | 26 | <para>The Ncurses package contains libraries for terminal-independent
|
---|
| 27 | handling of character screens.</para>
|
---|
[673b0d8] | 28 |
|
---|
[2fa922f] | 29 | <segmentedlist>
|
---|
| 30 | <segtitle>&buildtime;</segtitle>
|
---|
| 31 | <segtitle>&diskspace;</segtitle>
|
---|
[5888299] | 32 |
|
---|
[2fa922f] | 33 | <seglistitem>
|
---|
[e4a5635] | 34 | <seg>&ncurses-ch6-sbu;</seg>
|
---|
| 35 | <seg>&ncurses-ch6-du;</seg>
|
---|
[2fa922f] | 36 | </seglistitem>
|
---|
| 37 | </segmentedlist>
|
---|
[673b0d8] | 38 |
|
---|
[2fa922f] | 39 | </sect2>
|
---|
| 40 |
|
---|
| 41 | <sect2 role="installation">
|
---|
| 42 | <title>Installation of Ncurses</title>
|
---|
[004616a] | 43 |
|
---|
| 44 | <!-- FIXME: Uncomment if using a dated ncurses release instead of a numbered
|
---|
| 45 | one.
|
---|
[2fa922f] | 46 |
|
---|
| 47 | <para>Since the release of Ncurses-&ncurses-version;, some bugs have been fixed
|
---|
| 48 | and features added. The most important news are .......
|
---|
| 49 | To get these fixes and features, apply the rollup patch:</para>
|
---|
[fa21b3d] | 50 |
|
---|
| 51 | <screen><userinput>bzcat ../&ncurses-rollup-patch; | patch -Np1</userinput></screen>
|
---|
[2fa922f] | 52 | -->
|
---|
[fa21b3d] | 53 |
|
---|
[2fa922f] | 54 | <para>Prepare Ncurses for compilation:</para>
|
---|
[73aedd1d] | 55 |
|
---|
[f5976ac] | 56 | <screen><userinput remap="configure">./configure --prefix=/usr \
|
---|
| 57 | --mandir=/usr/share/man \
|
---|
| 58 | --with-shared \
|
---|
| 59 | --without-debug \
|
---|
| 60 | --enable-widec</userinput></screen>
|
---|
[fa21b3d] | 61 |
|
---|
[2fa922f] | 62 | <variablelist>
|
---|
| 63 | <title>The meaning of the configure option:</title>
|
---|
| 64 |
|
---|
| 65 | <varlistentry>
|
---|
| 66 | <term><parameter>--enable-widec</parameter></term>
|
---|
| 67 | <listitem>
|
---|
| 68 | <para>This switch causes wide-character libraries (e.g., <filename
|
---|
| 69 | class="libraryfile">libncursesw.so.&ncurses-version;</filename>)
|
---|
| 70 | to be built instead of normal ones (e.g., <filename
|
---|
| 71 | class="libraryfile">libncurses.so.&ncurses-version;</filename>).
|
---|
| 72 | These wide-character libraries are usable in both multibyte and
|
---|
| 73 | traditional 8-bit locales, while normal libraries work properly
|
---|
| 74 | only in 8-bit locales. Wide-character and normal libraries are
|
---|
| 75 | source-compatible, but not binary-compatible.</para>
|
---|
| 76 | </listitem>
|
---|
| 77 | </varlistentry>
|
---|
| 78 |
|
---|
| 79 | <!--
|
---|
| 80 | <varlistentry>
|
---|
| 81 | <term><parameter>- -without-cxx-binding</parameter></term>
|
---|
| 82 | <listitem>
|
---|
| 83 | <para>This optional switch causes the
|
---|
| 84 | <filename class="libraryfile">libncurses++w.a</filename> library
|
---|
| 85 | not to be built. Nothing in LFS and BLFS uses this library.</para>
|
---|
| 86 | </listitem>
|
---|
| 87 | </varlistentry>
|
---|
| 88 | -->
|
---|
| 89 |
|
---|
| 90 | </variablelist>
|
---|
| 91 |
|
---|
| 92 | <para>Compile the package:</para>
|
---|
[73aedd1d] | 93 |
|
---|
[0445a3d] | 94 | <screen><userinput remap="make">make</userinput></screen>
|
---|
[73aedd1d] | 95 |
|
---|
[49ae4c6] | 96 | <para>This package has a test suite, but it can only be run after the
|
---|
| 97 | package has been installed. The tests reside in the
|
---|
| 98 | <filename class="directory">test/</filename> directory. See the
|
---|
| 99 | <filename>README</filename> file in that directory for further details.
|
---|
| 100 | </para>
|
---|
[81fd230] | 101 |
|
---|
[2fa922f] | 102 | <para>Install the package:</para>
|
---|
[73aedd1d] | 103 |
|
---|
[0445a3d] | 104 | <screen><userinput remap="install">make install</userinput></screen>
|
---|
[73aedd1d] | 105 |
|
---|
[bc5f39a] | 106 | <para>Move the shared libraries to the
|
---|
| 107 | <filename class="directory">/lib</filename> directory, where they are
|
---|
| 108 | expected to reside:</para>
|
---|
[73aedd1d] | 109 |
|
---|
[0445a3d] | 110 | <screen><userinput remap="install">mv -v /usr/lib/libncursesw.so.5* /lib</userinput></screen>
|
---|
[fa21b3d] | 111 |
|
---|
[2fa922f] | 112 | <para>Because the libraries have been moved, one symlink points to
|
---|
| 113 | a non-existent file. Recreate it:</para>
|
---|
[fa21b3d] | 114 |
|
---|
[0445a3d] | 115 | <screen><userinput remap="install">ln -sfv ../../lib/libncursesw.so.5 /usr/lib/libncursesw.so</userinput></screen>
|
---|
[fa21b3d] | 116 |
|
---|
[2fa922f] | 117 | <para>Many applications still expect the linker to be able to find
|
---|
| 118 | non-wide-character Ncurses libraries. Trick such applications into linking with
|
---|
| 119 | wide-character libraries by means of symlinks and linker scripts:</para>
|
---|
[fa21b3d] | 120 |
|
---|
[f5976ac] | 121 | <screen><userinput remap="install">for lib in ncurses form panel menu ; do
|
---|
| 122 | rm -vf /usr/lib/lib${lib}.so
|
---|
| 123 | echo "INPUT(-l${lib}w)" >/usr/lib/lib${lib}.so
|
---|
| 124 | ln -sfv lib${lib}w.a /usr/lib/lib${lib}.a
|
---|
[ad83f72] | 125 | done
|
---|
[f5976ac] | 126 |
|
---|
[fa21b3d] | 127 | ln -sfv libncurses++w.a /usr/lib/libncurses++.a</userinput></screen>
|
---|
| 128 |
|
---|
[2fa922f] | 129 | <para>Finally, make sure that old applications that look for
|
---|
| 130 | <filename class="libraryfile">-lcurses</filename> at build time are still
|
---|
| 131 | buildable:</para>
|
---|
[fa21b3d] | 132 |
|
---|
[f5976ac] | 133 | <screen><userinput remap="install">rm -vf /usr/lib/libcursesw.so
|
---|
| 134 | echo "INPUT(-lncursesw)" > /usr/lib/libcursesw.so
|
---|
| 135 | ln -sfv libncurses.so /usr/lib/libcurses.so
|
---|
| 136 | ln -sfv libncursesw.a /usr/lib/libcursesw.a
|
---|
| 137 | ln -sfv libncurses.a /usr/lib/libcurses.a</userinput></screen>
|
---|
[fa21b3d] | 138 |
|
---|
[2e1fb0ca] | 139 | <para>If desired, install the Ncurses documentation:</para>
|
---|
| 140 |
|
---|
| 141 | <screen><userinput remap="install">mkdir -v /usr/share/doc/ncurses-&ncurses-version;
|
---|
| 142 | cp -v -R doc/* /usr/share/doc/ncurses-&ncurses-version;</userinput></screen>
|
---|
| 143 |
|
---|
[2fa922f] | 144 | <note>
|
---|
| 145 | <para>The instructions above don't create non-wide-character Ncurses
|
---|
| 146 | libraries since no package installed by compiling from sources would
|
---|
| 147 | link against them at runtime. If you must have such libraries because
|
---|
[a26951e] | 148 | of some binary-only application or to be compliant with LSB, build
|
---|
| 149 | the package again with the following commands:</para>
|
---|
[2fa922f] | 150 |
|
---|
[ad83f72] | 151 | <screen role="nodump"><userinput>make distclean
|
---|
[fa21b3d] | 152 | ./configure --prefix=/usr --with-shared --without-normal \
|
---|
[ad83f72] | 153 | --without-debug --without-cxx-binding
|
---|
| 154 | make sources libs
|
---|
[fa21b3d] | 155 | cp -av lib/lib*.so.5* /usr/lib</userinput></screen>
|
---|
[2fa922f] | 156 | </note>
|
---|
| 157 |
|
---|
| 158 | </sect2>
|
---|
| 159 |
|
---|
| 160 | <sect2 id="contents-ncurses" role="content">
|
---|
| 161 | <title>Contents of Ncurses</title>
|
---|
| 162 |
|
---|
| 163 | <segmentedlist>
|
---|
| 164 | <segtitle>Installed programs</segtitle>
|
---|
| 165 | <segtitle>Installed libraries</segtitle>
|
---|
[fe05b08] | 166 | <segtitle>Installed directories</segtitle>
|
---|
[2fa922f] | 167 |
|
---|
| 168 | <seglistitem>
|
---|
| 169 | <seg>captoinfo (link to tic), clear, infocmp, infotocap (link to tic),
|
---|
[3119ddc] | 170 | ncursesw5-config, reset (link to tset), tabs, tic, toe, tput, and tset</seg>
|
---|
[0090db5] | 171 | <seg>libcursesw.{a,so} (symlink and linker script to libncursesw.{a,so}),
|
---|
| 172 | libformw.{a,so}, libmenuw.{a,so}, libncurses++w.a, libncursesw.{a,so},
|
---|
| 173 | libpanelw.{a,so} and their non-wide-character counterparts without "w"
|
---|
[2fa922f] | 174 | in the library names.</seg>
|
---|
[ca101ad] | 175 | <seg>/usr/share/tabset, /usr/share/terminfo,
|
---|
| 176 | /usr/share/doc/ncurses-&ncurses-version;</seg>
|
---|
[2fa922f] | 177 | </seglistitem>
|
---|
| 178 | </segmentedlist>
|
---|
| 179 |
|
---|
| 180 | <variablelist>
|
---|
| 181 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 182 | <?dbfo list-presentation="list"?>
|
---|
| 183 | <?dbhtml list-presentation="table"?>
|
---|
| 184 |
|
---|
| 185 | <varlistentry id="captoinfo">
|
---|
| 186 | <term><command>captoinfo</command></term>
|
---|
| 187 | <listitem>
|
---|
| 188 | <para>Converts a termcap description into a terminfo description</para>
|
---|
| 189 | <indexterm zone="ch-system-ncurses captoinfo">
|
---|
| 190 | <primary sortas="b-captoinfo">captoinfo</primary>
|
---|
| 191 | </indexterm>
|
---|
| 192 | </listitem>
|
---|
| 193 | </varlistentry>
|
---|
| 194 |
|
---|
| 195 | <varlistentry id="clear">
|
---|
| 196 | <term><command>clear</command></term>
|
---|
| 197 | <listitem>
|
---|
| 198 | <para>Clears the screen, if possible</para>
|
---|
| 199 | <indexterm zone="ch-system-ncurses clear">
|
---|
| 200 | <primary sortas="b-clear">clear</primary>
|
---|
| 201 | </indexterm>
|
---|
| 202 | </listitem>
|
---|
| 203 | </varlistentry>
|
---|
| 204 |
|
---|
| 205 | <varlistentry id="infocmp">
|
---|
| 206 | <term><command>infocmp</command></term>
|
---|
| 207 | <listitem>
|
---|
| 208 | <para>Compares or prints out terminfo descriptions</para>
|
---|
| 209 | <indexterm zone="ch-system-ncurses infocmp">
|
---|
| 210 | <primary sortas="b-infocmp">infocmp</primary>
|
---|
| 211 | </indexterm>
|
---|
| 212 | </listitem>
|
---|
| 213 | </varlistentry>
|
---|
| 214 |
|
---|
| 215 | <varlistentry id="infotocap">
|
---|
| 216 | <term><command>infotocap</command></term>
|
---|
| 217 | <listitem>
|
---|
| 218 | <para>Converts a terminfo description into a termcap description</para>
|
---|
| 219 | <indexterm zone="ch-system-ncurses infotocap">
|
---|
| 220 | <primary sortas="b-infotocap">infotocap</primary>
|
---|
| 221 | </indexterm>
|
---|
| 222 | </listitem>
|
---|
| 223 | </varlistentry>
|
---|
| 224 |
|
---|
[90aae6b] | 225 | <varlistentry id="ncursesw5-config">
|
---|
| 226 | <term><command>ncursesw5-config</command></term>
|
---|
[9058aa1] | 227 | <listitem>
|
---|
| 228 | <para>Provides configuration information for ncurses</para>
|
---|
[90aae6b] | 229 | <indexterm zone="ch-system-ncurses ncursesw5-config">
|
---|
| 230 | <primary sortas="b-ncursesw5-config">ncursesw5-config</primary>
|
---|
[9058aa1] | 231 | </indexterm>
|
---|
| 232 | </listitem>
|
---|
| 233 | </varlistentry>
|
---|
| 234 |
|
---|
[2fa922f] | 235 | <varlistentry id="reset">
|
---|
| 236 | <term><command>reset</command></term>
|
---|
| 237 | <listitem>
|
---|
| 238 | <para>Reinitializes a terminal to its default values</para>
|
---|
| 239 | <indexterm zone="ch-system-ncurses reset">
|
---|
| 240 | <primary sortas="b-reset">reset</primary>
|
---|
| 241 | </indexterm>
|
---|
| 242 | </listitem>
|
---|
| 243 | </varlistentry>
|
---|
[3119ddc] | 244 |
|
---|
[90aae6b] | 245 | <varlistentry id="tabs">
|
---|
| 246 | <term><command>tabs</command></term>
|
---|
[2fa922f] | 247 | <listitem>
|
---|
[90aae6b] | 248 | <para>Clears and sets tab stops on a terminal</para>
|
---|
| 249 | <indexterm zone="ch-system-ncurses tabs">
|
---|
| 250 | <primary sortas="b-tabs">tabs</primary>
|
---|
[2fa922f] | 251 | </indexterm>
|
---|
| 252 | </listitem>
|
---|
| 253 | </varlistentry>
|
---|
[3119ddc] | 254 |
|
---|
[2fa922f] | 255 | <varlistentry id="tic">
|
---|
| 256 | <term><command>tic</command></term>
|
---|
| 257 | <listitem>
|
---|
| 258 | <para>The terminfo entry-description compiler that translates a
|
---|
| 259 | terminfo file from source format into the binary format needed for the
|
---|
| 260 | ncurses library routines. A terminfo file contains information on the
|
---|
| 261 | capabilities of a certain terminal</para>
|
---|
| 262 | <indexterm zone="ch-system-ncurses tic">
|
---|
| 263 | <primary sortas="b-tic">tic</primary>
|
---|
| 264 | </indexterm>
|
---|
| 265 | </listitem>
|
---|
| 266 | </varlistentry>
|
---|
| 267 |
|
---|
| 268 | <varlistentry id="toe">
|
---|
| 269 | <term><command>toe</command></term>
|
---|
| 270 | <listitem>
|
---|
| 271 | <para>Lists all available terminal types, giving the primary name and
|
---|
| 272 | description for each</para>
|
---|
| 273 | <indexterm zone="ch-system-ncurses toe">
|
---|
| 274 | <primary sortas="b-toe">toe</primary>
|
---|
| 275 | </indexterm>
|
---|
| 276 | </listitem>
|
---|
| 277 | </varlistentry>
|
---|
| 278 |
|
---|
| 279 | <varlistentry id="tput">
|
---|
| 280 | <term><command>tput</command></term>
|
---|
| 281 | <listitem>
|
---|
| 282 | <para>Makes the values of terminal-dependent capabilities available to
|
---|
| 283 | the shell; it can also be used to reset or initialize a terminal or
|
---|
| 284 | report its long name</para>
|
---|
| 285 | <indexterm zone="ch-system-ncurses tput">
|
---|
| 286 | <primary sortas="b-tput">tput</primary>
|
---|
| 287 | </indexterm>
|
---|
| 288 | </listitem>
|
---|
| 289 | </varlistentry>
|
---|
| 290 |
|
---|
| 291 | <varlistentry id="tset">
|
---|
| 292 | <term><command>tset</command></term>
|
---|
| 293 | <listitem>
|
---|
| 294 | <para>Can be used to initialize terminals</para>
|
---|
| 295 | <indexterm zone="ch-system-ncurses tset">
|
---|
| 296 | <primary sortas="b-tset">tset</primary>
|
---|
| 297 | </indexterm>
|
---|
| 298 | </listitem>
|
---|
| 299 | </varlistentry>
|
---|
| 300 |
|
---|
| 301 | <varlistentry id="libcurses">
|
---|
| 302 | <term><filename class="libraryfile">libcurses</filename></term>
|
---|
| 303 | <listitem>
|
---|
| 304 | <para>A link to <filename>libncurses</filename></para>
|
---|
| 305 | <indexterm zone="ch-system-ncurses libcurses">
|
---|
| 306 | <primary sortas="c-libcurses">libcurses</primary>
|
---|
| 307 | </indexterm>
|
---|
| 308 | </listitem>
|
---|
| 309 | </varlistentry>
|
---|
| 310 |
|
---|
| 311 | <varlistentry id="libncurses">
|
---|
| 312 | <term><filename class="libraryfile">libncurses</filename></term>
|
---|
| 313 | <listitem>
|
---|
| 314 | <para>Contains functions to display text in many complex ways on a
|
---|
| 315 | terminal screen; a good example of the use of these functions is the
|
---|
| 316 | menu displayed during the kernel's <command>make
|
---|
| 317 | menuconfig</command></para>
|
---|
| 318 | <indexterm zone="ch-system-ncurses libncurses">
|
---|
| 319 | <primary sortas="c-libncurses">libncurses</primary>
|
---|
| 320 | </indexterm>
|
---|
| 321 | </listitem>
|
---|
| 322 | </varlistentry>
|
---|
| 323 |
|
---|
| 324 | <varlistentry id="libform">
|
---|
| 325 | <term><filename class="libraryfile">libform</filename></term>
|
---|
| 326 | <listitem>
|
---|
| 327 | <para>Contains functions to implement forms</para>
|
---|
| 328 | <indexterm zone="ch-system-ncurses libform">
|
---|
| 329 | <primary sortas="c-libform">libform</primary>
|
---|
| 330 | </indexterm>
|
---|
| 331 | </listitem>
|
---|
| 332 | </varlistentry>
|
---|
| 333 |
|
---|
| 334 | <varlistentry id="libmenu">
|
---|
| 335 | <term><filename class="libraryfile">libmenu</filename></term>
|
---|
| 336 | <listitem>
|
---|
| 337 | <para>Contains functions to implement menus</para>
|
---|
| 338 | <indexterm zone="ch-system-ncurses libmenu">
|
---|
| 339 | <primary sortas="c-libmenu">libmenu</primary>
|
---|
| 340 | </indexterm>
|
---|
| 341 | </listitem>
|
---|
| 342 | </varlistentry>
|
---|
| 343 |
|
---|
| 344 | <varlistentry id="libpanel">
|
---|
| 345 | <term><filename class="libraryfile">libpanel</filename></term>
|
---|
| 346 | <listitem>
|
---|
| 347 | <para>Contains functions to implement panels</para>
|
---|
| 348 | <indexterm zone="ch-system-ncurses libpanel">
|
---|
| 349 | <primary sortas="c-libpanel">libpanel</primary>
|
---|
| 350 | </indexterm>
|
---|
| 351 | </listitem>
|
---|
| 352 | </varlistentry>
|
---|
| 353 |
|
---|
| 354 | </variablelist>
|
---|
| 355 |
|
---|
| 356 | </sect2>
|
---|
[673b0d8] | 357 |
|
---|
| 358 | </sect1>
|
---|