[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 |
|
---|
[aad85a6] | 44 | <para>Don't install a static library that is not handled by configure:</para>
|
---|
[2fa922f] | 45 |
|
---|
[aad85a6] | 46 | <screen><userinput remap="pre">sed -i '/LIBTOOL_INSTALL/d' c++/Makefile.in</userinput></screen>
|
---|
[fa21b3d] | 47 |
|
---|
[2fa922f] | 48 | <para>Prepare Ncurses for compilation:</para>
|
---|
[73aedd1d] | 49 |
|
---|
[f5976ac] | 50 | <screen><userinput remap="configure">./configure --prefix=/usr \
|
---|
| 51 | --mandir=/usr/share/man \
|
---|
| 52 | --with-shared \
|
---|
| 53 | --without-debug \
|
---|
[aad85a6] | 54 | --without-normal \
|
---|
[c0220ed] | 55 | --enable-pc-files \
|
---|
[f5976ac] | 56 | --enable-widec</userinput></screen>
|
---|
[fa21b3d] | 57 |
|
---|
[2fa922f] | 58 | <variablelist>
|
---|
[46ded2b] | 59 | <title>The meaning of the new configure options:</title>
|
---|
[2fa922f] | 60 |
|
---|
| 61 | <varlistentry>
|
---|
| 62 | <term><parameter>--enable-widec</parameter></term>
|
---|
| 63 | <listitem>
|
---|
| 64 | <para>This switch causes wide-character libraries (e.g., <filename
|
---|
| 65 | class="libraryfile">libncursesw.so.&ncurses-version;</filename>)
|
---|
| 66 | to be built instead of normal ones (e.g., <filename
|
---|
| 67 | class="libraryfile">libncurses.so.&ncurses-version;</filename>).
|
---|
| 68 | These wide-character libraries are usable in both multibyte and
|
---|
| 69 | traditional 8-bit locales, while normal libraries work properly
|
---|
| 70 | only in 8-bit locales. Wide-character and normal libraries are
|
---|
| 71 | source-compatible, but not binary-compatible.</para>
|
---|
| 72 | </listitem>
|
---|
| 73 | </varlistentry>
|
---|
| 74 |
|
---|
| 75 | <varlistentry>
|
---|
[c0220ed] | 76 | <term><parameter>--enable-pc-files</parameter></term>
|
---|
[2fa922f] | 77 | <listitem>
|
---|
[c0220ed] | 78 | <para>This switch generates and installs .pc files for pkg-config.
|
---|
| 79 | </para>
|
---|
[2fa922f] | 80 | </listitem>
|
---|
| 81 | </varlistentry>
|
---|
| 82 |
|
---|
[aad85a6] | 83 | <varlistentry>
|
---|
| 84 | <term><parameter>--without-normal</parameter></term>
|
---|
| 85 | <listitem>
|
---|
| 86 | <para>This switch disables building and installing most static libraries.
|
---|
| 87 | </para>
|
---|
| 88 | </listitem>
|
---|
| 89 | </varlistentry>
|
---|
| 90 |
|
---|
[2fa922f] | 91 | </variablelist>
|
---|
| 92 |
|
---|
| 93 | <para>Compile the package:</para>
|
---|
[73aedd1d] | 94 |
|
---|
[0445a3d] | 95 | <screen><userinput remap="make">make</userinput></screen>
|
---|
[73aedd1d] | 96 |
|
---|
[49ae4c6] | 97 | <para>This package has a test suite, but it can only be run after the
|
---|
| 98 | package has been installed. The tests reside in the
|
---|
| 99 | <filename class="directory">test/</filename> directory. See the
|
---|
| 100 | <filename>README</filename> file in that directory for further details.
|
---|
| 101 | </para>
|
---|
[81fd230] | 102 |
|
---|
[2fa922f] | 103 | <para>Install the package:</para>
|
---|
[73aedd1d] | 104 |
|
---|
[0445a3d] | 105 | <screen><userinput remap="install">make install</userinput></screen>
|
---|
[73aedd1d] | 106 |
|
---|
[bc5f39a] | 107 | <para>Move the shared libraries to the
|
---|
| 108 | <filename class="directory">/lib</filename> directory, where they are
|
---|
| 109 | expected to reside:</para>
|
---|
[73aedd1d] | 110 |
|
---|
[f77b95f] | 111 | <screen><userinput remap="install">mv -v /usr/lib/libncursesw.so.6* /lib</userinput></screen>
|
---|
[fa21b3d] | 112 |
|
---|
[2fa922f] | 113 | <para>Because the libraries have been moved, one symlink points to
|
---|
| 114 | a non-existent file. Recreate it:</para>
|
---|
[fa21b3d] | 115 |
|
---|
[112db9d] | 116 | <screen><userinput remap="install">ln -sfv ../../lib/$(readlink /usr/lib/libncursesw.so) /usr/lib/libncursesw.so</userinput></screen>
|
---|
[fa21b3d] | 117 |
|
---|
[2fa922f] | 118 | <para>Many applications still expect the linker to be able to find
|
---|
| 119 | non-wide-character Ncurses libraries. Trick such applications into linking with
|
---|
| 120 | wide-character libraries by means of symlinks and linker scripts:</para>
|
---|
[fa21b3d] | 121 |
|
---|
[ce5ebe1] | 122 | <screen><userinput remap="install">for lib in ncurses form panel menu ; do
|
---|
| 123 | rm -vf /usr/lib/lib${lib}.so
|
---|
[c0220ed] | 124 | echo "INPUT(-l${lib}w)" > /usr/lib/lib${lib}.so
|
---|
| 125 | ln -sfv ${lib}w.pc /usr/lib/pkgconfig/${lib}.pc
|
---|
[aad85a6] | 126 | done</userinput></screen>
|
---|
[fa21b3d] | 127 |
|
---|
[2fa922f] | 128 | <para>Finally, make sure that old applications that look for
|
---|
| 129 | <filename class="libraryfile">-lcurses</filename> at build time are still
|
---|
| 130 | buildable:</para>
|
---|
[fa21b3d] | 131 |
|
---|
[f5976ac] | 132 | <screen><userinput remap="install">rm -vf /usr/lib/libcursesw.so
|
---|
| 133 | echo "INPUT(-lncursesw)" > /usr/lib/libcursesw.so
|
---|
[aad85a6] | 134 | ln -sfv libncurses.so /usr/lib/libcurses.so</userinput></screen>
|
---|
[fa21b3d] | 135 |
|
---|
[2e1fb0ca] | 136 | <para>If desired, install the Ncurses documentation:</para>
|
---|
| 137 |
|
---|
| 138 | <screen><userinput remap="install">mkdir -v /usr/share/doc/ncurses-&ncurses-version;
|
---|
| 139 | cp -v -R doc/* /usr/share/doc/ncurses-&ncurses-version;</userinput></screen>
|
---|
| 140 |
|
---|
[2fa922f] | 141 | <note>
|
---|
| 142 | <para>The instructions above don't create non-wide-character Ncurses
|
---|
| 143 | libraries since no package installed by compiling from sources would
|
---|
[dbc347c5] | 144 | link against them at runtime. However, the only known binary-only
|
---|
| 145 | applications that link against non-wide-character Ncurses libraries
|
---|
| 146 | require version 5. If you must have such libraries because
|
---|
[ce5ebe1] | 147 | of some binary-only application or to be compliant with LSB, build
|
---|
[a26951e] | 148 | the package again with the following commands:</para>
|
---|
[2fa922f] | 149 |
|
---|
[ad83f72] | 150 | <screen role="nodump"><userinput>make distclean
|
---|
[c0220ed] | 151 | ./configure --prefix=/usr \
|
---|
| 152 | --with-shared \
|
---|
| 153 | --without-normal \
|
---|
| 154 | --without-debug \
|
---|
[dbc347c5] | 155 | --without-cxx-binding \
|
---|
| 156 | --with-abi-version=5
|
---|
[ad83f72] | 157 | make sources libs
|
---|
[dbc347c5] | 158 | cp -av lib/lib*.so.5* /usr/lib</userinput></screen>
|
---|
[2fa922f] | 159 | </note>
|
---|
| 160 |
|
---|
| 161 | </sect2>
|
---|
| 162 |
|
---|
| 163 | <sect2 id="contents-ncurses" role="content">
|
---|
| 164 | <title>Contents of Ncurses</title>
|
---|
| 165 |
|
---|
| 166 | <segmentedlist>
|
---|
| 167 | <segtitle>Installed programs</segtitle>
|
---|
| 168 | <segtitle>Installed libraries</segtitle>
|
---|
[fe05b08] | 169 | <segtitle>Installed directories</segtitle>
|
---|
[2fa922f] | 170 |
|
---|
| 171 | <seglistitem>
|
---|
[aad85a6] | 172 | <seg>
|
---|
| 173 | captoinfo (link to tic),
|
---|
| 174 | clear,
|
---|
| 175 | infocmp,
|
---|
| 176 | infotocap (link to tic),
|
---|
| 177 | ncursesw5-config,
|
---|
| 178 | reset (link to tset),
|
---|
| 179 | tabs,
|
---|
| 180 | tic,
|
---|
| 181 | toe,
|
---|
| 182 | tput, and
|
---|
| 183 | tset
|
---|
| 184 | </seg>
|
---|
| 185 | <seg>
|
---|
| 186 | libcursesw.so (symlink and linker script to libncursesw.so),
|
---|
| 187 | libformw.so,
|
---|
| 188 | libmenuw.so,
|
---|
| 189 | libncursesw.so,
|
---|
| 190 | libpanelw.so, and their non-wide-character counterparts without "w"
|
---|
| 191 | in the library names.</seg>
|
---|
| 192 | <seg>
|
---|
| 193 | /usr/share/tabset,
|
---|
| 194 | /usr/share/terminfo, and
|
---|
| 195 | /usr/share/doc/ncurses-&ncurses-version;
|
---|
| 196 | </seg>
|
---|
[2fa922f] | 197 | </seglistitem>
|
---|
| 198 | </segmentedlist>
|
---|
| 199 |
|
---|
| 200 | <variablelist>
|
---|
| 201 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 202 | <?dbfo list-presentation="list"?>
|
---|
| 203 | <?dbhtml list-presentation="table"?>
|
---|
| 204 |
|
---|
| 205 | <varlistentry id="captoinfo">
|
---|
| 206 | <term><command>captoinfo</command></term>
|
---|
| 207 | <listitem>
|
---|
| 208 | <para>Converts a termcap description into a terminfo description</para>
|
---|
| 209 | <indexterm zone="ch-system-ncurses captoinfo">
|
---|
| 210 | <primary sortas="b-captoinfo">captoinfo</primary>
|
---|
| 211 | </indexterm>
|
---|
| 212 | </listitem>
|
---|
| 213 | </varlistentry>
|
---|
| 214 |
|
---|
| 215 | <varlistentry id="clear">
|
---|
| 216 | <term><command>clear</command></term>
|
---|
| 217 | <listitem>
|
---|
| 218 | <para>Clears the screen, if possible</para>
|
---|
| 219 | <indexterm zone="ch-system-ncurses clear">
|
---|
| 220 | <primary sortas="b-clear">clear</primary>
|
---|
| 221 | </indexterm>
|
---|
| 222 | </listitem>
|
---|
| 223 | </varlistentry>
|
---|
| 224 |
|
---|
| 225 | <varlistentry id="infocmp">
|
---|
| 226 | <term><command>infocmp</command></term>
|
---|
| 227 | <listitem>
|
---|
| 228 | <para>Compares or prints out terminfo descriptions</para>
|
---|
| 229 | <indexterm zone="ch-system-ncurses infocmp">
|
---|
| 230 | <primary sortas="b-infocmp">infocmp</primary>
|
---|
| 231 | </indexterm>
|
---|
| 232 | </listitem>
|
---|
| 233 | </varlistentry>
|
---|
| 234 |
|
---|
| 235 | <varlistentry id="infotocap">
|
---|
| 236 | <term><command>infotocap</command></term>
|
---|
| 237 | <listitem>
|
---|
| 238 | <para>Converts a terminfo description into a termcap description</para>
|
---|
| 239 | <indexterm zone="ch-system-ncurses infotocap">
|
---|
| 240 | <primary sortas="b-infotocap">infotocap</primary>
|
---|
| 241 | </indexterm>
|
---|
| 242 | </listitem>
|
---|
| 243 | </varlistentry>
|
---|
| 244 |
|
---|
[90aae6b] | 245 | <varlistentry id="ncursesw5-config">
|
---|
| 246 | <term><command>ncursesw5-config</command></term>
|
---|
[9058aa1] | 247 | <listitem>
|
---|
| 248 | <para>Provides configuration information for ncurses</para>
|
---|
[90aae6b] | 249 | <indexterm zone="ch-system-ncurses ncursesw5-config">
|
---|
| 250 | <primary sortas="b-ncursesw5-config">ncursesw5-config</primary>
|
---|
[9058aa1] | 251 | </indexterm>
|
---|
| 252 | </listitem>
|
---|
| 253 | </varlistentry>
|
---|
| 254 |
|
---|
[2fa922f] | 255 | <varlistentry id="reset">
|
---|
| 256 | <term><command>reset</command></term>
|
---|
| 257 | <listitem>
|
---|
| 258 | <para>Reinitializes a terminal to its default values</para>
|
---|
| 259 | <indexterm zone="ch-system-ncurses reset">
|
---|
| 260 | <primary sortas="b-reset">reset</primary>
|
---|
| 261 | </indexterm>
|
---|
| 262 | </listitem>
|
---|
| 263 | </varlistentry>
|
---|
[3119ddc] | 264 |
|
---|
[90aae6b] | 265 | <varlistentry id="tabs">
|
---|
| 266 | <term><command>tabs</command></term>
|
---|
[2fa922f] | 267 | <listitem>
|
---|
[90aae6b] | 268 | <para>Clears and sets tab stops on a terminal</para>
|
---|
| 269 | <indexterm zone="ch-system-ncurses tabs">
|
---|
| 270 | <primary sortas="b-tabs">tabs</primary>
|
---|
[2fa922f] | 271 | </indexterm>
|
---|
| 272 | </listitem>
|
---|
| 273 | </varlistentry>
|
---|
[3119ddc] | 274 |
|
---|
[2fa922f] | 275 | <varlistentry id="tic">
|
---|
| 276 | <term><command>tic</command></term>
|
---|
| 277 | <listitem>
|
---|
| 278 | <para>The terminfo entry-description compiler that translates a
|
---|
| 279 | terminfo file from source format into the binary format needed for the
|
---|
[b5734891] | 280 | ncurses library routines [A terminfo file contains information on the
|
---|
| 281 | capabilities of a certain terminal.]</para>
|
---|
[2fa922f] | 282 | <indexterm zone="ch-system-ncurses tic">
|
---|
| 283 | <primary sortas="b-tic">tic</primary>
|
---|
| 284 | </indexterm>
|
---|
| 285 | </listitem>
|
---|
| 286 | </varlistentry>
|
---|
| 287 |
|
---|
| 288 | <varlistentry id="toe">
|
---|
| 289 | <term><command>toe</command></term>
|
---|
| 290 | <listitem>
|
---|
| 291 | <para>Lists all available terminal types, giving the primary name and
|
---|
| 292 | description for each</para>
|
---|
| 293 | <indexterm zone="ch-system-ncurses toe">
|
---|
| 294 | <primary sortas="b-toe">toe</primary>
|
---|
| 295 | </indexterm>
|
---|
| 296 | </listitem>
|
---|
| 297 | </varlistentry>
|
---|
| 298 |
|
---|
| 299 | <varlistentry id="tput">
|
---|
| 300 | <term><command>tput</command></term>
|
---|
| 301 | <listitem>
|
---|
| 302 | <para>Makes the values of terminal-dependent capabilities available to
|
---|
| 303 | the shell; it can also be used to reset or initialize a terminal or
|
---|
| 304 | report its long name</para>
|
---|
| 305 | <indexterm zone="ch-system-ncurses tput">
|
---|
| 306 | <primary sortas="b-tput">tput</primary>
|
---|
| 307 | </indexterm>
|
---|
| 308 | </listitem>
|
---|
| 309 | </varlistentry>
|
---|
| 310 |
|
---|
| 311 | <varlistentry id="tset">
|
---|
| 312 | <term><command>tset</command></term>
|
---|
| 313 | <listitem>
|
---|
| 314 | <para>Can be used to initialize terminals</para>
|
---|
| 315 | <indexterm zone="ch-system-ncurses tset">
|
---|
| 316 | <primary sortas="b-tset">tset</primary>
|
---|
| 317 | </indexterm>
|
---|
| 318 | </listitem>
|
---|
| 319 | </varlistentry>
|
---|
| 320 |
|
---|
[930578e4] | 321 | <varlistentry id="libcursesw">
|
---|
| 322 | <term><filename class="libraryfile">libcursesw</filename></term>
|
---|
[2fa922f] | 323 | <listitem>
|
---|
[930578e4] | 324 | <para>A link to <filename>libncursesw</filename></para>
|
---|
| 325 | <indexterm zone="ch-system-ncurses libcursesw">
|
---|
| 326 | <primary sortas="c-libcursesw">libcursesw</primary>
|
---|
[2fa922f] | 327 | </indexterm>
|
---|
| 328 | </listitem>
|
---|
| 329 | </varlistentry>
|
---|
| 330 |
|
---|
[930578e4] | 331 | <varlistentry id="libncursesw">
|
---|
| 332 | <term><filename class="libraryfile">libncursesw</filename></term>
|
---|
[2fa922f] | 333 | <listitem>
|
---|
| 334 | <para>Contains functions to display text in many complex ways on a
|
---|
| 335 | terminal screen; a good example of the use of these functions is the
|
---|
| 336 | menu displayed during the kernel's <command>make
|
---|
| 337 | menuconfig</command></para>
|
---|
[930578e4] | 338 | <indexterm zone="ch-system-ncurses libncursesw">
|
---|
| 339 | <primary sortas="c-libncursesw">libncursesw</primary>
|
---|
[2fa922f] | 340 | </indexterm>
|
---|
| 341 | </listitem>
|
---|
| 342 | </varlistentry>
|
---|
| 343 |
|
---|
[930578e4] | 344 | <varlistentry id="libformw">
|
---|
| 345 | <term><filename class="libraryfile">libformw</filename></term>
|
---|
[2fa922f] | 346 | <listitem>
|
---|
| 347 | <para>Contains functions to implement forms</para>
|
---|
[930578e4] | 348 | <indexterm zone="ch-system-ncurses libformw">
|
---|
| 349 | <primary sortas="c-libformw">libformw</primary>
|
---|
[2fa922f] | 350 | </indexterm>
|
---|
| 351 | </listitem>
|
---|
| 352 | </varlistentry>
|
---|
| 353 |
|
---|
[930578e4] | 354 | <varlistentry id="libmenuw">
|
---|
| 355 | <term><filename class="libraryfile">libmenuw</filename></term>
|
---|
[2fa922f] | 356 | <listitem>
|
---|
| 357 | <para>Contains functions to implement menus</para>
|
---|
[930578e4] | 358 | <indexterm zone="ch-system-ncurses libmenuw">
|
---|
| 359 | <primary sortas="c-libmenuw">libmenuw</primary>
|
---|
[2fa922f] | 360 | </indexterm>
|
---|
| 361 | </listitem>
|
---|
| 362 | </varlistentry>
|
---|
| 363 |
|
---|
[930578e4] | 364 | <varlistentry id="libpanelw">
|
---|
| 365 | <term><filename class="libraryfile">libpanelw</filename></term>
|
---|
[2fa922f] | 366 | <listitem>
|
---|
| 367 | <para>Contains functions to implement panels</para>
|
---|
[930578e4] | 368 | <indexterm zone="ch-system-ncurses libpanelw">
|
---|
| 369 | <primary sortas="c-libpanelw">libpanelw</primary>
|
---|
[2fa922f] | 370 | </indexterm>
|
---|
| 371 | </listitem>
|
---|
| 372 | </varlistentry>
|
---|
| 373 |
|
---|
| 374 | </variablelist>
|
---|
| 375 |
|
---|
| 376 | </sect2>
|
---|
[673b0d8] | 377 |
|
---|
| 378 | </sect1>
|
---|