1 -- $Id: INSTALL,v 1.38 2000/07/08 22:46:08 tom Exp $
2 ---------------------------------------------------------------------
3 How to install Ncurses/Terminfo on your system
4 ---------------------------------------------------------------------
6 ************************************************************
7 * READ ALL OF THIS FILE BEFORE YOU TRY TO INSTALL NCURSES. *
8 ************************************************************
10 You should be reading the file INSTALL in a directory called ncurses-d.d, where
11 d.d is the current version number. There should be several subdirectories,
12 including `c++', `form', `man', `menu', 'misc', `ncurses', `panel', `progs',
13 and `test'. See the README file for a roadmap to the package.
15 If you are a Linux or FreeBSD or NetBSD distribution integrator or packager,
16 please read and act on the section titled IF YOU ARE A SYSTEM INTEGRATOR
19 If you are converting from BSD curses and do not have root access, be sure
20 to read the BSD CONVERSION NOTES section below.
22 If you are using a version of XFree86 xterm older than 3.1.2F, see the section
23 on RECENT XTERM VERSIONS below.
25 If you are trying to build GNU Emacs using ncurses for terminal support,
26 read the USING NCURSES WITH EMACS section below.
28 If you are trying to build applications using gpm with ncurses,
29 read the USING NCURSES WITH GPM section below.
31 If you are running over the Andrew File System see the note below on
32 USING NCURSES WITH AFS.
34 If you want to build the Ada95 binding, go to the Ada95 directory and
35 follow the instructions there. The Ada95 binding is not covered below.
37 If you are using anything but (a) Linux, or (b) one of the 4.4BSD-based
38 i386 Unixes, go read the Portability section in the TO-DO file before you
45 You will need the following in order to build and install ncurses under UNIX:
47 * ANSI C compiler (gcc is recommended)
49 * awk (mawk or gawk will do)
51 * BSD or System V style install (a script is enclosed)
53 Ncurses has been also built in the OS/2 EMX environment.
56 INSTALLATION PROCEDURE:
57 ----------------------
59 1. First, decide whether you want ncurses to replace your existing library (in
60 which case you'll need super-user privileges) or be installed in parallel
63 The --prefix option to configure changes the root directory for installing
64 ncurses. The default is in subdirectories of /usr/local. Use
65 --prefix=/usr to replace your default curses distribution. This is the
66 default for Linux and BSD/OS users.
68 The package gets installed beneath the --prefix directory as follows:
70 In $(prefix)/bin: tic, infocmp, captoinfo, tset,
71 reset, clear, tput, toe
72 In $(prefix)/lib: libncurses*.* libcurses.a
73 In $(prefix)/share/terminfo: compiled terminal descriptions
74 In $(prefix)/include: C header files
75 Under $(prefix)/man: the manual pages
77 Note however that the configure script attempts to locate previous
78 installation of ncurses, and will set the default prefix according to where
79 it finds the ncurses headers.
81 2. Type `./configure' in the top-level directory of the distribution to
82 configure ncurses for your operating system and create the Makefiles.
83 Besides --prefix, various configuration options are available to customize
84 the installation; use `./configure --help' to list the available options.
86 If your operating system is not supported, read the PORTABILITY section in
87 the file ncurses/README for information on how to create a configuration
90 The `configure' script generates makefile rules for one or more object
91 models and their associated libraries:
95 libcurses.a (normal, a link to libncurses.a)
96 This gets left out if you configure with --disable-overwrite.
98 libncurses.so (shared)
100 libncurses_g.a (debug)
102 libncurses_p.a (profile)
104 If you do not specify any models, the normal and debug libraries will be
105 configured. Typing `configure' with no arguments is equivalent to:
107 ./configure --with-normal --with-debug --enable-overwrite
111 ./configure --with-shared
113 makes the shared libraries the default, resulting in
115 ./configure --with-shared --with-normal --with-debug --enable-overwrite
117 If you want only shared libraries, type
119 ./configure --with-shared --without-normal --without-debug
121 Rules for generating shared libraries are highly dependent upon the choice
122 of host system and compiler. We've been testing shared libraries on Linux
123 and SunOS with gcc, but more work needs to be done to make shared libraries
124 work on other systems.
126 You can make curses and terminfo fall back to an existing file of termcap
127 definitions by configuring with --enable-termcap. If you do this, the
128 library will search /etc/termcap before the terminfo database, and will
129 also interpret the contents of the TERM environment variable. See the
130 section BSD CONVERSION NOTES below.
132 3. Type `make'. Ignore any warnings, no error messages should be produced.
133 This should compile the ncurses library, the terminfo compiler tic(1),
134 captoinfo(1), infocmp(1), toe(1), clear(1) tset(1), reset(1), and tput(1)
135 programs (see the manual pages for explanation of what they do), some test
136 programs, and the panels, menus, and forms libraries.
138 4. Run ncurses and several other test programs in the test directory to
139 verify that ncurses functions correctly before doing an install that
140 may overwrite system files. Read the file test/README for details on
143 NOTE: You must have installed the terminfo database, or set the
144 environment variable $TERMINFO to point to a SVr4-compatible terminfo
145 database before running the test programs. Not all vendors' terminfo
146 databases are SVr4-compatible, but most seem to be. Exceptions include
147 DEC's Digital Unix (formerly known as OSF/1).
149 The ncurses program is designed specifically to test the ncurses library.
150 You can use it to verify that the screen highlights work correctly, that
151 cursor addressing and window scrolling works OK, etc.
153 5. Once you've tested, you can type `make install' to install libraries,
154 the programs, the terminfo database and the manual pages. Alternately, you
155 can type `make install' in each directory you want to install. In the
156 top-level directory, you can do a partial install using these commands:
158 'make install.progs' installs tic, infocmp, etc...
159 'make install.includes' installs the headers.
160 'make install.libs' installs the libraries (and the headers).
161 'make install.data' installs the terminfo data. (Note: `tic' must
162 be installed before the terminfo data can be
164 'make install.man' installs the manual pages.
166 ############################################################################
167 # CAVEAT EMPTOR: `install.data' run as root will NUKE any existing #
168 # terminfo database. If you have any custom or unusual entries SAVE them #
169 # before you install ncurses. I have a file called terminfo.custom for #
170 # this purpose. Don't forget to run tic on the file once you're done. #
171 ############################################################################
173 The terminfo(5) manual page must be preprocessed with tbl(1) before
174 being formatted by nroff(1). Modern man(1) implementations tend to do
175 this by default, but you may want to look at your version's manual page
178 If the system already has a curses library that you need to keep using
179 for some bizarre binary-compatibility reason, you'll need to distinguish
180 between it and ncurses. If ncurses is installed outside the standard
181 directories (/usr/include and /usr/lib) then all your users will need
182 to use the -I option to compile programs and -L to link them.
184 If you have BSD curses installed in your system and you accidentally
185 compile using its curses.h you'll end up with a large number of
186 undefined symbols at link time. _waddbytes is one of them.
188 IF YOU DO NOT HAVE ROOT: Change directory to the `progs' subdirectory
189 and run the `capconvert' script. This script will deduce various things
190 about your environment and use them to build you a private terminfo tree,
191 so you can use ncurses applications.
193 If more than one user at your site does this, the space for the duplicate
194 trees is wasted. Try to get your site administrators to install a system-
195 wide terminfo tree instead.
197 See the BSD CONVERSION NOTES section below for a few more details.
199 6. The c++ directory has C++ classes that are built on top of ncurses and
200 panels. You must have c++ (and its libraries) installed before you can
201 compile and run the demo.
203 Use --without-cxx-binding to tell configure to not build the C++ bindings
206 If you do not have C++, you must use the --without-cxx option to tell
207 the configure script to not attempt to determine the type of 'bool'
208 which may be supported by C++. IF YOU USE THIS OPTION, BE ADVISED THAT
209 YOU MAY NOT BE ABLE TO COMPILE (OR RUN) NCURSES APPLICATIONS WITH C++.
211 7. If you're running an older Linux, you must either (a) tell Linux that the
212 console terminal type is `linux' or (b) make a link to or copy of the
213 linux entry in the appropriate place under your terminfo directory, named
214 `console'. All 1.3 and many 1.2 distributions (including Yggdrasil and
215 Red Hat) already have the console type set to `linux'.
217 The way to change the wired-in console type depends on the configuration
218 of your system. This may involve editing /etc/inittab, /etc/ttytype,
219 /etc/profile and other such files.
221 Warning: this is not for the fainthearted, if you mess up your console
222 getty entries you can make your system unusable! However, if you are
223 a distribution maker, this is the right thing to do (see the note for
224 integrators near the end of this file).
226 The easier way is to link or copy l/linux to c/console under your terminfo
227 directory. Note: this will go away next time you do `make install.data'
228 and you'll have to redo it. There is no need to have entries for all
229 possible screen sizes, ncurses will figure out the size automatically.
232 SUMMARY OF CONFIGURE OPTIONS:
233 ----------------------------
235 The configure script provides a short list of its options when you type
239 The --help and several options are common to all configure scripts that are
240 generated with autoconf. Those are all listed before the line
242 --enable and --with options recognized:
244 The other options are specific to this package. We list them in alphabetic
248 Assume machine has little memory. The configure script attempts to
249 determine if your machine has enough memory (about 6Mb) to compile the
250 terminfo database without writing portions to disk. Some allocators
251 return deceptive results, so you may have to override the configure
252 script. Or you may be building tic for a smaller machine.
255 Use only built-in data. The ncurses libraries normally read terminfo
256 and termcap data from disk. You can configure ncurses to have a
257 built-in database, aka "fallback" entries. Embedded applications may
258 have no need for an external database.
261 Disable function-extensions. Configure ncurses without the functions
262 that are not specified by XSI. See ncurses/modules for the exact
263 list of library modules that would be suppressed.
266 For testing, compile-in code that frees memory that normally would not
267 be freed, to simplify analysis of memory-leaks.
270 For testing, use functions rather than macros. The program will run
271 more slowly, but it is simpler to debug. This makes a header file
272 "nomacros.h". See also the --enable-expanded option.
275 If you are installing ncurses on a system which contains another
276 development version of curses, or which could be confused by the loader
277 for another version, we recommend that you leave out the link to
278 -lcurses. The ncurses library is always available as -lncurses.
279 Disabling overwrite also causes the ncurses header files to be
280 installed into a subdirectory, e.g., /usr/local/include/ncurses,
281 rather than the include directory. This makes it simpler to avoid
282 compile-time conflicts with other versions of curses.h
284 --disable-scroll-hints
285 Compile without scroll-hints code. This option is ignored when
286 hashmap scrolling is configured, which is the default.
288 --enable-add-ons=DIR...
289 This is used to check if this package is a glibc add-on. This is used
290 only by the glibc makefiles.
293 For testing, compile-in assertion code. This is used only for a few
294 places where ncurses cannot easily recover by returning an error code.
296 --enable-broken_linker
297 A few platforms have what we consider a broken linker: it cannot link
298 objects from an archive solely by referring to data objects in those
299 files, but requires a function reference. This configure option
300 changes several data references to functions to work around this
303 NOTE: With ncurses 5.1, this may not be necessary, since we are
304 told that some linkers interpret uninitialized global data as a
305 different type of reference which behaves as described above. We have
306 explicitly initialized all of the global data to work around the
310 Recognize BSD-style prefix padding. Some ancient BSD programs (such as
311 nethack) call tputs("50") to implement delays.
314 Compile with experimental $COLORFGBG code. That environment variable
315 is set by some terminal emulators as a hint to applications, by
316 advertising the default foreground and background colors. During
317 initialization, ncurses sets color pair 0 to match this.
320 The curses interface as documented in XSI is rather old, in fact
321 including features that precede ANSI C. The prototypes generally do
322 not make effective use of "const". When using stricter compilers (or
323 gcc with appropriate warnings), you may see warnings about the mismatch
324 between const and non-const data. We provide a configure option which
325 changes the interfaces to use const - quieting these warnings and
326 reflecting the actual use of the parameters more closely. The ncurses
327 library uses the symbol NCURSES_CONST for these instances of const,
328 and if you have asked for compiler warnings, will add gcc's const-qual
329 warning. There will still be warnings due to subtle inconsistencies
330 in the interface, but at a lower level.
332 NOTE: configuring ncurses with this option may detract from the
333 portability of your applications by encouraging you to use const in
334 places where the XSI curses interface would not allow them. Similar
335 issues arise when porting to SVr4 curses, which uses const in even
339 Use the option --disable-echo to make the build-log less verbose by
340 suppressing the display of the compile and link commands. This makes
341 it easier to see the compiler warnings. (You can always use "make -n"
342 to see the options that are used).
345 For testing, generate functions for certain macros to make them visible
346 as such to the debugger. See also the --disable-macros option.
349 Use the 4.4BSD getcap code if available, or a bundled version of it to
350 fetch termcap entries. Entries read in this way cannot use (make
351 cross-references to) the terminfo tree, but it is faster than reading
354 --enable-getcap-cache
355 Cache translated termcaps under the directory $HOME/.terminfo
357 NOTE: this sounds good - it makes ncurses run faster the second time.
358 But look where the data comes from - an /etc/termcap containing lots of
359 entries that are not up to date. If you configure with this option and
360 forget to install the terminfo database before running an ncurses
361 application, you will end up with a hidden terminfo database that
362 generally does not support color and will miss some function keys.
365 Compile-in cursor-optimization code that uses hard-tabs. We would make
366 this a standard feature except for the concern that the terminfo entry
367 may not be accurate, or that your stty settings have disabled the use
371 Compile with hashmap scrolling-optimization code. This is the default,
372 replacing an older scrolling-hints algorithm.
375 Compile-in support for the $NCURSES_NO_PADDING environment variable,
376 which allows you to suppress the effect of non-mandatory padding in
377 terminfo entries. This is the default, unless you have disabled the
381 Use rpath option when generating shared libraries. This applies mainly
382 to systems using the GNU linker (read the manpage).
384 --enable-safe-sprintf
385 Compile with experimental safe-sprintf code. You may consider using
386 this if you are building ncurses for a system that has neither
387 vsnprintf() or vsprintf(). It is slow, however.
390 Compile support for ncurses' SIGWINCH handler. If your application has
391 its own SIGWINCH handler, ncurses will not use its own. The ncurses
392 handler causes wgetch() to return KEY_RESIZE when the screen-size
393 changes. This option is the default, unless you have disabled the
397 If your system supports symbolic links, make tic use symbolic links
398 rather than hard links to save diskspace when writing aliases in the
402 Compile-in support for user-definable terminal capabilities. Use the
403 -x option of tic and infocmp to treat unrecognized terminal
404 capabilities as user-defined strings. This option is the default,
405 unless you have disabled the extended functions.
408 Compile in support for reading terminal descriptions from termcap if no
409 match is found in the terminfo database. See also the --enable-getcap
410 and --enable-getcap-cache options.
413 Turn on GCC compiler warnings. There should be only a few.
416 Compile with experimental wide-character code. This makes a different
417 version of the libraries (e.g., libncursesw.so), which stores
418 characters in 16-bits. We provide a simple UTF-8 driver and test
419 program to use this feature with terminals that can display UTF-8.
421 NOTE: applications compiled with this configuration are not compatible
422 with those built for 8-bit characters. You cannot simply make a
423 symbolic link to equate libncurses.so with libncursesw.so
426 Compile-in support experimental xmc (magic cookie) code.
428 --with-ada-compiler=CMD
429 Specify the Ada95 compiler command (default "gnatmake")
431 --with-ada-include=DIR
432 Tell where to install the Ada includes (default:
433 PREFIX/lib/ada/adainclude)
435 --with-ada-objects=DIR
436 Tell where to install the Ada objects (default: PREFIX/lib/ada/adalib)
439 For testing, compile and link with Conor Cahill's dbmalloc library.
442 Generate debug-libraries (default). These are named by adding "_g"
443 to the root, e.g., libncurses_g.a
446 Enable experimental/development options. This does not count those
447 that change the interface, such as --enable-widec.
450 For testing, compile and link with Gray Watson's dmalloc library.
453 Specify a list of fallback terminal descriptions which will be
454 compiled into the ncurses library. See CONFIGURING FALLBACK ENTRIES.
457 use Alessandro Rubini's GPM library to provide mouse support on the
460 --with-install-prefix=XXX
461 Allows you to specify an alternate location for installing ncurses
462 after building it. The value you specify is prepended to the "real"
463 install location. This simplifies making binary packages.
465 NOTE: a few systems build shared libraries with fixed pathnames; this
466 option probably will not work for those configurations.
468 --with-manpage-format=XXX
469 Tell the configure script how you would like to install man-pages. The
470 option value must be one of these: gzip, compress, BSDI, normal,
471 formatted. If you do not give this option, the configure script
472 attempts to determine which is the case.
474 --with-manpage-renames=XXX
475 Tell the configure script that you wish to rename the manpages while
476 installing. Currently the only distribution which does this is
477 the Linux Debian. The option value specifies the name of a file
478 that lists the renamed files, e.g., $srcdir/man/man_db.renames
480 --with-manpage-symlinks
481 Tell the configure script that you wish to make symbolic links in the
482 man-directory for aliases to the man-pages. This is the default, but
483 can be disabled for systems that provide this automatically. Doing
484 this on systems that do not support symbolic links will result in
485 copying the man-page for each alias.
488 Generate normal (i.e., static) libraries (default).
491 Generate profile-libraries These are named by adding "_p" to the root,
495 Compile-in RCS identifiers. Most of the C files have an identifier.
498 Generate shared-libraries. The names given depend on the system for
499 which you are building, typically using a ".so" suffix, along with
500 symbolic links that refer to the release version.
502 NOTE: Unless you override the configure script by setting the $CFLAGS
503 environment variable, these will not be built with the -g debugging
506 --with-shlib-version=XXX
507 Specify whether to use the release or ABI version for shared libraries.
508 This is normally chosen automatically based on the type of system
509 which you are building on. We use it for testing the configure script.
511 --with-system-type=XXX
512 For testing, override the derived host system-type which is used to
513 decide things such as the linker commands used to build shared
514 libraries. This is normally chosen automatically based on the type of
515 system which you are building on. We use it for testing the configure
518 --with-terminfo-dirs=XXX
519 Specify a search-list of terminfo directories which will be compiled into
520 the ncurses library (default: DATADIR/terminfo)
523 When building the ncurses library, organize this as two parts: the
524 curses library (libncurses) and the low-level terminfo library
525 (libtinfo). This is done to accommodate applications that use only
526 the latter. The terminfo library is about half the size of the total.
529 Suppress the configure script's check for Ada95, do not build the
530 Ada95 binding and related demo.
533 XSI curses declares "bool" as part of the interface. C++ also declares
534 "bool". Neither specifies the size and type of booleans, but both
535 insist on the same name. We chose to accommodate this by making the
536 configure script check for the size and type (e.g., unsigned or signed)
537 that your C++ compiler uses for booleans. If you do not wish to use
538 ncurses with C++, use this option to tell the configure script to not
539 adjust ncurses bool to match C++.
541 --without-cxx-binding
542 Suppress the configure script's check for C++, do not build the
543 C++ binding and related demo.
546 Tell the configure script to suppress the build of ncurses' application
547 programs (e.g., tic). The test applications will still be built if you
548 type "make", though not if you simply do "make install".
551 COMPATIBILITY WITH OLDER VERSIONS OF NCURSES:
552 --------------------------------------------
554 Because ncurses implements the X/Open Curses Specification, its interface
555 is fairly stable. That does not mean the interface does not change.
556 Changes are made to the documented interfaces when we find differences
557 between ncurses and X/Open or implementations which they certify (such as
558 Solaris). We add extensions to those interfaces to solve problems not
559 addressed by the original curses design, but those must not conflict with
560 the X/Open documentation.
562 Here are some of the major interface changes, and related problems which
563 you may encounter when building a system with different versions of
569 + made the extended terminal capabilities
570 (configure --enable-tcap-names) a standard feature. This should
571 be transparent to applications that do not require it.
573 + removed the trace() function and related trace support from the
576 + modified curses.h.in, undef'ing some symbols to avoid conflict
579 Added extensions: assume_default_colors().
581 5.0 (October 23, 1999)
584 + implemented the wcolor_set() and slk_color() functions.
586 + move macro winch to a function, to hide details of struct ldat
588 + corrected prototypes for slk_* functions, using chtype rather than
591 + the slk_attr_{set,off,on} functions need an additional void*
592 parameter according to XSI.
594 + modified several prototypes to correspond with 1997 version of X/Open
595 Curses: [w]attr_get(), [w]attr_set(), border_set() have different
596 parameters. Some functions were renamed or misspelled:
597 erase_wchar(), in_wchntr(), mvin_wchntr(). Some developers have used
600 Added extensions: keybound(), curses_version().
602 Terminfo database changes:
604 + change translation for termcap 'rs' to terminfo 'rs2', which is
605 the documented equivalent, rather than 'rs1'.
607 The problems are subtler in recent releases.
609 a) This release provides users with the ability to define their own
610 terminal capability extensions, like termcap. To accomplish this,
611 we redesigned the TERMTYPE struct (in term.h). Very few
612 applications use this struct. They must be recompiled to work with
615 a) If you use the extended terminfo names (i.e., you used configure
616 --enable-tcap-names), the resulting terminfo database can have some
617 entries which are not readable by older versions of ncurses. This
618 is a bug in the older versions:
620 + the terminfo database stores booleans, numbers and strings in
621 arrays. The capabilities that are listed in the arrays are
622 specified by X/Open. ncurses recognizes a number of obsolete and
623 extended names which are stored past the end of the specified
626 + a change to read_entry.c in 951001 made the library do an lseek()
627 call incorrectly skipping data which is already read from the
628 string array. This happens when the number of strings in the
629 terminfo data file is greater than STRCOUNT, the number of
630 specified and obsolete or extended strings.
632 + as part of alignment with the X/Open final specification, in the
633 990109 patch we added two new terminfo capabilities:
634 set_a_attributes and set_pglen_inch). This makes the indices for
635 the obsolete and extended capabilities shift up by 2.
637 + the last two capabilities in the obsolete/extended list are memu
638 and meml, which are found in most terminfo descriptions for xterm.
640 When trying to read this terminfo entry, the spurious lseek()
641 causes the library to attempt to read the final portion of the
642 terminfo data (the text of the string capabilities) 4 characters
643 past its starting point, and reads 4 characters too few. The
644 library rejects the data, and applications are unable to
645 initialize that terminal type.
647 FIX: remove memu and meml from the xterm description. They are
648 obsolete, not used by ncurses. (It appears that the feature was
649 added to xterm to make it more like hpterm).
651 This is not a problem if you do not use the -x option of tic to
652 create a terminfo database with extended names. Note that the
653 user-defined terminal capabilities are not affected by this bug,
654 since they are stored in a table after the older terminfo data ends,
655 and are invisible to the older libraries.
657 c) Some developers did not wish to use the C++ binding, and used the
658 configure --without-cxx option. This causes problems if someone
659 uses the ncurses library from C++ because that configure test
660 determines the type for C++'s bool and makes ncurses match it, since
661 both C++ and curses are specified to declare bool. Calling ncurses
662 functions with the incorrect type for bool will cause execution
663 errors. In 5.0 we added a configure option "--without-cxx-binding"
664 which controls whether the binding itself is built and installed.
669 + correct prototype for termattrs() as per XPG4 version 2.
671 + add placeholder prototypes for color_set(), erasewchar(),
672 term_attrs(), wcolor_set() as per XPG4 version 2.
674 + add macros getcur[xy] getbeg[xy] getpar[xy], which are defined in
677 New extensions: keyok() and define_key().
679 Terminfo database changes:
681 + corrected definition in curses.h for ACS_LANTERN, which was 'I'
686 We added these extensions: use_default_colors(). Also added
687 configure option --enable-const, to support the use of const where
688 X/Open should have, but did not, specify.
690 The terminfo database content changed the representation of color for
691 most entries that use ANSI colors. SVr4 curses treats the setaf/setab
692 and setf/setb capabilities differently, interchanging the red/blue
693 colors in the latter.
695 4.0 (December 24, 1996)
697 We bumped to version 4.0 because the newly released dynamic loader
698 (ld.so.1.8.5) on Linux did not load shared libraries whose ABI and REL
699 versions were inconsistent. At that point, ncurses ABI was 3.4 and the
700 REL was 1.9.9g, so we made them consistent.
702 1.9.9g (December 1, 1996)
704 This fixed most of the problems with 1.9.9e, and made these interface
707 + remove tparam(), which had been provided for compatibility with
708 some termcap. tparm() is standard, and does not conflict with
709 application's fallback for missing tparam().
711 + turn off hardware echo in initscr(). This changes the sense of the
712 echo() function, which was initialized to echoing rather than
713 nonechoing (the latter is specified). There were several other
714 corrections to the terminal I/O settings which cause applications to
717 + implemented several functions (such as attr_on()) which were
718 available only as macros.
720 + corrected several typos in curses.h.in (i.e., the mvXXXX macros).
722 + corrected prototypes for delay_output(),
723 has_color, immedok() and idcok().
725 + corrected misspelled getbkgd(). Some applications used the
728 + added _yoffset to WINDOW. The size of WINDOW does not impact
729 applications, since they use only pointers to WINDOW structs.
731 These changes were made to the terminfo database:
733 + removed boolean 'getm' which was available as an extended name.
735 We added these extensions: wresize(), resizeterm(), has_key() and
738 1.9.9e (March 24, 1996)
740 not recommended (a last-minute/untested change left the forms and
741 menus libraries unusable since they do not repaint the screen).
742 Foreground/background colors are combined incorrectly, working properly
743 only on a black background. When this was released, the X/Open
744 specification was available only in draft form.
746 Some applications (such as lxdialog) were "fixed" to work with the
747 incorrect color scheme.
750 IF YOU ARE A SYSTEM INTEGRATOR:
751 ------------------------------
753 Beginning with 1.9.9, the ncurses distribution includes both a tset
754 utility and /usr/share/tabset directory. If you are installing ncurses,
755 it is no longer either necessary or desirable to install tset-jv.
757 Configuration and Installation:
759 Configure with --prefix=/usr to make the install productions put
760 libraries and headers in the correct locations (overwriting any
761 previous curses libraries and headers). This will put the terminfo
762 hierarchy under /usr/share/terminfo; you may want to override this with
763 --datadir=/usr/share/misc; terminfo and tabset are installed under the
766 Please configure the ncurses library in a pure-terminfo mode; that
767 is, with the --disable-termcap option. This will make the ncurses
768 library smaller and faster. The ncurses library includes a termcap
769 emulation that queries the terminfo database, so even applications
770 that use raw termcap to query terminal characteristics will win
771 (providing you recompile and relink them!).
773 If you must configure with termcap fallback enabled, you may also
774 wish to use the --enable-getcap option. This option speeds up
775 termcap-based startups, at the expense of not allowing personal
776 termcap entries to reference the terminfo tree. See the code in
777 ncurses/tinfo/read_termcap.c for details.
779 Note that if you have $TERMCAP set, ncurses will use that value
780 to locate termcap data. In particular, running from xterm will
781 set $TERMCAP to the contents of the xterm's termcap entry.
782 If ncurses sees that, it will not examine /etc/termcap.
786 The terminfo file assumes that Shift-Tab generates \E[Z (the ECMA-48
787 reverse-tabulation sequence) rather than ^I. Here are the loadkeys -d
788 mappings that will set this up:
791 alt keycode 15 = Meta_Tab
792 shift keycode 15 = F26
795 Naming the Console Terminal
797 In various Linuxes (and possibly elsewhere) there has been a practice
798 of designating the system console driver type as `console'. Please
799 do not do this any more! It complicates peoples' lives, because it
800 can mean that several different terminfo entries from different
801 operating systems all logically want to be called `console'.
803 Please pick a name unique to your console driver and set that up
804 in the /etc/inittab table or local equivalent. Send the entry to the
805 terminfo maintainer (listed in the misc/terminfo file) to be included
806 in the terminfo file, if it's not already there. See the
807 term(7) manual page included with this distribution for more on
808 conventions for choosing type names.
810 Here are some recommended primary console names:
812 linux -- Linux console driver
817 If you are responsible for integrating ncurses for one of these
818 distribution, please either use the recommended name or get back
819 to us explaining why you don't want to, so we can work out nomenclature
820 that will make users' lives easier rather than harder.
823 RECENT XTERM VERSIONS:
824 ---------------------
826 The terminfo database file included with this distribution assumes you
827 are running an XFree86 xterm based on X11R6 (i.e., xterm-r6). The
828 earlier X11R5 entry (xterm-r5) is provided as well.
830 If you are running XFree86 version 3.2 (actually 3.1.2F and up), you
831 should consider using the xterm-xf86-v32 (or later, the most recent
832 version is always named "xterm-xfree86") entry, which adds ANSI color
833 and the VT220 capabilities which have been added in XFree86. If you
834 are running a mixed network, however, where this terminal description
835 may be used on an older xterm, you may have problems, since
836 applications that assume these capabilities will produce incorrect
837 output on the older xterm (e.g., highlighting is not cleared).
840 CONFIGURING FALLBACK ENTRIES:
841 ----------------------------
843 In order to support operation of ncurses programs before the terminfo
844 tree is accessible (that is, in single-user mode or at OS installation
845 time) the ncurses library can be compiled to include an array of
846 pre-fetched fallback entries.
848 These entries are checked by setupterm() only when the conventional
849 fetches from the terminfo tree and the termcap fallback (if configured)
850 have been tried and failed. Thus, the presence of a fallback will not
851 shadow modifications to the on-disk entry for the same type, when that
854 By default, there are no entries on the fallback list. After you
855 have built the ncurses suite for the first time, you can change
856 the list (the process needs infocmp(1)). To do so, use the script
857 MKfallback.sh. A configure script option --with-fallbacks does this
858 (it accepts a comma-separated list of the names you wish, and does
859 not require a rebuild).
861 If you wanted (say) to have linux, vt100, and xterm fallbacks, you
862 would use the commands
865 MKfallback.sh linux vt100 xterm >fallback.c
867 Then just rebuild and reinstall the library as you would normally.
868 You can restore the default empty fallback list with
870 MKfallback.sh >fallback.c
872 The overhead for an empty fallback list is one trivial stub function.
873 Any non-empty fallback list is const-ed and therefore lives in sharable
874 text space. You can look at the comment trailing each initializer in
875 the generated ncurses/fallback.c file to see the core cost of the
876 fallbacks. A good rule of thumb for modern vt100-like entries is that
877 each one will cost about 2.5K of text space.
880 BSD CONVERSION NOTES:
883 If you need to support really ancient BSD programs, you probably
884 want to configure with the --enable-bsdpad option. What this does
885 is enable code in tputs() that recognizes a numeric prefix on a
886 capability as a request for that much trailing padding in milliseconds.
887 There are old BSD programs that do things like tputs("50").
889 (If you are distributing ncurses as a support-library component of
890 an application you probably want to put the remainder of this section
891 in the package README file.)
893 The following note applies only if you have configured ncurses with
896 ------------------------------- CUT HERE --------------------------------
898 If you are installing this application privately (either because you
899 have no root access or want to experiment with it before doing a root
900 installation), there are a couple of details you need to be aware of.
901 They have to do with the ncurses library, which uses terminfo rather
902 than termcap for describing terminal characteristics.
904 Though the ncurses library is terminfo-based, it will interpret your
905 TERMCAP variable (if present), any local termcap files you reference
906 through it, and the system termcap file. However, in order to avoid
907 slowing down your application startup, it will only do this once per
910 The first time you load a given terminal type from your termcap
911 database, the library initialization code will automatically write it
912 in terminfo format to a subdirectory under $HOME/.terminfo. After
913 that, the initialization code will find it there and do a (much
914 faster) terminfo fetch.
916 Usually, all this means is that your home directory will silently grow
917 an invisible .terminfo subdirectory which will get filled in with
918 terminfo descriptions of terminal types as you invoke them. If anyone
919 ever installs a global terminfo tree on your system, this will quietly
920 stop happening and your $HOME/.terminfo will become redundant.
922 The objective of all this logic is to make converting from BSD termcap
923 as painless as possible without slowing down your application (termcap
924 compilation is expensive).
926 If you don't have a TERMCAP variable or custom personal termcap file,
927 you can skip the rest of this dissertation.
929 If you *do* have a TERMCAP variable and/or a custom personal termcap file
930 that defines a terminal type, that definition will stop being visible
931 to this application after the first time you run it, because it will
932 instead see the terminfo entry that it wrote to $HOME/terminfo the
935 Subsequently, editing the TERMCAP variable or personal TERMCAP file
936 will have no effect unless you explicitly remove the terminfo entry
937 under $HOME/terminfo. If you do that, the entry will be recompiled
938 from your termcap resources the next time it is invoked.
940 To avoid these complications, use infocmp(1) and tic(1) to edit the
941 terminfo directory directly.
943 ------------------------------- CUT HERE --------------------------------
945 USING NCURSES WITH AFS:
946 AFS treats each directory as a separate logical filesystem, you
947 can't hard-link across them. The --enable-symlinks option copes
948 with this by making tic use symbolic links.
950 USING NCURSES WITH EMACS:
951 GNU Emacs has its own termcap support. By default, it uses a mixture
952 of those functions and code linked from the host system's libraries.
953 You need to foil this and shut out the GNU termcap library entirely.
955 In order to do this, hack the Linux config file (s/linux.h) to contain
956 a #define TERMINFO and set the symbol LIBS_TERMCAP to "-lncurses".
958 We have submitted such a change for the 19.30 release, so it may
959 already be applied in your sources -- check for the #define TERMINFO.
961 USING NCURSES WITH GPM:
962 Ncurses 4.1 and up can be configured to use GPM (General Purpose Mouse)
963 which is used on Linux console. Be aware that GPM is commonly
964 installed as a shared library which contains a wrapper for the curses
965 wgetch() function (libcurses.o). Some integrators have simplified
966 linking applications by combining all or part of libcurses.so (the BSD
967 curses) into the libgpm.so file, producing symbol conflicts with
968 ncurses (specifically the wgetch function). You may be able to work
969 around this problem by linking as follows:
971 cc -o foo foo.o -lncurses -lgpm -lncurses
973 but the linker may not cooperate, producing mysterious errors.
974 A patched version of gpm is available:
976 dickey.his.com:/ncurses/gpm-1.10-970125.tar.gz
978 This patch is incorporated in gpm 1.12; however some integrators
979 are slow to update this library. Current distributions of gpm can
980 be configured properly using the --without-curses option.
983 Send any feedback to the ncurses mailing list at
984 bug-ncurses@gnu.org. To subscribe send mail to
985 bug-ncurses-request@gnu.org with body that reads:
986 subscribe ncurses <your-email-address-here>
988 The Hacker's Guide in the misc directory includes some guidelines
989 on how to report bugs in ways that will get them fixed most quickly.