xref: /freebsd/contrib/ncurses/INSTALL (revision 21817992b3314c908ab50f0bb88d2ee750b9c4ac)
14a1a9510SRong-En Fan-------------------------------------------------------------------------------
2*21817992SBaptiste Daroussin-- Copyright 2018-2023,2024 Thomas E. Dickey                                 --
3e1865124SBaptiste Daroussin-- Copyright 1998-2017,2018 Free Software Foundation, Inc.                   --
44a1a9510SRong-En Fan--                                                                           --
54a1a9510SRong-En Fan-- Permission is hereby granted, free of charge, to any person obtaining a   --
64a1a9510SRong-En Fan-- copy of this software and associated documentation files (the             --
74a1a9510SRong-En Fan-- "Software"), to deal in the Software without restriction, including       --
84a1a9510SRong-En Fan-- without limitation the rights to use, copy, modify, merge, publish,       --
94a1a9510SRong-En Fan-- distribute, distribute with modifications, sublicense, and/or sell copies --
104a1a9510SRong-En Fan-- of the Software, and to permit persons to whom the Software is furnished  --
114a1a9510SRong-En Fan-- to do so, subject to the following conditions:                            --
124a1a9510SRong-En Fan--                                                                           --
134a1a9510SRong-En Fan-- The above copyright notice and this permission notice shall be included   --
144a1a9510SRong-En Fan-- in all copies or substantial portions of the Software.                    --
154a1a9510SRong-En Fan--                                                                           --
164a1a9510SRong-En Fan-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS   --
174a1a9510SRong-En Fan-- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF                --
184a1a9510SRong-En Fan-- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN --
194a1a9510SRong-En Fan-- NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,       --
204a1a9510SRong-En Fan-- DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR     --
214a1a9510SRong-En Fan-- OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE --
224a1a9510SRong-En Fan-- USE OR OTHER DEALINGS IN THE SOFTWARE.                                    --
234a1a9510SRong-En Fan--                                                                           --
244a1a9510SRong-En Fan-- Except as contained in this notice, the name(s) of the above copyright    --
254a1a9510SRong-En Fan-- holders shall not be used in advertising or otherwise to promote the      --
264a1a9510SRong-En Fan-- sale, use or other dealings in this Software without prior written        --
274a1a9510SRong-En Fan-- authorization.                                                            --
284a1a9510SRong-En Fan-------------------------------------------------------------------------------
29*21817992SBaptiste Daroussin-- $Id: INSTALL,v 1.254 2024/04/27 14:21:05 tom Exp $
300e3d5408SPeter Wemm---------------------------------------------------------------------
310e3d5408SPeter Wemm             How to install Ncurses/Terminfo on your system
320e3d5408SPeter Wemm---------------------------------------------------------------------
3315589c42SPeter Wemm
340e3d5408SPeter Wemm    ************************************************************
350e3d5408SPeter Wemm    * READ ALL OF THIS FILE BEFORE YOU TRY TO INSTALL NCURSES. *
360e3d5408SPeter Wemm    ************************************************************
370e3d5408SPeter Wemm
38*21817992SBaptiste DaroussinYou should be reading the file INSTALL in a directory called ncurses-d.d,
39*21817992SBaptiste Daroussinwhere d.d is the current version number.  There should be several
40*21817992SBaptiste Daroussinsubdirectories, including 'c++', 'form', 'man', 'menu', 'misc', 'ncurses',
41*21817992SBaptiste Daroussin'panel', 'progs', and 'test'.  See 'README' for a roadmap to the package.
420e3d5408SPeter Wemm
4306bfebdeSXin LIIf you are a distribution integrator or packager, please read and act on the
447a656419SBaptiste Daroussinsection titled FOR SYSTEM INTEGRATORS below.
450e3d5408SPeter Wemm
460e3d5408SPeter WemmIf you are converting from BSD curses and do not have root access, be sure
470e3d5408SPeter Wemmto read the BSD CONVERSION NOTES section below.
480e3d5408SPeter Wemm
490e3d5408SPeter WemmIf you are trying to build applications using gpm with ncurses,
50*21817992SBaptiste Daroussinread the USING GPM section below.
510e3d5408SPeter Wemm
52*21817992SBaptiste DaroussinIf you are cross-compiling, see the note below on
53*21817992SBaptiste DaroussinBUILDING WITH A CROSS-COMPILER.
5418259542SPeter Wemm
550e3d5408SPeter WemmIf you want to build the Ada95 binding, go to the Ada95 directory and
560e3d5408SPeter Wemmfollow the instructions there.  The Ada95 binding is not covered below.
570e3d5408SPeter Wemm
5815589c42SPeter Wemm
590e3d5408SPeter WemmREQUIREMENTS:
6015589c42SPeter Wemm------------
610e3d5408SPeter Wemm
624a1a9510SRong-En FanYou will need the following to build and install ncurses under UNIX:
630e3d5408SPeter Wemm
644a1a9510SRong-En Fan	* ANSI C compiler  (gcc, for instance)
650e3d5408SPeter Wemm	* sh               (bash will do)
660e3d5408SPeter Wemm	* awk              (mawk or gawk will do)
670e3d5408SPeter Wemm	* sed
680e3d5408SPeter Wemm	* BSD or System V style install (a script is enclosed)
690e3d5408SPeter Wemm
700e3d5408SPeter WemmNcurses has been also built in the OS/2 EMX environment.
710e3d5408SPeter Wemm
7215589c42SPeter Wemm
730e3d5408SPeter WemmINSTALLATION PROCEDURE:
7415589c42SPeter Wemm----------------------
750e3d5408SPeter Wemm
76*21817992SBaptiste Daroussin1.  First, decide whether you want ncurses to replace your existing library
77*21817992SBaptiste Daroussin    (in which case you'll need super-user privileges) or be installed in
78*21817992SBaptiste Daroussin    parallel with it.
790e3d5408SPeter Wemm
800e3d5408SPeter Wemm    The --prefix option to configure changes the root directory for installing
814a1a9510SRong-En Fan    ncurses.  The default is normally in subdirectories of /usr/local, except
8206bfebdeSXin LI    for systems where ncurses is normally installed as a system library (see
83*21817992SBaptiste Daroussin    "FOR SYSTEM INTEGRATORS").  Use --prefix=/usr to replace your
8406bfebdeSXin LI    default curses distribution.
850e3d5408SPeter Wemm
860e3d5408SPeter Wemm    The package gets installed beneath the --prefix directory as follows:
870e3d5408SPeter Wemm
880e3d5408SPeter Wemm    In $(prefix)/bin:          tic, infocmp, captoinfo, tset,
8906bfebdeSXin LI				reset, clear, tput, toe, tabs
900e3d5408SPeter Wemm    In $(prefix)/lib:          libncurses*.* libcurses.a
910e3d5408SPeter Wemm    In $(prefix)/share/terminfo: compiled terminal descriptions
920e3d5408SPeter Wemm    In $(prefix)/include:      C header files
930e3d5408SPeter Wemm    Under $(prefix)/man:       the manual pages
940e3d5408SPeter Wemm
954a1a9510SRong-En Fan    Note that the configure script attempts to locate previous installation of
964a1a9510SRong-En Fan    ncurses, and will set the default prefix according to where it finds the
974a1a9510SRong-En Fan    ncurses headers.
984a1a9510SRong-En Fan
994a1a9510SRong-En Fan    Do not use commands such as
1004a1a9510SRong-En Fan
1014a1a9510SRong-En Fan	make install prefix=XXX
1024a1a9510SRong-En Fan
1034a1a9510SRong-En Fan    to change the prefix after configuration, since the prefix value is used
1044a1a9510SRong-En Fan    for some absolute pathnames such as TERMINFO.  Instead do this
1054a1a9510SRong-En Fan
1064a1a9510SRong-En Fan	make install DESTDIR=XXX
1074a1a9510SRong-En Fan
1084a1a9510SRong-En Fan    See also the discussion of --with-install-prefix.
1090e3d5408SPeter Wemm
110*21817992SBaptiste Daroussin2.  Type './configure' in the top-level directory of the distribution to
1110e3d5408SPeter Wemm    configure ncurses for your operating system and create the Makefiles.
1120e3d5408SPeter Wemm    Besides --prefix, various configuration options are available to customize
113*21817992SBaptiste Daroussin    the installation; use './configure --help' to list the available options.
1140e3d5408SPeter Wemm
1150e3d5408SPeter Wemm    If your operating system is not supported, read the PORTABILITY section in
1160e3d5408SPeter Wemm    the file ncurses/README for information on how to create a configuration
1170e3d5408SPeter Wemm    file for your system.
1180e3d5408SPeter Wemm
119*21817992SBaptiste Daroussin    The 'configure' script generates makefile rules for one or more object
1200e3d5408SPeter Wemm    models and their associated libraries:
1210e3d5408SPeter Wemm
1220e3d5408SPeter Wemm	libncurses.a (normal)
1230e3d5408SPeter Wemm
1240e3d5408SPeter Wemm	libcurses.a (normal, a link to libncurses.a)
1250e3d5408SPeter Wemm		This gets left out if you configure with --disable-overwrite.
1260e3d5408SPeter Wemm
1270e3d5408SPeter Wemm	libncurses.so (shared)
1280e3d5408SPeter Wemm
1290e3d5408SPeter Wemm	libncurses_g.a (debug)
1300e3d5408SPeter Wemm
1310e3d5408SPeter Wemm	libncurses_p.a (profile)
1320e3d5408SPeter Wemm
1337a69bbfbSPeter Wemm	libncurses.la (libtool)
1347a69bbfbSPeter Wemm
1354a1a9510SRong-En Fan    If you configure using the --enable-widec option, a "w" is appended to the
1364a1a9510SRong-En Fan    library names (e.g., libncursesw.a), and the resulting libraries support
1374a1a9510SRong-En Fan    wide-characters, e.g., via a UTF-8 locale.  The corresponding header files
1384a1a9510SRong-En Fan    are compatible with the non-wide-character configuration; wide-character
1394a1a9510SRong-En Fan    features are provided by ifdef's in the header files.  The wide-character
1404a1a9510SRong-En Fan    library interfaces are not binary-compatible with the non-wide-character
1414a1a9510SRong-En Fan    version.  Building and running the wide-character code relies on a fairly
1424a1a9510SRong-En Fan    recent implementation of libiconv.  We have built this configuration on
14306bfebdeSXin LI    various systems using libiconv, sometimes requiring libutf8.
1444a1a9510SRong-En Fan
145aa59d4d4SRong-En Fan    If you configure using the --with-pthread option, a "t" is appended to
146aa59d4d4SRong-En Fan    the library names (e.g., libncursest.a, libncursestw.a).
147aa59d4d4SRong-En Fan
1480e3d5408SPeter Wemm    If you do not specify any models, the normal and debug libraries will be
149*21817992SBaptiste Daroussin    configured.  Typing 'configure' with no arguments is equivalent to:
1500e3d5408SPeter Wemm
1510e3d5408SPeter Wemm	./configure --with-normal --with-debug --enable-overwrite
1520e3d5408SPeter Wemm
1530e3d5408SPeter Wemm    Typing
1540e3d5408SPeter Wemm
1550e3d5408SPeter Wemm	./configure --with-shared
1560e3d5408SPeter Wemm
1570e3d5408SPeter Wemm    makes the shared libraries the default, resulting in
1580e3d5408SPeter Wemm
1590e3d5408SPeter Wemm	./configure --with-shared --with-normal --with-debug --enable-overwrite
1600e3d5408SPeter Wemm
1610e3d5408SPeter Wemm    If you want only shared libraries, type
1620e3d5408SPeter Wemm
1630e3d5408SPeter Wemm	./configure --with-shared --without-normal --without-debug
1640e3d5408SPeter Wemm
1650e3d5408SPeter Wemm    Rules for generating shared libraries are highly dependent upon the choice
16606bfebdeSXin LI    of host system and compiler.  We've been testing shared libraries on
16706bfebdeSXin LI    several systems, but more work needs to be done to make shared libraries
1680e3d5408SPeter Wemm    work on other systems.
1690e3d5408SPeter Wemm
1707a69bbfbSPeter Wemm    If you have libtool installed, you can type
1717a69bbfbSPeter Wemm
1727a69bbfbSPeter Wemm	./configure --with-libtool
1737a69bbfbSPeter Wemm
1747a69bbfbSPeter Wemm    to generate the appropriate static and/or shared libraries for your
1757a69bbfbSPeter Wemm    platform using libtool.
1767a69bbfbSPeter Wemm
1770e3d5408SPeter Wemm    You can make curses and terminfo fall back to an existing file of termcap
1780e3d5408SPeter Wemm    definitions by configuring with --enable-termcap.  If you do this, the
1790e3d5408SPeter Wemm    library will search /etc/termcap before the terminfo database, and will
180*21817992SBaptiste Daroussin    also interpret the contents of the $TERM environment variable.  See the
1810e3d5408SPeter Wemm    section BSD CONVERSION NOTES below.
1820e3d5408SPeter Wemm
183*21817992SBaptiste Daroussin3.  Type 'make'.  Ignore any warnings; no error messages should be produced.
1840e3d5408SPeter Wemm    This should compile the ncurses library, the terminfo compiler tic(1),
1850e3d5408SPeter Wemm    captoinfo(1), infocmp(1), toe(1), clear(1) tset(1), reset(1), and tput(1)
18618259542SPeter Wemm    programs (see the manual pages for explanation of what they do), some test
1870e3d5408SPeter Wemm    programs, and the panels, menus, and forms libraries.
1880e3d5408SPeter Wemm
1890e3d5408SPeter Wemm4.  Run ncurses and several other test programs in the test directory to
1900e3d5408SPeter Wemm    verify that ncurses functions correctly before doing an install that
1910e3d5408SPeter Wemm    may overwrite system files.  Read the file test/README for details on
1920e3d5408SPeter Wemm    the test programs.
1930e3d5408SPeter Wemm
1940e3d5408SPeter Wemm    NOTE: You must have installed the terminfo database, or set the
1950e3d5408SPeter Wemm    environment variable $TERMINFO to point to a SVr4-compatible terminfo
1960e3d5408SPeter Wemm    database before running the test programs.  Not all vendors' terminfo
197aae38d10SBaptiste Daroussin    databases are SVr4-compatible, but most seem to be.
198aae38d10SBaptiste Daroussin
199*21817992SBaptiste Daroussin    It is possible to configure ncurses to use other terminfo database
200*21817992SBaptiste Daroussin    formats.  A few are provided as examples in the include-directory (see
201*21817992SBaptiste Daroussin    --with-caps).
2020e3d5408SPeter Wemm
2034a1a9510SRong-En Fan    If you run the test programs WITHOUT installing terminfo, ncurses may
2044a1a9510SRong-En Fan    read the termcap file and cache that in $HOME/.terminfo, which will
2054a1a9510SRong-En Fan    thereafter be used instead of the terminfo database.  See the comments
2064a1a9510SRong-En Fan    on "--enable-getcap-cache", to see why this is a Bad Thing.
2074a1a9510SRong-En Fan
2080e3d5408SPeter Wemm    The ncurses program is designed specifically to test the ncurses library.
2090e3d5408SPeter Wemm    You can use it to verify that the screen highlights work correctly, that
2100e3d5408SPeter Wemm    cursor addressing and window scrolling works OK, etc.
2110e3d5408SPeter Wemm
212*21817992SBaptiste Daroussin5.  Once you've tested, you can type 'make install' to install libraries,
213*21817992SBaptiste Daroussin    the programs, the terminfo database and the manual pages.  Alternately,
214*21817992SBaptiste Daroussin    you can type 'make install' in each directory you want to install.  In the
2150e3d5408SPeter Wemm    top-level directory, you can do a partial install using these commands:
2160e3d5408SPeter Wemm
2170e3d5408SPeter Wemm	'make install.progs'    installs tic, infocmp, etc...
2180e3d5408SPeter Wemm	'make install.includes' installs the headers.
2190e3d5408SPeter Wemm	'make install.libs'     installs the libraries (and the headers).
220*21817992SBaptiste Daroussin	'make install.data'     installs the terminfo data. (Note: 'tic' must
2210e3d5408SPeter Wemm				be installed before the terminfo data can be
2220e3d5408SPeter Wemm				compiled).
22318259542SPeter Wemm	'make install.man'      installs the manual pages.
2240e3d5408SPeter Wemm
2250e3d5408SPeter Wemm  ############################################################################
226*21817992SBaptiste Daroussin  #     CAVEAT EMPTOR: 'install.data' run as root will NUKE any existing     #
2270e3d5408SPeter Wemm  #  terminfo database. If you have any custom or unusual entries SAVE them  #
228aae38d10SBaptiste Daroussin  #  before you install ncurses.                                             #
2290e3d5408SPeter Wemm  ############################################################################
2300e3d5408SPeter Wemm
23118259542SPeter Wemm    The terminfo(5) manual page must be preprocessed with tbl(1) before
2320e3d5408SPeter Wemm    being formatted by nroff(1).  Modern man(1) implementations tend to do
23318259542SPeter Wemm    this by default, but you may want to look at your version's manual page
2347a69bbfbSPeter Wemm    to be sure.  You may also install the manual pages after preprocessing
2357a69bbfbSPeter Wemm    with tbl(1) by specifying the configure option --with-manpage-tbl.
2360e3d5408SPeter Wemm
2370e3d5408SPeter Wemm    If the system already has a curses library that you need to keep using
2384a1a9510SRong-En Fan    you'll need to distinguish between it and ncurses.  See the discussion of
2394a1a9510SRong-En Fan    --disable-overwrite.  If ncurses is installed outside the standard
2404a1a9510SRong-En Fan    directories (/usr/include and /usr/lib) then all your users will need to
2414a1a9510SRong-En Fan    use the -I option to compile programs and -L to link them.
2420e3d5408SPeter Wemm
2434a1a9510SRong-En Fan    If you have another curses installed in your system and you accidentally
2440e3d5408SPeter Wemm    compile using its curses.h you'll end up with a large number of
2454a1a9510SRong-En Fan    undefined symbols at link time.
2460e3d5408SPeter Wemm
247*21817992SBaptiste Daroussin    IF YOU DO NOT HAVE ROOT: Change directory to the 'progs' subdirectory
248*21817992SBaptiste Daroussin    and run the 'capconvert' script.  This script will deduce various things
2490e3d5408SPeter Wemm    about your environment and use them to build you a private terminfo tree,
2500e3d5408SPeter Wemm    so you can use ncurses applications.
2510e3d5408SPeter Wemm
2520e3d5408SPeter Wemm    If more than one user at your site does this, the space for the duplicate
2530e3d5408SPeter Wemm    trees is wasted.  Try to get your site administrators to install a system-
2540e3d5408SPeter Wemm    wide terminfo tree instead.
2550e3d5408SPeter Wemm
2560e3d5408SPeter Wemm    See the BSD CONVERSION NOTES section below for a few more details.
2570e3d5408SPeter Wemm
2580e3d5408SPeter Wemm6.  The c++ directory has C++ classes that are built on top of ncurses and
2591759abf3SPeter Wemm    panels.  You must have c++ (and its libraries) installed before you can
2600e3d5408SPeter Wemm    compile and run the demo.
2610e3d5408SPeter Wemm
2621759abf3SPeter Wemm    Use --without-cxx-binding to tell configure to not build the C++ bindings
2631759abf3SPeter Wemm    and demo.
2641759abf3SPeter Wemm
2650e3d5408SPeter Wemm    If you do not have C++, you must use the --without-cxx option to tell
2661759abf3SPeter Wemm    the configure script to not attempt to determine the type of 'bool'
2671759abf3SPeter Wemm    which may be supported by C++.  IF YOU USE THIS OPTION, BE ADVISED THAT
2681759abf3SPeter Wemm    YOU MAY NOT BE ABLE TO COMPILE (OR RUN) NCURSES APPLICATIONS WITH C++.
2690e3d5408SPeter Wemm
27015589c42SPeter Wemm
2717a656419SBaptiste DaroussinCONFIGURE OPTIONS:
2727a656419SBaptiste Daroussin-----------------
27318259542SPeter Wemm
27418259542SPeter Wemm    The configure script provides a short list of its options when you type
27518259542SPeter Wemm
27618259542SPeter Wemm	./configure --help
27718259542SPeter Wemm
278*21817992SBaptiste Daroussin    The --help and several options are common to all configure scripts that
279*21817992SBaptiste Daroussin    are generated with autoconf.  Those are all listed before the line
28018259542SPeter Wemm
28118259542SPeter Wemm	--enable and --with options recognized:
28218259542SPeter Wemm
283*21817992SBaptiste Daroussin    The other options are specific to this package.  We list them in
284*21817992SBaptiste Daroussin    alphabetic order.
28518259542SPeter Wemm
28618259542SPeter Wemm    --disable-assumed-color
28718259542SPeter Wemm	With ncurses 5.1, we introduced a new function, assume_default_colors()
28818259542SPeter Wemm	which allows applications to specify what the default foreground and
28918259542SPeter Wemm	background color are assumed to be.  Most color applications use
29018259542SPeter Wemm	full-screen color; but a few do not color the background.  While the
29118259542SPeter Wemm	assumed values can be overridden by invoking assume_default_colors(),
29218259542SPeter Wemm	you may find it useful to set the assumed values to the pre-5.1
29318259542SPeter Wemm	convention, using this configure option.
29418259542SPeter Wemm
29518259542SPeter Wemm    --disable-big-core
29618259542SPeter Wemm	Assume machine has little memory.  The configure script attempts to
29718259542SPeter Wemm	determine if your machine has enough memory (about 6Mb) to compile the
29818259542SPeter Wemm	terminfo database without writing portions to disk.  Some allocators
29918259542SPeter Wemm	return deceptive results, so you may have to override the configure
30018259542SPeter Wemm	script.  Or you may be building tic for a smaller machine.
30118259542SPeter Wemm
3025ca44d1cSRong-En Fan    --disable-big-strings
3035ca44d1cSRong-En Fan	Disable compile-time optimization of predefined tables which puts
3045ca44d1cSRong-En Fan	all of their strings into a very long string, to reduce relocation
3055ca44d1cSRong-En Fan	overhead.
3065ca44d1cSRong-En Fan
30718259542SPeter Wemm    --disable-database
30818259542SPeter Wemm	Use only built-in data.  The ncurses libraries normally read terminfo
30918259542SPeter Wemm	and termcap data from disk.  You can configure ncurses to have a
31018259542SPeter Wemm	built-in database, aka "fallback" entries.  Embedded applications may
31139f2269fSPeter Wemm	have no need for an external database.  Some, but not all of the
312aae38d10SBaptiste Daroussin	programs are useful in this configuration, e.g., tset and tput versus
31339f2269fSPeter Wemm	infocmp and tic.
31418259542SPeter Wemm
31573f0a83dSXin LI    --disable-db-install
31673f0a83dSXin LI	Do not install the terminal database.  This is used to omit features
31773f0a83dSXin LI	for packages, as done with --without-progs.
31873f0a83dSXin LI
319aae38d10SBaptiste Daroussin    --disable-echo
320aae38d10SBaptiste Daroussin	Use the option --disable-echo to make the build-log less verbose by
321aae38d10SBaptiste Daroussin	suppressing the display of the compile and link commands.  This makes
322aae38d10SBaptiste Daroussin	it easier to see the compiler warnings.  (You can always use "make -n"
323aae38d10SBaptiste Daroussin	to see the options that are used).
324aae38d10SBaptiste Daroussin
32518259542SPeter Wemm    --disable-ext-funcs
32618259542SPeter Wemm	Disable function-extensions.  Configure ncurses without the functions
32718259542SPeter Wemm	that are not specified by XSI.  See ncurses/modules for the exact
32818259542SPeter Wemm	list of library modules that would be suppressed.
32918259542SPeter Wemm
330aae38d10SBaptiste Daroussin    --disable-gnat-projects
331aae38d10SBaptiste Daroussin	Disable GNAT projects even if usable, for testing old makefile rules.
332aae38d10SBaptiste Daroussin
33318259542SPeter Wemm    --disable-hashmap
33418259542SPeter Wemm	Compile without hashmap scrolling-optimization code.  This algorithm is
33518259542SPeter Wemm	the default.
33618259542SPeter Wemm
3374a1a9510SRong-En Fan    --disable-home-terminfo
3384a1a9510SRong-En Fan	The $HOME/.terminfo directory is normally added to ncurses' search
3394a1a9510SRong-En Fan	list for reading/writing terminfo entries, since that directory is
3404a1a9510SRong-En Fan	more likely writable than the system terminfo database.  Use this
3414a1a9510SRong-En Fan	option to disable the feature altogether.
3424a1a9510SRong-En Fan
3434a1a9510SRong-En Fan    --disable-largefile
3444a1a9510SRong-En Fan	Disable compiler flags needed to use large-file interfaces.
3454a1a9510SRong-En Fan
346aae38d10SBaptiste Daroussin    --disable-leaks
347aae38d10SBaptiste Daroussin	For testing, compile-in code that frees memory that normally would not
348aae38d10SBaptiste Daroussin	be freed, to simplify analysis of memory-leaks.
349aae38d10SBaptiste Daroussin
350aae38d10SBaptiste Daroussin	Any implementation of curses must not free the memory associated with
351aae38d10SBaptiste Daroussin	a screen, since (even after calling endwin()), it must be available
352aae38d10SBaptiste Daroussin	for use in the next call to refresh().  There are also chunks of
353aae38d10SBaptiste Daroussin	memory held for performance reasons.  That makes it hard to analyze
354aae38d10SBaptiste Daroussin	curses applications for memory leaks.  To work around this, build a
355aae38d10SBaptiste Daroussin	debugging version of the ncurses library which frees those chunks
356aae38d10SBaptiste Daroussin	which it can, and provides the _nc_free_and_exit() function to free
357aae38d10SBaptiste Daroussin	the remainder and then exit.  The ncurses utility and test programs
358aae38d10SBaptiste Daroussin	use this feature, e.g., via the ExitProgram() macro.
359aae38d10SBaptiste Daroussin
360aae38d10SBaptiste Daroussin	Because this lies outside of the library's intended usage, it is not
361aae38d10SBaptiste Daroussin	normally considered part of the ABI.  If there were some (as yet
362aae38d10SBaptiste Daroussin	unplanned) extension which frees memory in a manner that would let the
363aae38d10SBaptiste Daroussin	library resume and reallocate memory, then that would not use a "_nc_"
364aae38d10SBaptiste Daroussin	prefix.
365aae38d10SBaptiste Daroussin
366aae38d10SBaptiste Daroussin    --disable-lib-suffixes
367aae38d10SBaptiste Daroussin	Suppress the "w", "t" or "tw" suffixes which normally would be added
368aae38d10SBaptiste Daroussin	to the library names for the --enable-widec and --with-pthread options.
369aae38d10SBaptiste Daroussin
37006bfebdeSXin LI    --disable-libtool-version
37106bfebdeSXin LI	when using --with-libtool, control how the major/minor version numbers
37206bfebdeSXin LI	are used for constructing the library name.
37306bfebdeSXin LI
37406bfebdeSXin LI	The default uses the -version-number feature of libtool, which makes
37506bfebdeSXin LI	the library names compatible (though not identical) with the standard
37606bfebdeSXin LI	build using --with-shared.
37706bfebdeSXin LI
37806bfebdeSXin LI	Use --disable-libtool-version to use the libtool -version-info feature.
37906bfebdeSXin LI	This corresponds to the setting used before patch 20100515.
38006bfebdeSXin LI
381aae38d10SBaptiste Daroussin	Starting with patch 20141115, using this option causes the configure
382aae38d10SBaptiste Daroussin	script to apply the top-level VERSION file to the ABI version used
383aae38d10SBaptiste Daroussin	for libtool.
3845ca44d1cSRong-En Fan
3854a1a9510SRong-En Fan    --disable-lp64
3864a1a9510SRong-En Fan	The header files will ignore use of the _LP64 symbol to make chtype
3874a1a9510SRong-En Fan	and mmask_t types 32 bits (they may be long on 64-bit hosts, for
3884a1a9510SRong-En Fan	compatibility with older releases).
3894a1a9510SRong-En Fan
3904a1a9510SRong-En Fan	NOTE: this is potentially an ABI change, depending on existing
3914a1a9510SRong-En Fan	packages.  The default for this option is "disabled" for ncurses
3924a1a9510SRong-En Fan	ABI 5, and "enabled" for ABI 6.
3934a1a9510SRong-En Fan
39418259542SPeter Wemm    --disable-macros
39518259542SPeter Wemm	For testing, use functions rather than macros.  The program will run
3964a1a9510SRong-En Fan	more slowly, but it is simpler to debug.  This defines NCURSES_NOMACROS
3974a1a9510SRong-En Fan	at build time.  See also the --enable-expanded option.
39818259542SPeter Wemm
39918259542SPeter Wemm    --disable-overwrite
40018259542SPeter Wemm	If you are installing ncurses on a system which contains another
40118259542SPeter Wemm	development version of curses, or which could be confused by the loader
40218259542SPeter Wemm	for another version, we recommend that you leave out the link to
40318259542SPeter Wemm	-lcurses.  The ncurses library is always available as -lncurses.
40418259542SPeter Wemm	Disabling overwrite also causes the ncurses header files to be
40518259542SPeter Wemm	installed into a subdirectory, e.g., /usr/local/include/ncurses,
40618259542SPeter Wemm	rather than the include directory.  This makes it simpler to avoid
40718259542SPeter Wemm	compile-time conflicts with other versions of curses.h
40818259542SPeter Wemm
409aae38d10SBaptiste Daroussin	Putting the header files into a subdirectory assumes that applications
410aae38d10SBaptiste Daroussin	will follow the (standard) practice of including the headers with
411aae38d10SBaptiste Daroussin	reference to the subdirectory name.  For instance, the normal ncurses
412aae38d10SBaptiste Daroussin	header would be included using
413aae38d10SBaptiste Daroussin
414aae38d10SBaptiste Daroussin		#include <ncurses/curses.h>
415aae38d10SBaptiste Daroussin		#include <ncurses/term.h>
416aae38d10SBaptiste Daroussin
417aae38d10SBaptiste Daroussin	while the ncursesw headers would be found this way:
418aae38d10SBaptiste Daroussin
419aae38d10SBaptiste Daroussin		#include <ncursesw/curses.h>
420aae38d10SBaptiste Daroussin		#include <ncursesw/term.h>
421aae38d10SBaptiste Daroussin
422aae38d10SBaptiste Daroussin	In either case (with or without the --disable-overwrite option),
423aae38d10SBaptiste Daroussin	almost all applications are designed to include a related set of
424aae38d10SBaptiste Daroussin	curses header files from the same directory.
425aae38d10SBaptiste Daroussin
426aae38d10SBaptiste Daroussin	Manipulating the --includedir configure option to put header files
427aae38d10SBaptiste Daroussin	directly in a subdirectory of the normal include-directory defeats
428aae38d10SBaptiste Daroussin	this, and breaks builds of portable applications.  Likewise, putting
429aae38d10SBaptiste Daroussin	some headers in /usr/include, and others in a subdirectory is a good
430aae38d10SBaptiste Daroussin	way to break builds.
431aae38d10SBaptiste Daroussin
432aae38d10SBaptiste Daroussin	When configured with --disable-overwrite, the installed header files'
433aae38d10SBaptiste Daroussin	embedded #include's are adjusted to use the same style of includes
434aae38d10SBaptiste Daroussin	noted above.  In particular, the unctrl.h header is included from
435aae38d10SBaptiste Daroussin	curses.h, which means that a makefile which tells the compiler to
436aae38d10SBaptiste Daroussin	include directly from the subdirectory will fail to compile correctly.
437aae38d10SBaptiste Daroussin	Without some special effort, it will either fail to compile at all,
438aae38d10SBaptiste Daroussin	or the compiler may find a different unctrl.h file.
439aae38d10SBaptiste Daroussin
4407a656419SBaptiste Daroussin	In addition to the curses library, a system may provide its own
4417a656419SBaptiste Daroussin	versions of the add-on libraries (form, menu, panel), which would
4427a656419SBaptiste Daroussin	not be compatible with ncurses.  These options allow you to rename
4437a656419SBaptiste Daroussin	ncurses' add-on libraries to avoid conflicts when linking:
4447a656419SBaptiste Daroussin
4457a656419SBaptiste Daroussin		--with-form-libname=XXX
4467a656419SBaptiste Daroussin		--with-menu-libname=XXX
4477a656419SBaptiste Daroussin		--with-panel-libname=XXX
4487a656419SBaptiste Daroussin
449*21817992SBaptiste Daroussin	Rather than renaming them arbitrarily, a prefix or suffix is
4507a656419SBaptiste Daroussin	recommended.  An "n" prefix provides consistency with ncurses versus
4517a656419SBaptiste Daroussin	curses, i.e.,
4527a656419SBaptiste Daroussin
4537a656419SBaptiste Daroussin		--with-form-libname=nform
4547a656419SBaptiste Daroussin		--with-menu-libname=nmenu
4557a656419SBaptiste Daroussin		--with-panel-libname=npanel
4567a656419SBaptiste Daroussin
4577a656419SBaptiste Daroussin    --disable-pkg-ldflags
458*21817992SBaptiste Daroussin	Omit options in $LDFLAGS and $EXTRA_LDFLAGS from the pkg-config ".pc"
459*21817992SBaptiste Daroussin	and corresponding ncurses*-config script which normally are listed via
4607a656419SBaptiste Daroussin	the "--libs" option.  These options are normally used to facilitate
4617a656419SBaptiste Daroussin	linking to ncurses when it was configured to use the rpath feature.
4627a656419SBaptiste Daroussin
4637a656419SBaptiste Daroussin	See also --enable-rpath and --disable-rpath-hack.
4647a656419SBaptiste Daroussin
4655ca44d1cSRong-En Fan    --disable-relink
4665ca44d1cSRong-En Fan	If --enable-rpath is given, the generated makefiles normally will
467aae38d10SBaptiste Daroussin	rebuild shared libraries during install.  Use this option to simply
468aae38d10SBaptiste Daroussin	copy whatever the linker produced.
4695ca44d1cSRong-En Fan
470aae38d10SBaptiste Daroussin	Static libraries cannot simply be copied because tools use timestamps
471aae38d10SBaptiste Daroussin	to determine if the library's symbol table is up to date.  If your
472aae38d10SBaptiste Daroussin	install program supports the "-p" (preserve timestamp) option, that
473aae38d10SBaptiste Daroussin	is used when --disable-relink is given, to avoid rebuilding the symbol
474aae38d10SBaptiste Daroussin	table.
475aae38d10SBaptiste Daroussin
476aae38d10SBaptiste Daroussin	Finally, some tools ignore the subsecond timestamps supported by some
477aae38d10SBaptiste Daroussin	filesystems.  This option adds a 1-second sleep to help those tools
478aae38d10SBaptiste Daroussin	avoid unnecessary relinking during the install process.
4795ca44d1cSRong-En Fan
480*21817992SBaptiste Daroussin    --disable-root-access
481*21817992SBaptiste Daroussin	Compile with environment restriction, so most file-access is limited
482*21817992SBaptiste Daroussin	when running as root, or via a setuid/setgid application.
483*21817992SBaptiste Daroussin
48418259542SPeter Wemm    --disable-root-environ
48518259542SPeter Wemm	Compile with environment restriction, so certain environment variables
486*21817992SBaptiste Daroussin	are not available when running as root.  These are (for example
487*21817992SBaptiste Daroussin	$TERMINFO) those that allow the search path for the terminfo or termcap
488*21817992SBaptiste Daroussin	entry to be customized.
489*21817992SBaptiste Daroussin
490*21817992SBaptiste Daroussin	Disabling the root environment variables also disables the setuid
491*21817992SBaptiste Daroussin	environment variables by default.  Use the --disable-setuid-environ
492*21817992SBaptiste Daroussin	option to modify this behavior.
49318259542SPeter Wemm
49406bfebdeSXin LI    --disable-rpath-hack
49506bfebdeSXin LI	Normally the configure script helps link libraries found in unusual
49606bfebdeSXin LI	places by adding an rpath option to the link command.  If you are
49706bfebdeSXin LI	building packages, this feature may be redundant.  Use this option
49806bfebdeSXin LI	to suppress the feature.
49906bfebdeSXin LI
50018259542SPeter Wemm    --disable-scroll-hints
50118259542SPeter Wemm	Compile without scroll-hints code.  This option is ignored when
50218259542SPeter Wemm	hashmap scrolling is configured, which is the default.
50318259542SPeter Wemm
504aae38d10SBaptiste Daroussin    --disable-stripping
505aae38d10SBaptiste Daroussin	Do not strip installed executables.
506aae38d10SBaptiste Daroussin
507*21817992SBaptiste Daroussin    --disable-setuid-environ
508*21817992SBaptiste Daroussin	Compile with environment restriction, so certain environment variables
509*21817992SBaptiste Daroussin	are not available when running via a setuid/setgid application.  These
510*21817992SBaptiste Daroussin	are (for example $TERMINFO) those that allow the search path for the
511*21817992SBaptiste Daroussin	terminfo or termcap entry to be customized.
512*21817992SBaptiste Daroussin
513*21817992SBaptiste Daroussin	A setuid/setgid application inherits its environment variables from
514*21817992SBaptiste Daroussin	the current user, in contrast to sudo which may limit the environment
515*21817992SBaptiste Daroussin	variables that ncurses uses.
516*21817992SBaptiste Daroussin
5175d08fb1fSRong-En Fan    --disable-tic-depends
5185d08fb1fSRong-En Fan	When building shared libraries, normally the tic library is linked to
51973f0a83dSXin LI	depend upon the ncurses library (or equivalently, on the tinfo-library
52073f0a83dSXin LI	if the --with-termlib option was given).  The tic- and tinfo-library
52173f0a83dSXin LI	ABIs do not depend on the --enable-widec option.  Some packagers have
52273f0a83dSXin LI	used this to reduce the number of library files which are packaged by
52373f0a83dSXin LI	using only one copy of those libraries.  To make this work properly,
5245d08fb1fSRong-En Fan	the tic library must be built without an explicit dependency on the
52573f0a83dSXin LI	underlying library (ncurses vs ncursesw, tinfo vs tinfow).  Use this
52673f0a83dSXin LI	configure option to do that.
5275d08fb1fSRong-En Fan	For example
5285d08fb1fSRong-En Fan		configure --with-ticlib --with-shared --disable-tic-depends
5295d08fb1fSRong-En Fan
5304a1a9510SRong-En Fan    --disable-tparm-varargs
5314a1a9510SRong-En Fan	Portable programs should call tparm() using the fixed-length parameter
5324a1a9510SRong-En Fan	list documented in X/Open.  ncurses provides varargs support for this
5334a1a9510SRong-En Fan	function.  Use --disable-tparm-varargs to disable this support.
53418259542SPeter Wemm
53518259542SPeter Wemm    --enable-assertions
53618259542SPeter Wemm	For testing, compile-in assertion code.  This is used only for a few
53718259542SPeter Wemm	places where ncurses cannot easily recover by returning an error code.
53818259542SPeter Wemm
53918259542SPeter Wemm    --enable-broken_linker
54018259542SPeter Wemm	A few platforms have what we consider a broken linker:  it cannot link
54118259542SPeter Wemm	objects from an archive solely by referring to data objects in those
54218259542SPeter Wemm	files, but requires a function reference.  This configure option
54318259542SPeter Wemm	changes several data references to functions to work around this
54418259542SPeter Wemm	problem.
54518259542SPeter Wemm
54618259542SPeter Wemm	NOTE: With ncurses 5.1, this may not be necessary, since we are
54718259542SPeter Wemm	told that some linkers interpret uninitialized global data as a
54818259542SPeter Wemm	different type of reference which behaves as described above.  We have
54918259542SPeter Wemm	explicitly initialized all of the global data to work around the
55018259542SPeter Wemm	problem.
55118259542SPeter Wemm
55218259542SPeter Wemm    --enable-bsdpad
55318259542SPeter Wemm	Recognize BSD-style prefix padding.  Some ancient BSD programs (such as
55418259542SPeter Wemm	nethack) call tputs("50") to implement delays.
55518259542SPeter Wemm
556*21817992SBaptiste Daroussin    --enable-check-size
557*21817992SBaptiste Daroussin	Compile-in feature to detect screensize for terminals which do not
558*21817992SBaptiste Daroussin	advertise their screensize, e.g., serial terminals.
559*21817992SBaptiste Daroussin
56018259542SPeter Wemm    --enable-colorfgbg
56118259542SPeter Wemm	Compile with experimental $COLORFGBG code.  That environment variable
56218259542SPeter Wemm	is set by some terminal emulators as a hint to applications, by
56318259542SPeter Wemm	advertising the default foreground and background colors.  During
56418259542SPeter Wemm	initialization, ncurses sets color pair 0 to match this.
56518259542SPeter Wemm
56618259542SPeter Wemm    --enable-const
56718259542SPeter Wemm	The curses interface as documented in XSI is rather old, in fact
56818259542SPeter Wemm	including features that precede ANSI C.  The prototypes generally do
56918259542SPeter Wemm	not make effective use of "const".  When using stricter compilers (or
57018259542SPeter Wemm	gcc with appropriate warnings), you may see warnings about the mismatch
57118259542SPeter Wemm	between const and non-const data.  We provide a configure option which
57218259542SPeter Wemm	changes the interfaces to use const - quieting these warnings and
57318259542SPeter Wemm	reflecting the actual use of the parameters more closely.  The ncurses
57418259542SPeter Wemm	library uses the symbol NCURSES_CONST for these instances of const,
57518259542SPeter Wemm	and if you have asked for compiler warnings, will add gcc's const-qual
57618259542SPeter Wemm	warning.  There will still be warnings due to subtle inconsistencies
57718259542SPeter Wemm	in the interface, but at a lower level.
57818259542SPeter Wemm
57918259542SPeter Wemm	NOTE: configuring ncurses with this option may detract from the
58018259542SPeter Wemm	portability of your applications by encouraging you to use const in
58118259542SPeter Wemm	places where the XSI curses interface would not allow them.  Similar
58218259542SPeter Wemm	issues arise when porting to SVr4 curses, which uses const in even
58318259542SPeter Wemm	fewer places.
58418259542SPeter Wemm
58518259542SPeter Wemm    --enable-expanded
58618259542SPeter Wemm	For testing, generate functions for certain macros to make them visible
58718259542SPeter Wemm	as such to the debugger.  See also the --disable-macros option.
58818259542SPeter Wemm
5897a656419SBaptiste Daroussin    --enable-exp-win32
5907a656419SBaptiste Daroussin	When configuring for MinGW, use the experimental Windows 10 driver.
5917a656419SBaptiste Daroussin
5924a1a9510SRong-En Fan    --enable-ext-colors
5934a1a9510SRong-En Fan	Extend the cchar_t structure to allow more than 16 colors to be
5944a1a9510SRong-En Fan	encoded.  This applies only to the wide-character (--enable-widec)
5954a1a9510SRong-En Fan	configuration.
5964a1a9510SRong-En Fan
5974a1a9510SRong-En Fan	NOTE: using this option will make libraries which are not binary-
5984a1a9510SRong-En Fan	compatible with libncursesw 5.4.  None of the interfaces change, but
5994a1a9510SRong-En Fan	applications which have an array of cchar_t's must be recompiled.
6004a1a9510SRong-En Fan
6014a1a9510SRong-En Fan    --enable-ext-mouse
6024a1a9510SRong-En Fan	Modify the encoding of mouse state to make room for a 5th mouse button.
6034a1a9510SRong-En Fan	That allows one to use ncurses with a wheel mouse with xterm or
6044a1a9510SRong-En Fan	similar X terminal emulators.
6054a1a9510SRong-En Fan
6064a1a9510SRong-En Fan	NOTE: using this option will make libraries which are not binary-
6074a1a9510SRong-En Fan	compatible with libncursesw 5.4.  None of the interfaces change, but
6084a1a9510SRong-En Fan	applications which have mouse mask mmask_t's must be recompiled.
6094a1a9510SRong-En Fan
610aae38d10SBaptiste Daroussin    --enable-ext-putwin
611aae38d10SBaptiste Daroussin	Modify the file-format written by putwin() to use printable text rather
612aae38d10SBaptiste Daroussin	than binary files, allowing getwin() to read screen dumps written by
613aae38d10SBaptiste Daroussin	differently-configured ncurses libraries.  The extended getwin() can
614aae38d10SBaptiste Daroussin	still read binary screen dumps from the "same" configuration of
615aae38d10SBaptiste Daroussin	ncurses.  This does not change the ABI (the binary interface seen by
616aae38d10SBaptiste Daroussin	calling applications).
617aae38d10SBaptiste Daroussin
6187a656419SBaptiste Daroussin    --enable-fvisibility
6197a656419SBaptiste Daroussin    	Use the gcc "-fvisibility=hidden" option to make symbols which are not
6207a656419SBaptiste Daroussin	explicitly exported, "hidden".  Doing this may reduce the number of
6217a656419SBaptiste Daroussin	symbols exported in the C++ binding; it should have less effect on the
6227a656419SBaptiste Daroussin	C libraries when symbol-versioning is used.
6237a656419SBaptiste Daroussin
62418259542SPeter Wemm    --enable-getcap
62518259542SPeter Wemm	Use the 4.4BSD getcap code if available, or a bundled version of it to
62618259542SPeter Wemm	fetch termcap entries.  Entries read in this way cannot use (make
62718259542SPeter Wemm	cross-references to) the terminfo tree, but it is faster than reading
62818259542SPeter Wemm	/etc/termcap.
62918259542SPeter Wemm
6304a1a9510SRong-En Fan	If configured for one of the *BSD systems, this automatically uses
6314a1a9510SRong-En Fan	the hashed database system produced using cap_mkdb or similar tools.
6324a1a9510SRong-En Fan	In that case, there is no advantage in using the --enable-getcap-cache
6334a1a9510SRong-En Fan	option.
6344a1a9510SRong-En Fan
6354a1a9510SRong-En Fan	See also the --with-hashed-db option.
6364a1a9510SRong-En Fan
63718259542SPeter Wemm    --enable-getcap-cache
63818259542SPeter Wemm	Cache translated termcaps under the directory $HOME/.terminfo
63918259542SPeter Wemm
64018259542SPeter Wemm	NOTE: this sounds good - it makes ncurses run faster the second time.
64118259542SPeter Wemm	But look where the data comes from - an /etc/termcap containing lots of
64218259542SPeter Wemm	entries that are not up to date.  If you configure with this option and
64318259542SPeter Wemm	forget to install the terminfo database before running an ncurses
64418259542SPeter Wemm	application, you will end up with a hidden terminfo database that
64518259542SPeter Wemm	generally does not support color and will miss some function keys.
64618259542SPeter Wemm
64718259542SPeter Wemm    --enable-hard-tabs
64818259542SPeter Wemm	Compile-in cursor-optimization code that uses hard-tabs.  We would make
64918259542SPeter Wemm	this a standard feature except for the concern that the terminfo entry
65018259542SPeter Wemm	may not be accurate, or that your stty settings have disabled the use
65118259542SPeter Wemm	of tabs.
65218259542SPeter Wemm
65306bfebdeSXin LI    --enable-interop
65406bfebdeSXin LI	Compile-in experimental interop bindings.  These provide generic types
65506bfebdeSXin LI	for the form-library.
65606bfebdeSXin LI
6575ca44d1cSRong-En Fan    --enable-mixed-case
6585ca44d1cSRong-En Fan	Controls whether the filesystem on which the terminfo database resides
6595ca44d1cSRong-En Fan	supports mixed-case filenames (normal for UNIX, but not on other
6605ca44d1cSRong-En Fan	systems).  If you do not specify this option, the configure script
6615ca44d1cSRong-En Fan	checks the current filesystem.
6625ca44d1cSRong-En Fan
66318259542SPeter Wemm    --enable-no-padding
66418259542SPeter Wemm	Compile-in support for the $NCURSES_NO_PADDING environment variable,
66518259542SPeter Wemm	which allows you to suppress the effect of non-mandatory padding in
66618259542SPeter Wemm	terminfo entries.  This is the default, unless you have disabled the
66718259542SPeter Wemm	extended functions.
66818259542SPeter Wemm
669aae38d10SBaptiste Daroussin    --enable-opaque-curses
670aae38d10SBaptiste Daroussin    --enable-opaque-form
671aae38d10SBaptiste Daroussin    --enable-opaque-menu
672aae38d10SBaptiste Daroussin    --enable-opaque-panel
673*21817992SBaptiste Daroussin	Define symbol in curses.h controlling whether some library structures
674*21817992SBaptiste Daroussin	are opaque, meaning that their members are accessible only via the
675*21817992SBaptiste Daroussin	documented API.  The --enable-opaque-curses option may be overridden
676*21817992SBaptiste Daroussin	by the --enable-reentrant option.
677*21817992SBaptiste Daroussin
678*21817992SBaptiste Daroussin	Enabling opaque-curses enables opaque for the form, menu, and panel
679*21817992SBaptiste Daroussin	libraries.  Use their corresponding options to disable the feature
680*21817992SBaptiste Daroussin	individually.
681*21817992SBaptiste Daroussin
682*21817992SBaptiste Daroussin	NOTE: beginning with ncurses 6.5 this option is enabled by default;
683*21817992SBaptiste Daroussin	older versions disable it by default.
684aae38d10SBaptiste Daroussin
68506bfebdeSXin LI    --enable-pc-files
68606bfebdeSXin LI	If pkg-config is found (see --with-pkg-config), generate ".pc" files
68706bfebdeSXin LI	for each of the libraries, and install them in pkg-config's library
68806bfebdeSXin LI	directory.
68906bfebdeSXin LI
69006bfebdeSXin LI    --enable-pthreads-eintr
69106bfebdeSXin LI	add logic in threaded configuration to ensure that a read(2) system
69206bfebdeSXin LI	call can be interrupted for SIGWINCH.
69306bfebdeSXin LI
6945ca44d1cSRong-En Fan    --enable-reentrant
695aae38d10SBaptiste Daroussin	Compile configuration which improves reentrant use of the library by
696aae38d10SBaptiste Daroussin	reducing global and static variables.  This option is also set if
697aae38d10SBaptiste Daroussin	--with-pthread is used.
6985ca44d1cSRong-En Fan
69973f0a83dSXin LI	Enabling this option adds a "t" to the library names, except for the
70073f0a83dSXin LI	special case when --enable-weak-symbols is also used.
70173f0a83dSXin LI
70218259542SPeter Wemm    --enable-rpath
7034a1a9510SRong-En Fan	Use rpath option when generating shared libraries, and (with some
7044a1a9510SRong-En Fan	restrictions) when linking the corresponding programs.  This originally
7054a1a9510SRong-En Fan	(in 1997) applied mainly to systems using the GNU linker (read the
7064a1a9510SRong-En Fan	manpage).
7074a1a9510SRong-En Fan
7084a1a9510SRong-En Fan	More recently it is useful for systems that require special treatment
7094a1a9510SRong-En Fan	shared libraries in "unusual" locations.  The "system" libraries reside
7104a1a9510SRong-En Fan	in directories which are on the loader's default search-path.  While
7114a1a9510SRong-En Fan	you may be able to use workarounds such as the $LD_LIBRARY_PATH
7124a1a9510SRong-En Fan	environment variable, they do not work with setuid applications since
7134a1a9510SRong-En Fan	the LD_LIBRARY_PATH variable would be unset in that situation.
71418259542SPeter Wemm
7155ca44d1cSRong-En Fan	This option does not apply to --with-libtool, since libtool makes
7165ca44d1cSRong-En Fan	extra assumptions about rpath.
7175ca44d1cSRong-En Fan
71818259542SPeter Wemm    --enable-safe-sprintf
71918259542SPeter Wemm	Compile with experimental safe-sprintf code.  You may consider using
72018259542SPeter Wemm	this if you are building ncurses for a system that has neither
721aae38d10SBaptiste Daroussin	vsnprintf() or vsprintf().  It is slow, however, and is used only on
722aae38d10SBaptiste Daroussin	very old systems which lack vsnprintf().
72318259542SPeter Wemm
7244a1a9510SRong-En Fan    --enable-signed-char
7254a1a9510SRong-En Fan	The term.h header declares a Booleans[] array typed "char".  But it
7264a1a9510SRong-En Fan	stores signed values there and "char" is not necessarily signed.
7274a1a9510SRong-En Fan	Some packagers choose to alter the type of Booleans[] though this
7284a1a9510SRong-En Fan	is not strictly compatible.  This option allows one to implement this
7294a1a9510SRong-En Fan	alteration without patching the source code.
7304a1a9510SRong-En Fan
731aae38d10SBaptiste Daroussin    --enable-sigwinch
732aae38d10SBaptiste Daroussin	Compile support for ncurses' SIGWINCH handler.  If your application has
733aae38d10SBaptiste Daroussin	its own SIGWINCH handler, ncurses will not use its own.  The ncurses
734aae38d10SBaptiste Daroussin	handler causes wgetch() to return KEY_RESIZE when the screen-size
735aae38d10SBaptiste Daroussin	changes.  This option is the default, unless you have disabled the
736aae38d10SBaptiste Daroussin	extended functions.
737aae38d10SBaptiste Daroussin
73806bfebdeSXin LI    --enable-sp-funcs
73906bfebdeSXin LI	Compile-in support for extended functions which accept a SCREEN pointer,
74006bfebdeSXin LI	reducing the need for juggling the global SP value with set_term() and
74106bfebdeSXin LI	delscreen().
74206bfebdeSXin LI
743*21817992SBaptiste Daroussin    --enable-stdnoreturn
744*21817992SBaptiste Daroussin	When enabled, check if the <stdnoreturn.h> header exists, and if found
745*21817992SBaptiste Daroussin	define GCC_NORETURN to _Noreturn rather than either the gcc-specific
746*21817992SBaptiste Daroussin	__attribute__((noreturn)) or an empty token.  Doing this may require
747*21817992SBaptiste Daroussin	calling programs which use GCC_NORETURN in their own function
748*21817992SBaptiste Daroussin	definitions to be modified, because _Noreturn is only accepted as
749*21817992SBaptiste Daroussin	the first token in a declaration.
750*21817992SBaptiste Daroussin
75173f0a83dSXin LI    --enable-string-hacks
75273f0a83dSXin LI	Controls whether strlcat and strlcpy may be used.  The same issue
75373f0a83dSXin LI	applies to OpenBSD's warnings about snprintf, noting that this function
75473f0a83dSXin LI	is weakly standardized.
75573f0a83dSXin LI
75673f0a83dSXin LI	Aside from stifling these warnings, there is no functional improvement
75773f0a83dSXin LI	in ncurses.
75873f0a83dSXin LI
75918259542SPeter Wemm    --enable-symlinks
76018259542SPeter Wemm	If your system supports symbolic links, make tic use symbolic links
76118259542SPeter Wemm	rather than hard links to save diskspace when writing aliases in the
76218259542SPeter Wemm	terminfo database.
76318259542SPeter Wemm
76418259542SPeter Wemm    --enable-tcap-names
76518259542SPeter Wemm	Compile-in support for user-definable terminal capabilities.  Use the
76618259542SPeter Wemm	-x option of tic and infocmp to treat unrecognized terminal
76718259542SPeter Wemm	capabilities as user-defined strings.  This option is the default,
76818259542SPeter Wemm	unless you have disabled the extended functions.
76918259542SPeter Wemm
77006bfebdeSXin LI    --enable-term-driver
77106bfebdeSXin LI	Enable experimental terminal-driver.  This is currently used for the
77206bfebdeSXin LI	MinGW port, by providing a way to substitute the low-level terminfo
77306bfebdeSXin LI	library with different terminal drivers.
77406bfebdeSXin LI
77518259542SPeter Wemm    --enable-termcap
77618259542SPeter Wemm	Compile in support for reading terminal descriptions from termcap if no
77718259542SPeter Wemm	match is found in the terminfo database.  See also the --enable-getcap
77818259542SPeter Wemm	and --enable-getcap-cache options.
77918259542SPeter Wemm
78073f0a83dSXin LI	Termcap support requires run-time parsing rather than loading
78173f0a83dSXin LI	predigested data.  If you have specified --with-ticlib, then you
78273f0a83dSXin LI	cannot have termcap support since run-time parsing is done in the
78373f0a83dSXin LI	tic library, which is intentionally not part of normal linkage
78473f0a83dSXin LI	dependencies.
78573f0a83dSXin LI
78618259542SPeter Wemm    --enable-warnings
78718259542SPeter Wemm	Turn on GCC compiler warnings.  There should be only a few.
78818259542SPeter Wemm
789*21817992SBaptiste Daroussin    --enable-wattr-macros
790*21817992SBaptiste Daroussin	The 6.0 ABI adds support for extended colors and for extended mouse.
791*21817992SBaptiste Daroussin	The former is a noticeable problem when developers inadvertently
792*21817992SBaptiste Daroussin	compile using the ncurses6 header files and link with an ncurses5
793*21817992SBaptiste Daroussin	library, because the wattr* macros use a new field in the WINDOW
794*21817992SBaptiste Daroussin	structure.  These macros are used in several applications.
795*21817992SBaptiste Daroussin
796*21817992SBaptiste Daroussin	Since ncurses provides an actual function for each of these macros,
797*21817992SBaptiste Daroussin	suppressing them from the curses.h header allows the ncurses5 libraries
798*21817992SBaptiste Daroussin	to be used in most applications.
799*21817992SBaptiste Daroussin
800*21817992SBaptiste Daroussin	NOTE: The extended colors also are used in the cchar_t structure, but
801*21817992SBaptiste Daroussin	fewer applications use that.
802*21817992SBaptiste Daroussin
803*21817992SBaptiste Daroussin	NOTE: This workaround does not help with mismatches in the ncurses
804*21817992SBaptiste Daroussin	mouse version.  The extended mouse feature uses one less fewer bit for
805*21817992SBaptiste Daroussin	each button, so that only the first button will work as expected with
806*21817992SBaptiste Daroussin	a mismatch between header and library.  Again, most applications will
807*21817992SBaptiste Daroussin	work, since most use only the first button.
808*21817992SBaptiste Daroussin
8095d08fb1fSRong-En Fan    --enable-weak-symbols
8105d08fb1fSRong-En Fan	If the --with-pthread option is set, check if the compiler supports
8115d08fb1fSRong-En Fan	weak-symbols.  If it does, then name the thread-capable library without
8125d08fb1fSRong-En Fan	the "t" (libncurses rather than libncursest), and provide for
8135d08fb1fSRong-En Fan	dynamically loading the pthreads entrypoints at runtime.  This allows
8145d08fb1fSRong-En Fan	one to reduce the number of library files for ncurses.
8155d08fb1fSRong-En Fan
8164a1a9510SRong-En Fan    --enable-wgetch-events
8174a1a9510SRong-En Fan	Compile with experimental wgetch-events code.  See ncurses/README.IZ
8184a1a9510SRong-En Fan
81918259542SPeter Wemm    --enable-widec
8204a1a9510SRong-En Fan	Compile with wide-character code.  This makes a different version of
8214a1a9510SRong-En Fan	the libraries (e.g., libncursesw.so), which stores characters as
8224a1a9510SRong-En Fan	wide-characters,
82318259542SPeter Wemm
82418259542SPeter Wemm	NOTE: applications compiled with this configuration are not compatible
82518259542SPeter Wemm	with those built for 8-bit characters.  You cannot simply make a
82618259542SPeter Wemm	symbolic link to equate libncurses.so with libncursesw.so
82718259542SPeter Wemm
8284a1a9510SRong-En Fan	NOTE: the Ada95 binding may be built against either version of the the
8294a1a9510SRong-En Fan	ncurses library, but you must decide which: the binding installs the
830*21817992SBaptiste Daroussin	same set of files for either version.  Currently (2023/10/21) it does
8314a1a9510SRong-En Fan	not use the extended features from the wide-character code, so it is
8324a1a9510SRong-En Fan	probably better to not install the binding for that configuration.
8334a1a9510SRong-En Fan
834*21817992SBaptiste Daroussin	NOTE: beginning with ncurses 6.5 this option is enabled by default;
835*21817992SBaptiste Daroussin	older versions disable it by default.
836*21817992SBaptiste Daroussin
83718259542SPeter Wemm    --enable-xmc-glitch
83818259542SPeter Wemm	Compile-in support experimental xmc (magic cookie) code.
83918259542SPeter Wemm
840*21817992SBaptiste Daroussin    --with-abi-altered=NUM
841*21817992SBaptiste Daroussin	Override the displayed (rather than compiled-in) ABI.  Only packagers
842*21817992SBaptiste Daroussin	who have created configurations where the ABI differs from ncurses
843*21817992SBaptiste Daroussin	should be interested in this option.
844*21817992SBaptiste Daroussin
8454a1a9510SRong-En Fan    --with-abi-version=NUM
8464a1a9510SRong-En Fan	Override the ABI version, which is used in shared library filenames.
8474a1a9510SRong-En Fan	Normally this is the same as the release version; some ports have
8484a1a9510SRong-En Fan	special requirements for compatibility.
8494a1a9510SRong-En Fan
8505d08fb1fSRong-En Fan	This option does not affect linking with libtool, which uses the
8515d08fb1fSRong-En Fan	release major/minor numbers.
8525d08fb1fSRong-En Fan
85318259542SPeter Wemm    --with-ada-compiler=CMD
85418259542SPeter Wemm	Specify the Ada95 compiler command (default "gnatmake")
85518259542SPeter Wemm
85618259542SPeter Wemm    --with-ada-include=DIR
85718259542SPeter Wemm	Tell where to install the Ada includes (default:
85818259542SPeter Wemm	PREFIX/lib/ada/adainclude)
85918259542SPeter Wemm
860aae38d10SBaptiste Daroussin    --with-ada-libname=NAME
861aae38d10SBaptiste Daroussin	Override the name of the Ada binding (default: "AdaCurses")
862aae38d10SBaptiste Daroussin
86318259542SPeter Wemm    --with-ada-objects=DIR
86418259542SPeter Wemm	Tell where to install the Ada objects (default:  PREFIX/lib/ada/adalib)
86518259542SPeter Wemm
86606bfebdeSXin LI    --with-ada-sharedlib
86706bfebdeSXin LI	Build a shared library for Ada95 binding, if the compiler permits.
86806bfebdeSXin LI
86906bfebdeSXin LI	NOTE: You must also set the --with-shared option on some platforms
87006bfebdeSXin LI	for a successful build.  You need not use this option when you set
87106bfebdeSXin LI	--with-shared, unless you want to use the Ada shared library.
87206bfebdeSXin LI
87339f2269fSPeter Wemm    --with-bool=TYPE
87439f2269fSPeter Wemm	If --without-cxx is specified, override the type used for the "bool"
87539f2269fSPeter Wemm	declared in curses.h (normally the type is automatically chosen to
87639f2269fSPeter Wemm	correspond with that in <stdbool.h>, or defaults to platform-specific
87739f2269fSPeter Wemm	sizes).
87839f2269fSPeter Wemm
87939f2269fSPeter Wemm    --with-build-cc=XXX
88039f2269fSPeter Wemm	If cross-compiling, specify a host C compiler, which is needed to
8814a1a9510SRong-En Fan	compile a few utilities which generate source modules for ncurses.
88239f2269fSPeter Wemm	If you do not give this option, the configure script checks if the
88339f2269fSPeter Wemm	$BUILD_CC variable is set, and otherwise defaults to gcc or cc.
88439f2269fSPeter Wemm
88539f2269fSPeter Wemm    --with-build-cflags=XXX
88639f2269fSPeter Wemm	If cross-compiling, specify the host C compiler-flags.  You might need
88739f2269fSPeter Wemm	to do this if the target compiler has unusual flags which confuse the
88839f2269fSPeter Wemm	host compiler.
88939f2269fSPeter Wemm
8905d08fb1fSRong-En Fan	You can also set the environment variable $BUILD_CFLAGS rather than
8915d08fb1fSRong-En Fan	use this option.
8925d08fb1fSRong-En Fan
893aae38d10SBaptiste Daroussin    --with-build-cpp=XXX
894aae38d10SBaptiste Daroussin	This option is provided by the same macro used for $BUILD_CC, etc.,
895aae38d10SBaptiste Daroussin	but is not directly used by ncurses.
896aae38d10SBaptiste Daroussin
8974a1a9510SRong-En Fan    --with-build-cppflags=XXX
8984a1a9510SRong-En Fan	If cross-compiling, specify the host C preprocessor-flags.  You might
8994a1a9510SRong-En Fan	need to do this if the target compiler has unusual flags which confuse
9004a1a9510SRong-En Fan	the host compiler.
9014a1a9510SRong-En Fan
9025d08fb1fSRong-En Fan	You can also set the environment variable $BUILD_CPPFLAGS rather than
9035d08fb1fSRong-En Fan	use this option.
9045d08fb1fSRong-En Fan
90539f2269fSPeter Wemm    --with-build-ldflags=XXX
90639f2269fSPeter Wemm	If cross-compiling, specify the host linker-flags.  You might need to
90739f2269fSPeter Wemm	do this if the target linker has unusual flags which confuse the host
90839f2269fSPeter Wemm	compiler.
90939f2269fSPeter Wemm
9105d08fb1fSRong-En Fan	You can also set the environment variable $BUILD_LDFLAGS rather than
9115d08fb1fSRong-En Fan	use this option.
9125d08fb1fSRong-En Fan
91339f2269fSPeter Wemm    --with-build-libs=XXX
91439f2269fSPeter Wemm	If cross-compiling, the host libraries.  You might need to do this if
91539f2269fSPeter Wemm	the target environment requires unusual libraries.
91639f2269fSPeter Wemm
9175d08fb1fSRong-En Fan	You can also set the environment variable $BUILD_LIBS rather than
9185d08fb1fSRong-En Fan	use this option.
9195d08fb1fSRong-En Fan
92039f2269fSPeter Wemm    --with-caps=XXX
92139f2269fSPeter Wemm	Specify an alternate terminfo capabilities file, which makes the
92239f2269fSPeter Wemm	configure script look for "include/Caps.XXX".  A few systems, e.g.,
92339f2269fSPeter Wemm	AIX 4.x use the same overall file-format as ncurses for terminfo
92439f2269fSPeter Wemm	data, but use different alignments within the tables to support
92539f2269fSPeter Wemm	legacy applications.  For those systems, you can configure ncurses
92639f2269fSPeter Wemm	to use a terminfo database which is compatible with the native
92739f2269fSPeter Wemm	applications.
92839f2269fSPeter Wemm
92906bfebdeSXin LI    --with-ccharw-max=XXX
93006bfebdeSXin LI	Override the size of the wide-character array in cchar_t structures.
93106bfebdeSXin LI	Changing this will alter the binary interface.  This defaults to 5.
93206bfebdeSXin LI
9334a1a9510SRong-En Fan    --with-chtype=TYPE
9344a1a9510SRong-En Fan	Override type of chtype, which stores the video attributes and (if
9354a1a9510SRong-En Fan	--enable-widec is not given) a character.  Prior to ncurses 5.5, this
9364a1a9510SRong-En Fan	was always unsigned long, but with ncurses 5.5, it may be unsigned.
9374a1a9510SRong-En Fan	Use this option if you need to preserve compatibility with 64-bit
93806bfebdeSXin LI	executables, e.g., by setting "--with-chtype=long" (the configure
93906bfebdeSXin LI	script supplies "unsigned").
9404a1a9510SRong-En Fan
941aae38d10SBaptiste Daroussin    --with-config-suffix=XXX
942*21817992SBaptiste Daroussin	Specify an suffix for "ncurses*" in the ncurses*-config filename to
943*21817992SBaptiste Daroussin	work around conflicts with packages.  The suffix is placed before the
944*21817992SBaptiste Daroussin	dash.
945aae38d10SBaptiste Daroussin
9467a656419SBaptiste Daroussin    --with-cxx-libname=NAME
9477a656419SBaptiste Daroussin	Override the basename of the ncurses++ library (default: "ncurses++")
9487a656419SBaptiste Daroussin
94973f0a83dSXin LI    --with-cxx-shared
95073f0a83dSXin LI	When --with-shared is set, build libncurses++ as a shared library.
95173f0a83dSXin LI	This implicitly relies upon building with gcc/g++, since other
95273f0a83dSXin LI	compiler suites may have differences in the way shared libraries are
95373f0a83dSXin LI	built.  libtool by the way has similar limitations.
95473f0a83dSXin LI
95518259542SPeter Wemm    --with-database=XXX
95618259542SPeter Wemm	Specify the terminfo source file to install.  Usually you will wish
95718259542SPeter Wemm	to install ncurses' default (misc/terminfo.src).  Certain systems
95818259542SPeter Wemm	have special requirements, e.g, OS/2 EMX has a customized terminfo
95918259542SPeter Wemm	source file.
96018259542SPeter Wemm
96118259542SPeter Wemm    --with-dbmalloc
96218259542SPeter Wemm	For testing, compile and link with Conor Cahill's dbmalloc library.
9634a1a9510SRong-En Fan	This also sets the --disable-leaks option.
96418259542SPeter Wemm
96518259542SPeter Wemm    --with-debug
96618259542SPeter Wemm	Generate debug-libraries (default).  These are named by adding "_g"
96718259542SPeter Wemm	to the root, e.g., libncurses_g.a
96818259542SPeter Wemm
96918259542SPeter Wemm    --with-default-terminfo-dir=XXX
97018259542SPeter Wemm	Specify the default terminfo database directory.  This is normally
97118259542SPeter Wemm	DATADIR/terminfo, e.g., /usr/share/terminfo.
97218259542SPeter Wemm
97318259542SPeter Wemm    --with-dmalloc
97418259542SPeter Wemm	For testing, compile and link with Gray Watson's dmalloc library.
9754a1a9510SRong-En Fan	This also sets the --disable-leaks option.
97618259542SPeter Wemm
977aae38d10SBaptiste Daroussin    --with-export-syms[=XXX]
978aae38d10SBaptiste Daroussin	Limit exported symbols using libtool.  The configure script
979aae38d10SBaptiste Daroussin	automatically chooses an appropriate ".sym" file, which lists the
980aae38d10SBaptiste Daroussin	symbols which are part of the ABI.
981aae38d10SBaptiste Daroussin
982aae38d10SBaptiste Daroussin    --with-extra-suffix[=XXX]
983aae38d10SBaptiste Daroussin	Add the given suffix to header- and library-names to simplify
984aae38d10SBaptiste Daroussin	installing incompatible ncurses libraries, e.g., those using a
985aae38d10SBaptiste Daroussin	different ABI.  The renaming affects the name of the
986aae38d10SBaptiste Daroussin	include-subdirectory if --disable-overwrite is given.
987aae38d10SBaptiste Daroussin
98818259542SPeter Wemm    --with-fallbacks=XXX
98918259542SPeter Wemm	Specify a list of fallback terminal descriptions which will be
99018259542SPeter Wemm	compiled into the ncurses library.  See CONFIGURING FALLBACK ENTRIES.
99118259542SPeter Wemm
992aae38d10SBaptiste Daroussin	See also "--with-tic-path" and "--with-infocmp-path".
993aae38d10SBaptiste Daroussin
9947a656419SBaptiste Daroussin    --with-form-libname=NAME
9957a656419SBaptiste Daroussin	Override the basename of the form library (default: "form")
9967a656419SBaptiste Daroussin
99718259542SPeter Wemm    --with-gpm
99818259542SPeter Wemm	use Alessandro Rubini's GPM library to provide mouse support on the
9994a1a9510SRong-En Fan	Linux console.  Prior to ncurses 5.5, this introduced a dependency on
10004a1a9510SRong-En Fan	the GPM library.
10014a1a9510SRong-En Fan
10024a1a9510SRong-En Fan	Currently ncurses uses the dlsym() function to bind to the library at
10034a1a9510SRong-En Fan	runtime, so it is only necessary that the library be present when
10044a1a9510SRong-En Fan	ncurses is built, to obtain the filename (or soname) used in the
10054a1a9510SRong-En Fan	corresponding dlopen() call.  If you give a value for this option,
10064a1a9510SRong-En Fan	e.g.,
10074a1a9510SRong-En Fan
10084a1a9510SRong-En Fan		--with-gpm=$HOME/tmp/test-gpm.so
10094a1a9510SRong-En Fan
10104a1a9510SRong-En Fan	that overrides the configure check for the soname.
10114a1a9510SRong-En Fan
10124a1a9510SRong-En Fan	See also --without-dlsym
10134a1a9510SRong-En Fan
10145ca44d1cSRong-En Fan    --with-hashed-db[=XXX]
10154a1a9510SRong-En Fan	Use a hashed database for storing terminfo data rather than storing
10164a1a9510SRong-En Fan	each compiled entry in a separate binary file within a directory
10174a1a9510SRong-En Fan	tree.
10184a1a9510SRong-En Fan
10195ca44d1cSRong-En Fan	In particular, this uses the Berkeley database 1.8.5 interface, as
10205ca44d1cSRong-En Fan	provided by that and its successors db 2, 3, and 4.  The actual
10215ca44d1cSRong-En Fan	interface is slightly different in the successor versions of the
10225ca44d1cSRong-En Fan	Berkeley database.  The database should have been configured using
10235ca44d1cSRong-En Fan	"--enable-compat185".
10245ca44d1cSRong-En Fan
10254a1a9510SRong-En Fan	If you use this option for configuring ncurses, tic will only be able
10264a1a9510SRong-En Fan	to write entries in the hashed database.  infocmp can still read
10274a1a9510SRong-En Fan	entries from a directory tree as well as reading entries from the
10284a1a9510SRong-En Fan	hashed database.  To do this, infocmp determines whether the $TERMINFO
10294a1a9510SRong-En Fan	variable points to a directory or a file, and reads the directory-tree
10304a1a9510SRong-En Fan	or hashed database respectively.
10314a1a9510SRong-En Fan
10324a1a9510SRong-En Fan	You cannot have a directory containing both hashed-database and
10334a1a9510SRong-En Fan	filesystem-based terminfo entries.
10344a1a9510SRong-En Fan
10355ca44d1cSRong-En Fan	Use the parameter value to give the install-prefix used for the
1036aae38d10SBaptiste Daroussin	database, e.g.,
10375ca44d1cSRong-En Fan		--with-hashed-db=/usr/local/BigBase
10385ca44d1cSRong-En Fan	to find the corresponding include- and lib-directories under the
1039aae38d10SBaptiste Daroussin	given directory.  Alternatively, you can specify a directory leaf
1040aae38d10SBaptiste Daroussin	name, e.g.,
1041aae38d10SBaptiste Daroussin		--with-hashed-db=db4
1042aae38d10SBaptiste Daroussin	to make the configure script look for files in a subdirectory such as
1043aae38d10SBaptiste Daroussin		/usr/include/db4/db.h
1044aae38d10SBaptiste Daroussin		/usr/lib/db4/libdb.so
10455ca44d1cSRong-En Fan
10464a1a9510SRong-En Fan	See also the --enable-getcap option.
104718259542SPeter Wemm
1048aae38d10SBaptiste Daroussin    --with-infocmp-path[=XXX]
1049*21817992SBaptiste Daroussin	Use this option to override the automatic detection of infocmp in your
1050aae38d10SBaptiste Daroussin	$PATH when building fallbacks (see "--with-fallbacks").
1051aae38d10SBaptiste Daroussin
105218259542SPeter Wemm    --with-install-prefix=XXX
105318259542SPeter Wemm	Allows you to specify an alternate location for installing ncurses
105418259542SPeter Wemm	after building it.  The value you specify is prepended to the "real"
10554a1a9510SRong-En Fan	install location.  This simplifies making binary packages.  The
10564a1a9510SRong-En Fan	makefile variable DESTDIR is set by this option.  It is also possible
10574a1a9510SRong-En Fan	to use
10584a1a9510SRong-En Fan		make install DESTDIR=XXX
10594a1a9510SRong-En Fan	since the makefiles pass that variable to subordinate makes.
106018259542SPeter Wemm
106118259542SPeter Wemm	NOTE: a few systems build shared libraries with fixed pathnames; this
106218259542SPeter Wemm	option probably will not work for those configurations.
106318259542SPeter Wemm
106473f0a83dSXin LI    --with-lib-prefix=XXX
106573f0a83dSXin LI	OS/2 EMX used a different naming convention from most Unix-like
106673f0a83dSXin LI	platforms.  It required that the "lib" part of a library name was
106773f0a83dSXin LI	omitted.  Newer EMX as part of eComStation does not follow that
106873f0a83dSXin LI	convention.  Use this option to override the configure script's
106973f0a83dSXin LI	assumptions about the library-prefix.  If this option is omitted, it
107073f0a83dSXin LI	uses the original OS/2 EMX convention for that platform.  Use
107173f0a83dSXin LI	"--with-lib-prefix=lib" for the newer EMX in eComStation.  Use
107273f0a83dSXin LI	"--without-lib-prefix" to suppress it for other odd platforms.
107373f0a83dSXin LI
10744a1a9510SRong-En Fan    --with-libtool[=XXX]
10754a1a9510SRong-En Fan	Generate libraries with libtool.  If this option is selected, then it
10764a1a9510SRong-En Fan	overrides all other library model specifications.  Note that libtool
10774a1a9510SRong-En Fan	must already be installed, uses makefile rules dependent on GNU make,
10784a1a9510SRong-En Fan	and does not promise to follow the version numbering convention of
10794a1a9510SRong-En Fan	other shared libraries on your system.  However, if the --with-shared
10804a1a9510SRong-En Fan	option does not succeed, you may get better results with this option.
10814a1a9510SRong-En Fan
10824a1a9510SRong-En Fan	If a parameter value is given, it must be the full pathname of the
10834a1a9510SRong-En Fan	particular version of libtool, e.g.,
10844a1a9510SRong-En Fan		/usr/bin/libtool-1.2.3
10854a1a9510SRong-En Fan
10864a1a9510SRong-En Fan	It is possible to rebuild the configure script to use the automake
10874a1a9510SRong-En Fan	macros for libtool, e.g., AC_PROG_LIBTOOL.  See the comments in
10884a1a9510SRong-En Fan	aclocal.m4 for CF_PROG_LIBTOOL, and ensure that you build configure
10894a1a9510SRong-En Fan	using the appropriate patch for autoconf from
1090aae38d10SBaptiste Daroussin		https://invisible-island.net/autoconf/
1091aae38d10SBaptiste Daroussin
1092aae38d10SBaptiste Daroussin    --with-libtool-opts=XXX
1093aae38d10SBaptiste Daroussin	Allow user to pass additional libtool options into the library creation
1094aae38d10SBaptiste Daroussin	and link steps.  The main use for this is to do something like
1095aae38d10SBaptiste Daroussin		./configure --with-libtool-opts=-static
1096aae38d10SBaptiste Daroussin	to get the same behavior as automake-flavored
1097aae38d10SBaptiste Daroussin		./configure --enable-static
10984a1a9510SRong-En Fan
10994a1a9510SRong-En Fan    --with-manpage-aliases
11004a1a9510SRong-En Fan	Tell the configure script you wish to create entries in the
11014a1a9510SRong-En Fan	man-directory for aliases to manpages which list them, e.g., the
11024a1a9510SRong-En Fan	functions in the panel manpage.  This is the default.  You can disable
11034a1a9510SRong-En Fan	it if your man program does this.  You can also disable
11044a1a9510SRong-En Fan	--with-manpage-symlinks to install files containing a ".so" command
11054a1a9510SRong-En Fan	rather than symbolic links.
11067a69bbfbSPeter Wemm
110718259542SPeter Wemm    --with-manpage-format=XXX
110818259542SPeter Wemm	Tell the configure script how you would like to install man-pages.  The
110918259542SPeter Wemm	option value must be one of these:  gzip, compress, BSDI, normal,
111018259542SPeter Wemm	formatted.  If you do not give this option, the configure script
111118259542SPeter Wemm	attempts to determine which is the case.
111218259542SPeter Wemm
111318259542SPeter Wemm    --with-manpage-renames=XXX
111418259542SPeter Wemm	Tell the configure script that you wish to rename the manpages while
111506bfebdeSXin LI	installing.  Currently the only distribution which does this is Debian.
111606bfebdeSXin LI	The option value specifies the name of a file that lists the renamed
111706bfebdeSXin LI	files, e.g., $srcdir/man/man_db.renames
111818259542SPeter Wemm
111918259542SPeter Wemm    --with-manpage-symlinks
112018259542SPeter Wemm	Tell the configure script that you wish to make symbolic links in the
112118259542SPeter Wemm	man-directory for aliases to the man-pages.  This is the default, but
112218259542SPeter Wemm	can be disabled for systems that provide this automatically.  Doing
112318259542SPeter Wemm	this on systems that do not support symbolic links will result in
112418259542SPeter Wemm	copying the man-page for each alias.
112518259542SPeter Wemm
11267a69bbfbSPeter Wemm    --with-manpage-tbl
1127aae38d10SBaptiste Daroussin	Tell the configure script that you wish to preprocess the manpages
11287a69bbfbSPeter Wemm	by running them through tbl to generate tables understandable by
11297a69bbfbSPeter Wemm	nroff.
11307a69bbfbSPeter Wemm
11317a656419SBaptiste Daroussin    --with-menu-libname=NAME
11327a656419SBaptiste Daroussin	Override the basename of the menu library (default: "menu")
11337a656419SBaptiste Daroussin
11344a1a9510SRong-En Fan    --with-mmask-t=TYPE
11354a1a9510SRong-En Fan	Override type of mmask_t, which stores the mouse mask.  Prior to
11364a1a9510SRong-En Fan	ncurses 5.5, this was always unsigned long, but with ncurses 5.5, it
11374a1a9510SRong-En Fan	may be unsigned.  Use this option if you need to preserve compatibility
11384a1a9510SRong-En Fan	with 64-bit executables.
11394a1a9510SRong-En Fan
11405d08fb1fSRong-En Fan    --with-normal
11415d08fb1fSRong-En Fan	Generate normal (i.e., static) libraries (default).
11425d08fb1fSRong-En Fan
11435d08fb1fSRong-En Fan	Note:  on Linux, the configure script will attempt to use the GPM
11445d08fb1fSRong-En Fan	library via the dlsym() function call.  Use --without-dlsym to disable
11455d08fb1fSRong-En Fan	this feature, or --without-gpm, depending on whether you wish to use
11465d08fb1fSRong-En Fan	GPM.
11475d08fb1fSRong-En Fan
11487a69bbfbSPeter Wemm    --with-ospeed=TYPE
11497a69bbfbSPeter Wemm	Override type of ospeed variable, which is part of the termcap
11507a69bbfbSPeter Wemm	compatibility interface.  In termcap, this is a 'short', which works
11517a69bbfbSPeter Wemm	for a wide range of baudrates because ospeed is not the actual speed
11527a69bbfbSPeter Wemm	but the encoded value, e.g., B9600 would be a small number such as 13.
11537a69bbfbSPeter Wemm	However the encoding scheme originally allowed for values "only" up to
11547a69bbfbSPeter Wemm	38400bd.  A newer set of definitions past 38400bd is not encoded as
11557a69bbfbSPeter Wemm	compactly, and is not guaranteed to fit into a short (see the function
11567a69bbfbSPeter Wemm	cfgetospeed(), which returns a speed_t for this reason).  In practice,
11577a69bbfbSPeter Wemm	applications that required knowledge of the ospeed variable, i.e.,
11587a69bbfbSPeter Wemm	those using termcap, do not use the higher speeds.  Your application
11597a69bbfbSPeter Wemm	(or system, in general) may or may not.
11607a69bbfbSPeter Wemm
11617a656419SBaptiste Daroussin    --with-panel-libname=NAME
11627a656419SBaptiste Daroussin	Override the basename of the panel library (default: "panel")
11637a656419SBaptiste Daroussin
1164aae38d10SBaptiste Daroussin    --with-pc-suffix=SUFFIX
1165*21817992SBaptiste Daroussin	If ".pc" files are installed (see --enable-pc-files), optionally add a
1166*21817992SBaptiste Daroussin	suffix to the files and corresponding package names to separate
1167*21817992SBaptiste Daroussin	unusual configurations.  If no option value is given (or if it is
1168*21817992SBaptiste Daroussin	"none"), no suffix is added.
1169aae38d10SBaptiste Daroussin
1170aae38d10SBaptiste Daroussin    --with-pcre2
1171aae38d10SBaptiste Daroussin	Add PCRE2 (Perl-compatible regular expressions v2) to the build if it
1172aae38d10SBaptiste Daroussin	is available and the user requests it.  Assume the application will
1173aae38d10SBaptiste Daroussin	otherwise use the POSIX interface.
1174aae38d10SBaptiste Daroussin
1175aae38d10SBaptiste Daroussin	This is useful for MinGW builds because the usual POSIX interface is
1176aae38d10SBaptiste Daroussin	not supplied by the development environment, while ncurses' form
1177aae38d10SBaptiste Daroussin	library uses a regular expression feature for one of the field types.
1178aae38d10SBaptiste Daroussin
1179*21817992SBaptiste Daroussin    --with-pkg-config[=CMD]
1180*21817992SBaptiste Daroussin	Check for pkg-config, optionally specifying its pathname.
118106bfebdeSXin LI
1182*21817992SBaptiste Daroussin    --with-pkg-config-libdir[=DIR]
118373f0a83dSXin LI	If pkg-config was found, override the automatic check for its library
1184*21817992SBaptiste Daroussin	path.  The optional DIR value can be
1185*21817992SBaptiste Daroussin
1186*21817992SBaptiste Daroussin	"auto", automatically use pkg-config's library directory, or
1187*21817992SBaptiste Daroussin
1188*21817992SBaptiste Daroussin	"libdir", use a ${libdir}/pkgconfig (based on the configuration), or
1189*21817992SBaptiste Daroussin
1190*21817992SBaptiste Daroussin	a directory path, i.e., beginning with "/".
1191*21817992SBaptiste Daroussin
1192*21817992SBaptiste Daroussin	The configure script allows only a single directory, because
1193*21817992SBaptiste Daroussin	that is used as the directory in which to install ".pc" files.
1194*21817992SBaptiste Daroussin
1195*21817992SBaptiste Daroussin	The automatic check for the library path prefers the first directory
1196*21817992SBaptiste Daroussin	which currently exists.  If none of the directories listed by
1197*21817992SBaptiste Daroussin	pkg-config exist, the check prefers a pkgconfig directory under the
1198*21817992SBaptiste Daroussin	"libdir" set by the configure script (which may not be the system
1199*21817992SBaptiste Daroussin	default), or if pkg-config lists nothing suitable, the first one which
1200*21817992SBaptiste Daroussin	is listed by pkg-config is used.
120173f0a83dSXin LI
120218259542SPeter Wemm    --with-profile
120318259542SPeter Wemm	Generate profile-libraries These are named by adding "_p" to the root,
120418259542SPeter Wemm	e.g., libncurses_p.a
120518259542SPeter Wemm
1206aa59d4d4SRong-En Fan    --with-pthread
1207aa59d4d4SRong-En Fan	Link with POSIX threads, set --enable-reentrant.  The use_window() and
1208aa59d4d4SRong-En Fan	use_screen() functions will use mutex's, allowing rudimentary support
1209aa59d4d4SRong-En Fan	for multithreaded applications.
1210aa59d4d4SRong-En Fan
121118259542SPeter Wemm    --with-rcs-ids
121218259542SPeter Wemm	Compile-in RCS identifiers.  Most of the C files have an identifier.
121318259542SPeter Wemm
12144a1a9510SRong-En Fan    --with-rel-version=NUM
12154a1a9510SRong-En Fan	Override the release version, which may be used in shared library
12164a1a9510SRong-En Fan	filenames.  This consists of a major and minor version number separated
12174a1a9510SRong-En Fan	by ".".  Normally the major version number is the same as the ABI
12184a1a9510SRong-En Fan	version; some ports have special requirements for compatibility.
12194a1a9510SRong-En Fan
122018259542SPeter Wemm    --with-shared
122118259542SPeter Wemm	Generate shared-libraries.  The names given depend on the system for
122218259542SPeter Wemm	which you are building, typically using a ".so" suffix, along with
122318259542SPeter Wemm	symbolic links that refer to the release version.
122418259542SPeter Wemm
122518259542SPeter Wemm	NOTE: Unless you override the configure script by setting the $CFLAGS
122618259542SPeter Wemm	environment variable, these will not be built with the -g debugging
122718259542SPeter Wemm	option.
122818259542SPeter Wemm
12294a1a9510SRong-En Fan	NOTE: For some configurations, e.g., installing a new version of
12304a1a9510SRong-En Fan	ncurses shared libraries on a machine which already has ncurses
12314a1a9510SRong-En Fan	shared libraries, you may encounter problems with the linker.
12324a1a9510SRong-En Fan	For example, it may prevent you from running  the build tree's
12334a1a9510SRong-En Fan	copy of tic (for installing the terminfo database) because it
1234aae38d10SBaptiste Daroussin	loads the system's copy of the ncurses shared libraries.
1235aae38d10SBaptiste Daroussin
1236aae38d10SBaptiste Daroussin	In that case, using the misc/shlib script may be helpful, since it
1237aae38d10SBaptiste Daroussin	sets $LD_LIBRARY_PATH to point to the build tree, e.g.,
1238aae38d10SBaptiste Daroussin
12394a1a9510SRong-En Fan		./misc/shlib make install
12404a1a9510SRong-En Fan
1241aae38d10SBaptiste Daroussin	Alternatively, for most platforms, the linker accepts a list of
1242aae38d10SBaptiste Daroussin	directories which will be searched for libraries at run-time.  The
1243aae38d10SBaptiste Daroussin	configure script allows you to modify this list using the
1244aae38d10SBaptiste Daroussin	RPATH_LIST environment variable.  It is a colon-separated list of
1245aae38d10SBaptiste Daroussin	directories (default:  the "libdir" set via the configure script).
1246aae38d10SBaptiste Daroussin	If you set that to put "../lib" first in the list, the linker will
1247aae38d10SBaptiste Daroussin	look first at the build-directory, and avoid conflict with libraries
1248aae38d10SBaptiste Daroussin	already installed.  One drawback to this approach is that libraries
1249aae38d10SBaptiste Daroussin	can be accidentally searched in any "../lib" directory.
1250aae38d10SBaptiste Daroussin
125106bfebdeSXin LI	NOTE: If you use the --with-ada-sharedlib option, you should also
125206bfebdeSXin LI	set this option, to ensure that C-language modules needed for the
125306bfebdeSXin LI	Ada binding use appropriate compiler options.
125406bfebdeSXin LI
125518259542SPeter Wemm    --with-shlib-version=XXX
125618259542SPeter Wemm	Specify whether to use the release or ABI version for shared libraries.
125718259542SPeter Wemm	This is normally chosen automatically based on the type of system
125818259542SPeter Wemm	which you are building on.  We use it for testing the configure script.
125918259542SPeter Wemm
1260*21817992SBaptiste Daroussin    --with-strip-program=XXX
1261*21817992SBaptiste Daroussin    	When stripping executables during install, use the specified program
1262*21817992SBaptiste Daroussin	rather than "strip".
1263*21817992SBaptiste Daroussin
12644a1a9510SRong-En Fan    --with-sysmouse
12654a1a9510SRong-En Fan	use FreeBSD sysmouse interface provide mouse support on the console.
12664a1a9510SRong-En Fan
126718259542SPeter Wemm    --with-system-type=XXX
126818259542SPeter Wemm	For testing, override the derived host system-type which is used to
126918259542SPeter Wemm	decide things such as the linker commands used to build shared
127018259542SPeter Wemm	libraries.  This is normally chosen automatically based on the type of
127118259542SPeter Wemm	system which you are building on.  We use it for testing the configure
127218259542SPeter Wemm	script.
127318259542SPeter Wemm
127418259542SPeter Wemm    --with-terminfo-dirs=XXX
127518259542SPeter Wemm	Specify a search-list of terminfo directories which will be compiled
127618259542SPeter Wemm	into the ncurses library (default: DATADIR/terminfo)
127718259542SPeter Wemm
1278*21817992SBaptiste Daroussin	This is a colon-separated list, like the $TERMINFO_DIRS environment
1279aae38d10SBaptiste Daroussin	variable.
1280aae38d10SBaptiste Daroussin
12814a1a9510SRong-En Fan    --with-termlib[=XXX]
128218259542SPeter Wemm	When building the ncurses library, organize this as two parts:  the
128318259542SPeter Wemm	curses library (libncurses) and the low-level terminfo library
128418259542SPeter Wemm	(libtinfo).  This is done to accommodate applications that use only
128518259542SPeter Wemm	the latter.  The terminfo library is about half the size of the total.
128618259542SPeter Wemm
12874a1a9510SRong-En Fan	If an option value is given, that overrides the name of the terminfo
12884a1a9510SRong-En Fan	library.  For instance, if the wide-character version is built, the
12894a1a9510SRong-En Fan	terminfo library would be named libtinfow.  But the libtinfow interface
12904a1a9510SRong-En Fan	is upward compatible from libtinfo, so it would be possible to overlay
12914a1a9510SRong-En Fan	libtinfo.so with a "wide" version of libtinfow.so by renaming it with
12924a1a9510SRong-En Fan	this option.
12934a1a9510SRong-En Fan
129439f2269fSPeter Wemm    --with-termpath=XXX
129539f2269fSPeter Wemm	Specify a search-list of termcap files which will be compiled into the
129639f2269fSPeter Wemm	ncurses library (default:  /etc/termcap:/usr/share/misc/termcap)
129739f2269fSPeter Wemm
1298aae38d10SBaptiste Daroussin    --with-tic-path[=XXX]
1299aae38d10SBaptiste Daroussin	Use this option to override the automatic detection of tic in your
1300aae38d10SBaptiste Daroussin	$PATH when building fallbacks (see "--with-fallbacks").
1301aae38d10SBaptiste Daroussin
13025ca44d1cSRong-En Fan    --with-ticlib[=XXX]
13035ca44d1cSRong-En Fan	When building the ncurses library, build a separate library for
13045ca44d1cSRong-En Fan	the modules that are used only by the utility programs.  Normally
13055ca44d1cSRong-En Fan	those would be bundled with the termlib or ncurses libraries.
13065ca44d1cSRong-En Fan
13075ca44d1cSRong-En Fan	If an option value is given, that overrides the name of the tic
13085ca44d1cSRong-En Fan	library.  As in termlib, there is no ABI difference between the
13095ca44d1cSRong-En Fan	"wide" libticw.so and libtic.so
13105ca44d1cSRong-En Fan
13115d08fb1fSRong-En Fan	NOTE: Overriding the name of the tic library may be useful if you are
13125d08fb1fSRong-En Fan	also using the --with-termlib option to rename libtinfo.  If you are
13135d08fb1fSRong-En Fan	not doing that, renaming the tic library can result in conflicting
13145d08fb1fSRong-En Fan	library dependencies for tic and other programs built with the tic
13155d08fb1fSRong-En Fan	library.
13165d08fb1fSRong-En Fan
131773f0a83dSXin LI    --with-tparm-arg[=XXX]
131873f0a83dSXin LI	Override the type used for tparm() arguments, which normally is a
131973f0a83dSXin LI	"long".  However the function must assume that its arguments can hold a
132073f0a83dSXin LI	pointer to char's which is not always workable for 64-bit platforms.  A
132173f0a83dSXin LI	better choice would be intptr_t, which was not available at the time
132273f0a83dSXin LI	tparm's interface was defined.
132373f0a83dSXin LI
132473f0a83dSXin LI	If the option is not given, this defaults to "long".
132573f0a83dSXin LI
13264a1a9510SRong-En Fan    --with-trace
13274a1a9510SRong-En Fan	Configure the trace() function as part of the all models of the ncurses
13284a1a9510SRong-En Fan	library.  Normally it is part of the debug (libncurses_g) library only.
13294a1a9510SRong-En Fan
13304a1a9510SRong-En Fan    --with-valgrind
13314a1a9510SRong-En Fan	For testing, compile with debug option.
13324a1a9510SRong-En Fan	This also sets the --disable-leaks option.
13334a1a9510SRong-En Fan
1334aae38d10SBaptiste Daroussin    --with-versioned-syms[=XXX]
1335aae38d10SBaptiste Daroussin	The Solaris, GNU and reportedly some other linkers (ld) accept a
1336aae38d10SBaptiste Daroussin	"--version-script" option which tells the linker to annotate the
1337aae38d10SBaptiste Daroussin	resulting objects with version identifiers.
1338aae38d10SBaptiste Daroussin
1339aae38d10SBaptiste Daroussin	Use "objdump -T" on a library to see the annotations.
1340aae38d10SBaptiste Daroussin
1341aae38d10SBaptiste Daroussin	The configure script attempts to automatically apply a suitable ".map"
1342aae38d10SBaptiste Daroussin	file to provide this information for Linux.  Solaris mapfiles differ:
1343aae38d10SBaptiste Daroussin
1344aae38d10SBaptiste Daroussin	a) comments are not accepted
1345aae38d10SBaptiste Daroussin	b) wildcards are not accepted, except for a special case of "_*".
1346aae38d10SBaptiste Daroussin	c) each symbol listed in the map file must exist in the library
1347aae38d10SBaptiste Daroussin
1348aae38d10SBaptiste Daroussin	The Solaris limitations conflict with the development goal of providing
1349aae38d10SBaptiste Daroussin	a small set of ".map" files as examples, which cover the most common
1350aae38d10SBaptiste Daroussin	configurations.  Because that coverage is done by merging together
1351aae38d10SBaptiste Daroussin	several builds, some symbols will be listed in the the ".map" files
1352aae38d10SBaptiste Daroussin	that do not happen to be present in one configuration or another.
1353aae38d10SBaptiste Daroussin
1354aae38d10SBaptiste Daroussin	The sample ".map" (and ".sym") files are generated using a set of
1355aae38d10SBaptiste Daroussin	scripts which build several configurations for each release version,
1356aae38d10SBaptiste Daroussin	checking to see which of the "_nc_" symbols can be made local.  In
1357aae38d10SBaptiste Daroussin	addition to the ncurses libraries and programs, the symbols used
1358aae38d10SBaptiste Daroussin	by the "tack" program before version 1.08 are made global.
1359aae38d10SBaptiste Daroussin
1360aae38d10SBaptiste Daroussin	These sample ".map" files will not cover all possible combinations.
1361aae38d10SBaptiste Daroussin	In some cases, e.g., when using the --with-weak-symbols option, you
1362aae38d10SBaptiste Daroussin	may prefer to use a different ".map" file by setting this option's
1363aae38d10SBaptiste Daroussin	value.
1364aae38d10SBaptiste Daroussin
136506bfebdeSXin LI    --with-wrap-prefix=XXX
136606bfebdeSXin LI	When using the --enable-reentrant option, ncurses redefines variables
136706bfebdeSXin LI	that would be global in curses, e.g., LINES, as a macro that calls a
136806bfebdeSXin LI	"wrapping" function which fetches the data from the current SCREEN
136906bfebdeSXin LI	structure.  Normally that function is named by prepending "_nc_" to the
137006bfebdeSXin LI	variable's name.  The function is technically private (since portable
137106bfebdeSXin LI	applications would not refer directly to it).  But according to one
137206bfebdeSXin LI	line of reasoning, it is not the same type of "private" as functions
137306bfebdeSXin LI	which applications should not call even via a macro.  This configure
137406bfebdeSXin LI	option lets you choose the prefix for these wrapped variables.
137506bfebdeSXin LI
1376aae38d10SBaptiste Daroussin    --with-x11-rgb=FILE
1377aae38d10SBaptiste Daroussin	Provide a pathname for the X11 rgb file, used by the picsmap program.
1378aae38d10SBaptiste Daroussin	This overrides a configure check which usually works, but is needed
1379aae38d10SBaptiste Daroussin	due to the lack of standardization for X11's files.
1380aae38d10SBaptiste Daroussin
1381aae38d10SBaptiste Daroussin    --with-xterm-kbs=XXX
1382aae38d10SBaptiste Daroussin	Configure xterm's terminfo entries to use either BS (^H, i.e., ASCII
1383aae38d10SBaptiste Daroussin	backspace) or DEL (^?, or 127).  XXX can be BS (or bs, 8) or DEL
1384*21817992SBaptiste Daroussin	(or del, 127).  If XXX is "auto", the configure script chooses BS or
1385*21817992SBaptiste Daroussin	DEL according to platform defaults.
1386aae38d10SBaptiste Daroussin
1387aae38d10SBaptiste Daroussin	During installation, the makefile and scripts modifies the "xterm+kbs"
1388aae38d10SBaptiste Daroussin	terminfo entry to use this setting.
1389aae38d10SBaptiste Daroussin
139018259542SPeter Wemm    --without-ada
139118259542SPeter Wemm	Suppress the configure script's check for Ada95, do not build the
139218259542SPeter Wemm	Ada95 binding and related demo.
139318259542SPeter Wemm
13947a69bbfbSPeter Wemm    --without-curses-h
13957a69bbfbSPeter Wemm	Don't install the ncurses header with the name "curses.h".  Rather,
13967a69bbfbSPeter Wemm	install as "ncurses.h" and modify the installed headers and manpages
13977a69bbfbSPeter Wemm	accordingly.
13987a69bbfbSPeter Wemm
139973f0a83dSXin LI	Likewise, do not install an alias "curses" for the ncurses manpage.
140073f0a83dSXin LI
140118259542SPeter Wemm    --without-cxx
140218259542SPeter Wemm	XSI curses declares "bool" as part of the interface.  C++ also declares
140318259542SPeter Wemm	"bool".  Neither specifies the size and type of booleans, but both
140418259542SPeter Wemm	insist on the same name.  We chose to accommodate this by making the
140518259542SPeter Wemm	configure script check for the size and type (e.g., unsigned or signed)
140618259542SPeter Wemm	that your C++ compiler uses for booleans.  If you do not wish to use
140718259542SPeter Wemm	ncurses with C++, use this option to tell the configure script to not
140818259542SPeter Wemm	adjust ncurses bool to match C++.
140918259542SPeter Wemm
141018259542SPeter Wemm    --without-cxx-binding
141118259542SPeter Wemm	Suppress the configure script's check for C++, do not build the
141218259542SPeter Wemm	C++ binding and related demo.
141318259542SPeter Wemm
14144a1a9510SRong-En Fan    --without-develop
14154a1a9510SRong-En Fan	Disable development options.  This does not include those that change
14164a1a9510SRong-En Fan	the interface, such as --enable-widec.
14174a1a9510SRong-En Fan
14184a1a9510SRong-En Fan    --without-dlsym
14194a1a9510SRong-En Fan	Do not use dlsym() to load GPM dynamically.
14204a1a9510SRong-En Fan
142106bfebdeSXin LI    --without-manpages
142206bfebdeSXin LI	Tell the configure script to suppress the install of ncurses' manpages.
142306bfebdeSXin LI
142418259542SPeter Wemm    --without-progs
142518259542SPeter Wemm	Tell the configure script to suppress the build of ncurses' application
142618259542SPeter Wemm	programs (e.g., tic).  The test applications will still be built if you
142718259542SPeter Wemm	type "make", though not if you simply do "make install".
142818259542SPeter Wemm
142906bfebdeSXin LI    --without-tests
143006bfebdeSXin LI	Tell the configure script to suppress the build of ncurses' test
143106bfebdeSXin LI	programs.
143206bfebdeSXin LI
14334a1a9510SRong-En Fan    --without-xterm-new
14344a1a9510SRong-En Fan	Tell the configure script to use "xterm-old" for the entry used in
14354a1a9510SRong-En Fan	the terminfo database.  This will work with variations such as
14364a1a9510SRong-En Fan	X11R5 and X11R6 xterm.
14374a1a9510SRong-En Fan
143818259542SPeter Wemm
14397a656419SBaptiste DaroussinCOMPATIBILITY WITH OLDER RELEASES:
14407a656419SBaptiste Daroussin---------------------------------
144115589c42SPeter Wemm
1442aae38d10SBaptiste Daroussin    Because ncurses implements X/Open Curses, its interface is fairly stable.
1443aae38d10SBaptiste Daroussin    That does not mean the interface does not change.  Changes are made to the
1444aae38d10SBaptiste Daroussin    documented interfaces when we find differences between ncurses and X/Open
1445aae38d10SBaptiste Daroussin    or implementations which largely correspond to X/Open (such as Solaris).
1446aae38d10SBaptiste Daroussin    We add extensions to those interfaces to solve problems not addressed by
1447aae38d10SBaptiste Daroussin    the original curses design, but those must not conflict with the X/Open
1448aae38d10SBaptiste Daroussin    documentation.
144915589c42SPeter Wemm
145015589c42SPeter Wemm    Here are some of the major interface changes, and related problems which
145115589c42SPeter Wemm    you may encounter when building a system with different versions of
145215589c42SPeter Wemm    ncurses:
145315589c42SPeter Wemm
1454*21817992SBaptiste Daroussin    6.5 (Apt 27, 2024)
1455*21817992SBaptiste Daroussin	Interface changes:
1456*21817992SBaptiste Daroussin
1457*21817992SBaptiste Daroussin	+ the WINDOW structure and some related internal data types declared
1458*21817992SBaptiste Daroussin	  in <curses.h> have been made opaque by default;
1459*21817992SBaptiste Daroussin	+ the FORM, MENU, and PANEL structures and related internal data types
1460*21817992SBaptiste Daroussin	  from their corresponding header files have been made opqaue by
1461*21817992SBaptiste Daroussin	  default; and
1462*21817992SBaptiste Daroussin	+ support for wide characters is now enabled by default.
1463*21817992SBaptiste Daroussin
1464*21817992SBaptiste Daroussin	Added extensions:
1465*21817992SBaptiste Daroussin
1466*21817992SBaptiste Daroussin	+ is_cbreak, is_echo, is_nl, and is_raw, as well as "_sp" variants
1467*21817992SBaptiste Daroussin
1468*21817992SBaptiste Daroussin	+ tiparm_s and tiscan_s
1469*21817992SBaptiste Daroussin
1470*21817992SBaptiste Daroussin	Added internal functions (other than "_sp" variants):
1471*21817992SBaptiste Daroussin
1472*21817992SBaptiste Daroussin	+ _nc_env_access
1473*21817992SBaptiste Daroussin
1474*21817992SBaptiste Daroussin	Removed internal functions:
1475*21817992SBaptiste Daroussin
1476*21817992SBaptiste Daroussin	+ none
1477*21817992SBaptiste Daroussin
1478*21817992SBaptiste Daroussin	Modified internal functions:
1479*21817992SBaptiste Daroussin
1480*21817992SBaptiste Daroussin	+ These now pass a const parameter: _nc_delink_entry, _nc_str_copy,
1481*21817992SBaptiste Daroussin	  and _nc_trans_string
1482*21817992SBaptiste Daroussin
1483*21817992SBaptiste Daroussin    6.4 (Dec 31, 2022)
1484*21817992SBaptiste Daroussin	Interface changes:
1485*21817992SBaptiste Daroussin
1486*21817992SBaptiste Daroussin	+ none
1487*21817992SBaptiste Daroussin
1488*21817992SBaptiste Daroussin	Added extensions:
1489*21817992SBaptiste Daroussin
1490*21817992SBaptiste Daroussin	+ none
1491*21817992SBaptiste Daroussin
1492*21817992SBaptiste Daroussin	Added internal functions (other than "_sp" variants):
1493*21817992SBaptiste Daroussin
1494*21817992SBaptiste Daroussin	+ add _nc_free_termtype1 and _nc_free_tparm, for memory-leaks
1495*21817992SBaptiste Daroussin
1496*21817992SBaptiste Daroussin	Removed internal functions:
1497*21817992SBaptiste Daroussin
1498*21817992SBaptiste Daroussin	+ none
1499*21817992SBaptiste Daroussin
1500*21817992SBaptiste Daroussin	Modified internal functions:
1501*21817992SBaptiste Daroussin
1502*21817992SBaptiste Daroussin	+ none
1503*21817992SBaptiste Daroussin
1504*21817992SBaptiste Daroussin    6.3 (Oct 21, 2021)
1505*21817992SBaptiste Daroussin	Interface changes:
1506*21817992SBaptiste Daroussin
1507*21817992SBaptiste Daroussin	+ the definition of TERMTYPE2 is now internal, not visible in the ABI,
1508*21817992SBaptiste Daroussin	  like the enclosing TERMINAL which was previously made opaque.  This
1509*21817992SBaptiste Daroussin	  was done to provide SCREEN-specific "static" variables in terminfo.
1510*21817992SBaptiste Daroussin
1511*21817992SBaptiste Daroussin	Added extensions:
1512*21817992SBaptiste Daroussin
1513*21817992SBaptiste Daroussin	+ add sp-funcs for erasewchar, killwchar.
1514*21817992SBaptiste Daroussin
1515*21817992SBaptiste Daroussin	Added internal functions (other than "_sp" variants):
1516*21817992SBaptiste Daroussin
1517*21817992SBaptiste Daroussin	+ _nc_safe_fopen and _nc_safe_open3 limit privileges if possible when
1518*21817992SBaptiste Daroussin	  opening a file; otherwise disallow access for updating files.
1519*21817992SBaptiste Daroussin
1520*21817992SBaptiste Daroussin	+ _nc_tiparm is a variant of tiparm which is used when all of the
1521*21817992SBaptiste Daroussin	  parameters are known to be numbers rather than possibly strings.
1522*21817992SBaptiste Daroussin
1523*21817992SBaptiste Daroussin	+ _nc_reset_tparm improves tic's checks by resetting the terminfo
1524*21817992SBaptiste Daroussin	  "static variables" before calling functions which may update them.
1525*21817992SBaptiste Daroussin
1526*21817992SBaptiste Daroussin	Removed internal functions:
1527*21817992SBaptiste Daroussin
1528*21817992SBaptiste Daroussin	+ none
1529*21817992SBaptiste Daroussin
1530*21817992SBaptiste Daroussin	Modified internal functions:
1531*21817992SBaptiste Daroussin
1532*21817992SBaptiste Daroussin	+ _nc_trace_ttymode passes pointer to const data
1533*21817992SBaptiste Daroussin
1534*21817992SBaptiste Daroussin	+ _nc_tparm_analyze passes pointer to int*, not int[]
1535*21817992SBaptiste Daroussin
1536e1865124SBaptiste Daroussin    6.2 (Feb 12, 2020)
1537e1865124SBaptiste Daroussin	Interface changes:
1538e1865124SBaptiste Daroussin
1539e1865124SBaptiste Daroussin	+ the terminal database must be compiled with ncurses 6.2 tic;
1540e1865124SBaptiste Daroussin	  older versions of tic/infocmp will not work.  Aside from that,
1541e1865124SBaptiste Daroussin	  the compiled database will work with older applications.
1542e1865124SBaptiste Daroussin
1543e1865124SBaptiste Daroussin	+ "*.pc" and "ncurses*-config" files give the same information.
1544e1865124SBaptiste Daroussin
1545e1865124SBaptiste Daroussin	+ vwprintw and vwscanw are deprecated.
1546e1865124SBaptiste Daroussin
1547e1865124SBaptiste Daroussin	Added extensions:
1548e1865124SBaptiste Daroussin
1549e1865124SBaptiste Daroussin	+ These make it simpler to substitute a debug-configuration of the
1550e1865124SBaptiste Daroussin	  library for non-debug:
1551e1865124SBaptiste Daroussin		curses_trace
1552e1865124SBaptiste Daroussin		exit_curses
1553e1865124SBaptiste Daroussin		exit_terminfo
1554e1865124SBaptiste Daroussin
1555e1865124SBaptiste Daroussin	Added internal functions (other than "_sp" variants):
1556e1865124SBaptiste Daroussin
1557e1865124SBaptiste Daroussin	+ These provide fast-lookup of common user-defined capabilities:
1558e1865124SBaptiste Daroussin		_nc_find_user_entry
1559e1865124SBaptiste Daroussin		_nc_get_userdefs_table
1560e1865124SBaptiste Daroussin		_nc_get_hash_user
1561e1865124SBaptiste Daroussin
1562e1865124SBaptiste Daroussin	+ This is added to work around compiler-warnings:
1563e1865124SBaptiste Daroussin		_nc_fmt_funcptr
1564e1865124SBaptiste Daroussin
1565e1865124SBaptiste Daroussin	Removed internal functions:
1566e1865124SBaptiste Daroussin
1567e1865124SBaptiste Daroussin	+ _nc_import_termtype
1568e1865124SBaptiste Daroussin
1569e1865124SBaptiste Daroussin	Modified internal functions:
1570e1865124SBaptiste Daroussin
1571e1865124SBaptiste Daroussin	+ _nc_reserve_pairs no longer returns a value
1572e1865124SBaptiste Daroussin
1573aae38d10SBaptiste Daroussin    6.1 (Jan 27, 2018)
1574aae38d10SBaptiste Daroussin	Interface changes:
1575aae38d10SBaptiste Daroussin
1576aae38d10SBaptiste Daroussin	+ X/Open Curses specifies a "reserved" void* parameter in several
1577aae38d10SBaptiste Daroussin	  functions, saying that it must be NULL.  In this release, if the
1578aae38d10SBaptiste Daroussin	  parameter is non-NULL, it is interpreted as a point to an integer
1579aae38d10SBaptiste Daroussin	  containing a color pair.  In previous releases, a non-NULL parameter
1580aae38d10SBaptiste Daroussin	  caused an error return.  Portable applications are unaffected.  Here
1581aae38d10SBaptiste Daroussin	  are the functions which have been extended:
1582aae38d10SBaptiste Daroussin		attr_get
1583aae38d10SBaptiste Daroussin		attr_off
1584aae38d10SBaptiste Daroussin		attr_on
1585aae38d10SBaptiste Daroussin		attr_set
1586aae38d10SBaptiste Daroussin		chgat
1587aae38d10SBaptiste Daroussin		color_set
1588aae38d10SBaptiste Daroussin		mvchgat
1589aae38d10SBaptiste Daroussin		mvwchgat
1590aae38d10SBaptiste Daroussin		slk_attr_off
1591aae38d10SBaptiste Daroussin		slk_attr_on
1592aae38d10SBaptiste Daroussin		slk_attr_set
1593aae38d10SBaptiste Daroussin		wattr_get
1594aae38d10SBaptiste Daroussin		wattr_on
1595aae38d10SBaptiste Daroussin		wattr_off
1596aae38d10SBaptiste Daroussin		wattr_set
1597aae38d10SBaptiste Daroussin		wchgat
1598aae38d10SBaptiste Daroussin		wcolor_set
1599aae38d10SBaptiste Daroussin
1600aae38d10SBaptiste Daroussin	+ the TERMINAL structure declared in <term.h> has been made opaque,
1601aae38d10SBaptiste Daroussin	  and its size increased to handle the increased size of color pair
1602aae38d10SBaptiste Daroussin	  and color value, as well as other numeric capabilities.
1603aae38d10SBaptiste Daroussin
1604aae38d10SBaptiste Daroussin	  A few applications required change, e.g., to use def_prog_mode;
1605aae38d10SBaptiste Daroussin	  only one application (tack) is known to have a valid reason for
1606aae38d10SBaptiste Daroussin	  accessing these internal details, and that was addressed by the
1607aae38d10SBaptiste Daroussin	  release of tack 1.08 in 2017.  Internal functions marked as used
1608aae38d10SBaptiste Daroussin	  by tack will be deprecated in future releases.
1609aae38d10SBaptiste Daroussin
1610aae38d10SBaptiste Daroussin	Added extensions:
1611aae38d10SBaptiste Daroussin
1612aae38d10SBaptiste Daroussin	+ Several new functions were added to manipulate extended color pairs
1613aae38d10SBaptiste Daroussin	  and color values.  These include:
1614aae38d10SBaptiste Daroussin		alloc_pair
1615aae38d10SBaptiste Daroussin		extended_color_content
1616aae38d10SBaptiste Daroussin		extended_pair_content
1617aae38d10SBaptiste Daroussin		extended_slk_color
1618aae38d10SBaptiste Daroussin		find_pair
1619aae38d10SBaptiste Daroussin		free_pair
1620aae38d10SBaptiste Daroussin		init_extended_color
1621aae38d10SBaptiste Daroussin		init_extended_pair
1622aae38d10SBaptiste Daroussin		reset_color_pairs
1623aae38d10SBaptiste Daroussin
1624aae38d10SBaptiste Daroussin	  as well as corresponding sp-functions.
1625aae38d10SBaptiste Daroussin
1626aae38d10SBaptiste Daroussin	+ A new terminfo capability "RGB" tells the ncurses library that the
1627aae38d10SBaptiste Daroussin	  color values are red/green/blue, to eliminate the need for palettes
1628aae38d10SBaptiste Daroussin	  in that special case for the color_content function.
1629aae38d10SBaptiste Daroussin
1630aae38d10SBaptiste Daroussin	Added internal functions (other than "_sp" variants):
1631aae38d10SBaptiste Daroussin		_nc_copy_termtype2
1632aae38d10SBaptiste Daroussin		_nc_export_termtype2
1633aae38d10SBaptiste Daroussin		_nc_fallback2
1634aae38d10SBaptiste Daroussin		_nc_find_prescr
1635aae38d10SBaptiste Daroussin		_nc_forget_prescr
1636aae38d10SBaptiste Daroussin		_nc_free_termtype2
1637aae38d10SBaptiste Daroussin		_nc_read_entry2
1638aae38d10SBaptiste Daroussin		_nc_write_object
1639aae38d10SBaptiste Daroussin
1640aae38d10SBaptiste Daroussin	Removed internal functions:
1641aae38d10SBaptiste Daroussin		_nc_check_termtype
1642aae38d10SBaptiste Daroussin		_nc_resolve_uses
1643aae38d10SBaptiste Daroussin
1644aae38d10SBaptiste Daroussin	Modified internal functions:
1645aae38d10SBaptiste Daroussin
1646aae38d10SBaptiste Daroussin	+ symbols are used by tic/infocmp/toe:
1647aae38d10SBaptiste Daroussin		_nc_align_termtype - change parameters to TERMTYPE2*
1648aae38d10SBaptiste Daroussin		_nc_check_termtype2 - change parameter to TERMTYPE2*
1649aae38d10SBaptiste Daroussin		_nc_read_file_entry - change parameter to TERMTYPE2*
1650aae38d10SBaptiste Daroussin		_nc_read_termtype - change parameter to TERMTYPE2*
1651aae38d10SBaptiste Daroussin		_nc_trim_sgr0 - change parameter to TERMTYPE2*
1652aae38d10SBaptiste Daroussin		_nc_write_entry - change parameter to TERMTYPE2*
1653aae38d10SBaptiste Daroussin
1654aae38d10SBaptiste Daroussin	+ symbols used only within the library:
1655aae38d10SBaptiste Daroussin		_nc_fallback - change return type to TERMTYPE2*
1656aae38d10SBaptiste Daroussin		_nc_init_termtype - change parameter to TERMTYPE2*
1657aae38d10SBaptiste Daroussin
1658aae38d10SBaptiste Daroussin    6.0 (Aug 08, 2015)
1659aae38d10SBaptiste Daroussin	Interface changes:
1660aae38d10SBaptiste Daroussin
1661aae38d10SBaptiste Daroussin	+ The 6.0 ABI modifies the defaults for these configure options:
1662aae38d10SBaptiste Daroussin	   --enable-const
1663aae38d10SBaptiste Daroussin	   --enable-ext-colors
1664aae38d10SBaptiste Daroussin	   --enable-ext-mouse
1665aae38d10SBaptiste Daroussin	   --enable-ext-putwin
1666aae38d10SBaptiste Daroussin	   --enable-interop
1667aae38d10SBaptiste Daroussin	   --enable-lp64
1668aae38d10SBaptiste Daroussin	   --enable-sp-funcs
1669aae38d10SBaptiste Daroussin	   --with-chtype=uint32_t
1670aae38d10SBaptiste Daroussin	   --with-mmask_t=uint32_t
1671aae38d10SBaptiste Daroussin	   --with-tparm-arg=intptr_t
1672aae38d10SBaptiste Daroussin
1673aae38d10SBaptiste Daroussin	+ ncurses supports symbol versioning.  If you use this feature, about
1674aae38d10SBaptiste Daroussin	  half of the "_nc_" private symbols are changed to local symbols.
1675aae38d10SBaptiste Daroussin
1676aae38d10SBaptiste Daroussin	+ a few applications may need to explicitly flush the standard output
1677aae38d10SBaptiste Daroussin	  when switching between printf's and (curses) printw.
1678aae38d10SBaptiste Daroussin
1679aae38d10SBaptiste Daroussin	Added extensions:
1680aae38d10SBaptiste Daroussin
1681aae38d10SBaptiste Daroussin	+ use_tioctl is an improvement over use_env
1682aae38d10SBaptiste Daroussin
1683aae38d10SBaptiste Daroussin	+ added wgetdelay to support the NCURSES_OPAQUE feature.
1684aae38d10SBaptiste Daroussin
1685aae38d10SBaptiste Daroussin	Added internal functions (other than "_sp" variants):
1686aae38d10SBaptiste Daroussin		_nc_init_termtype
1687aae38d10SBaptiste Daroussin		_nc_mvcur
1688aae38d10SBaptiste Daroussin		_nc_putchar
1689aae38d10SBaptiste Daroussin		_nc_setenv_num
1690aae38d10SBaptiste Daroussin		_nc_trace_mmask_t
1691aae38d10SBaptiste Daroussin
1692aae38d10SBaptiste Daroussin	Removed internal functions:
1693aae38d10SBaptiste Daroussin		none
1694aae38d10SBaptiste Daroussin
1695aae38d10SBaptiste Daroussin	Modified internal functions:
1696aae38d10SBaptiste Daroussin		_nc_do_color - change parameters from short/bool to int
1697aae38d10SBaptiste Daroussin		_nc_keypad - change parameter from bool to int
1698aae38d10SBaptiste Daroussin		_nc_setupscreen - change parameter from bool to int
1699aae38d10SBaptiste Daroussin		_nc_signal_handler - change parameter from bool to int
1700aae38d10SBaptiste Daroussin
1701aae38d10SBaptiste Daroussin    5.9 (Apr 04, 2011)
170206bfebdeSXin LI    5.8 (Feb 26, 2011)
170306bfebdeSXin LI	Interface changes:
170406bfebdeSXin LI
170506bfebdeSXin LI	+ add an alternate library configuration, i.e., "terminal driver" to
170606bfebdeSXin LI	  support port to Windows, built with MinGW.  There are two drivers
170706bfebdeSXin LI	  (terminfo and Windows console).  The terminfo driver works on other
170806bfebdeSXin LI	  platforms.
170906bfebdeSXin LI
171006bfebdeSXin LI	+ add a new set of functions which accept a SCREEN* parameter, in
171106bfebdeSXin LI	  contrast with the original set which use the global value "sp".
171206bfebdeSXin LI	  By default, these names end with "_sp", and are otherwise
171306bfebdeSXin LI	  functionally identical with the originals.
171406bfebdeSXin LI
171506bfebdeSXin LI	  In addition to the "_sp" functions, there are a few new functions
171606bfebdeSXin LI	  associated with this feature:  ceiling_panel, ground_panel,
171706bfebdeSXin LI	  new_prescr.
171806bfebdeSXin LI
171906bfebdeSXin LI	  If the library is not built with the sp-funcs extension, there
172006bfebdeSXin LI	  are no related interface changes.
172106bfebdeSXin LI
172206bfebdeSXin LI	+ add tiparm function based on review of X/Open Curses Issue 7.
172306bfebdeSXin LI
172406bfebdeSXin LI	+ change internal _nc_has_mouse function to public has_mouse function
172506bfebdeSXin LI
172606bfebdeSXin LI	Added extensions:
172706bfebdeSXin LI
172806bfebdeSXin LI	+ add a few more functions to support the NCURSES_OPAQUE feature:
172906bfebdeSXin LI	  get_escdelay, is_pad, is_subwin
173006bfebdeSXin LI
173106bfebdeSXin LI	Added internal functions (other than "_sp" variants):
173206bfebdeSXin LI		_nc_curscr_of
173306bfebdeSXin LI		_nc_format_slks
173406bfebdeSXin LI		_nc_get_alias_table
173506bfebdeSXin LI		_nc_get_hash_info
173606bfebdeSXin LI		_nc_insert_wch
173706bfebdeSXin LI		_nc_newscr_of
173806bfebdeSXin LI		_nc_outc_wrapper
173906bfebdeSXin LI		_nc_retrace_char
174006bfebdeSXin LI		_nc_retrace_int_attr_t
174106bfebdeSXin LI		_nc_retrace_mmask_t
174206bfebdeSXin LI		_nc_setup_tinfo
174306bfebdeSXin LI		_nc_stdscr_of
174406bfebdeSXin LI		_nc_tinfo_cmdch
174506bfebdeSXin LI
174606bfebdeSXin LI	Removed internal functions:
174706bfebdeSXin LI		_nc_makenew (some configurations replace by _nc_makenew_sp)
174806bfebdeSXin LI
174906bfebdeSXin LI	Modified internal functions:
175006bfebdeSXin LI		_nc_UpdateAttrs
175106bfebdeSXin LI		_nc_get_hash_table
175206bfebdeSXin LI		_nc_has_mouse
175306bfebdeSXin LI		_nc_insert_ch
175406bfebdeSXin LI		_nc_wgetch
175506bfebdeSXin LI
17565d08fb1fSRong-En Fan    5.7 (November 2, 2008)
17575d08fb1fSRong-En Fan	Interface changes:
17585d08fb1fSRong-En Fan
17595d08fb1fSRong-En Fan	+ generate linkable stubs for some macros:
17605d08fb1fSRong-En Fan		getattrs
17615d08fb1fSRong-En Fan
17625d08fb1fSRong-En Fan	+ Add new library configuration for tic-library (the non-curses portion
17635d08fb1fSRong-En Fan	  of the ncurses library used for the tic program as well as some
17645d08fb1fSRong-En Fan	  others such as tack.  There is no API change, but makefiles would be
17655d08fb1fSRong-En Fan	  changed to use the tic-library built separately.
17665d08fb1fSRong-En Fan
17675d08fb1fSRong-En Fan	  tack, distributed separately from ncurses, uses some of the internal
17685d08fb1fSRong-En Fan	  _nc_XXX functions, which are declared in the tic.h header file.
17695d08fb1fSRong-En Fan
17705d08fb1fSRong-En Fan	  The reason for providing this separate library is that none of the
17715d08fb1fSRong-En Fan	  functions in it are suitable for threaded applications.
17725d08fb1fSRong-En Fan
17735d08fb1fSRong-En Fan	+ Add new library configuration (ncursest, ncurseswt) which provides
17745d08fb1fSRong-En Fan	  rudimentary support for POSIX threads.  This introduces opaque
17755d08fb1fSRong-En Fan	  access functions to the WINDOW structure and adds a parameter to
17765d08fb1fSRong-En Fan	  several internal functions.
17775d08fb1fSRong-En Fan
17785d08fb1fSRong-En Fan	+ move most internal variables (except tic-library) into data blocks
17795d08fb1fSRong-En Fan	  _nc_globals and _nc_prescreen to simplify analysis.  Those were
17805d08fb1fSRong-En Fan	  globally accessible, but since they were not part of the documented
17815d08fb1fSRong-En Fan	  API, there is no ABI change.
17825d08fb1fSRong-En Fan
17835d08fb1fSRong-En Fan	+ changed static tables of strings to be indices into long strings, to
17845d08fb1fSRong-En Fan	  improve startup performance.  This changes parameter lists for some
17855d08fb1fSRong-En Fan	  of the internal functions.
17865d08fb1fSRong-En Fan
17875d08fb1fSRong-En Fan	Added extensions:
17885d08fb1fSRong-En Fan
17895d08fb1fSRong-En Fan	+ add NCURSES_OPAQUE definition in curses.h to control whether internal
17905d08fb1fSRong-En Fan	  details of the WINDOW structure are visible to an application.  This
17915d08fb1fSRong-En Fan	  is always defined when the threaded library is built, and is optional
17925d08fb1fSRong-En Fan	  otherwise.  New functions for this:  is_cleared, is_idcok, is_idlok,
17935d08fb1fSRong-En Fan	  is_immedok, is_keypad, is_leaveok, is_nodelay, is_notimeout,
17945d08fb1fSRong-En Fan	  is_scrollok, is_syncok, wgetparent and wgetscrreg.
17955d08fb1fSRong-En Fan
17965d08fb1fSRong-En Fan	+ the threaded library (ncursest) also disallows direct updating of
17975d08fb1fSRong-En Fan	  global curses-level variables, providing functions (via macros) for
17985d08fb1fSRong-En Fan	  obtaining their value.  A few of those variables can be modified by
17995d08fb1fSRong-En Fan	  the application, using new functions:  set_escdelay, set_tabsize
18005d08fb1fSRong-En Fan
18015d08fb1fSRong-En Fan	+ added functions use_window() and use_screen() which wrap a mutex
18025d08fb1fSRong-En Fan	  (if threading is configured) around a call to a user-supplied
18035d08fb1fSRong-En Fan	  function.
18045d08fb1fSRong-En Fan
18055d08fb1fSRong-En Fan	Added internal functions:
18065d08fb1fSRong-En Fan		_nc_get_alias_table
18075d08fb1fSRong-En Fan		_nc_get_screensize
18085d08fb1fSRong-En Fan		_nc_keyname
18095d08fb1fSRong-En Fan		_nc_screen_of
18105d08fb1fSRong-En Fan		_nc_set_no_padding
18115d08fb1fSRong-En Fan		_nc_tracechar
18125d08fb1fSRong-En Fan		_nc_tracemouse
18135d08fb1fSRong-En Fan		_nc_unctrl
18145d08fb1fSRong-En Fan		_nc_ungetch
18155d08fb1fSRong-En Fan
18165d08fb1fSRong-En Fan		These are used for leak-testing, and are stubs for
18175d08fb1fSRong-En Fan		ABI compatibility when ncurses is not configured for that
18185d08fb1fSRong-En Fan		using the --disable-leaks configure script option:
18195d08fb1fSRong-En Fan
18205d08fb1fSRong-En Fan		_nc_free_and_exit
18215d08fb1fSRong-En Fan		_nc_leaks_tinfo
18225d08fb1fSRong-En Fan
18235d08fb1fSRong-En Fan	Removed internal functions:
18245d08fb1fSRong-En Fan		none
18255d08fb1fSRong-En Fan
18265d08fb1fSRong-En Fan	Modified internal functions:
18275d08fb1fSRong-En Fan		_nc_fifo_dump
18285d08fb1fSRong-En Fan		_nc_find_entry
18295d08fb1fSRong-En Fan		_nc_handle_sigwinch
18305d08fb1fSRong-En Fan		_nc_init_keytry
18315d08fb1fSRong-En Fan		_nc_keypad
18325d08fb1fSRong-En Fan		_nc_locale_breaks_acs
18335d08fb1fSRong-En Fan		_nc_timed_wait
18345d08fb1fSRong-En Fan		_nc_update_screensize
18355d08fb1fSRong-En Fan
18365d08fb1fSRong-En Fan		Use new typedef TRIES to replace "struct tries":
18375d08fb1fSRong-En Fan
18385d08fb1fSRong-En Fan		_nc_add_to_try
18395d08fb1fSRong-En Fan		_nc_expand_try
18405d08fb1fSRong-En Fan		_nc_remove_key
18415d08fb1fSRong-En Fan		_nc_remove_string
18425d08fb1fSRong-En Fan		_nc_trace_tries
18435d08fb1fSRong-En Fan
18444a1a9510SRong-En Fan    5.6 (December 17, 2006)
18454a1a9510SRong-En Fan	Interface changes:
18464a1a9510SRong-En Fan
18474a1a9510SRong-En Fan	+ generate linkable stubs for some macros:
18484a1a9510SRong-En Fan
18494a1a9510SRong-En Fan	  getbegx, getbegy, getcurx, getcury, getmaxx, getmaxy, getparx,
18504a1a9510SRong-En Fan	  getpary, getpary,
18514a1a9510SRong-En Fan
18524a1a9510SRong-En Fan	  and (for libncursesw)
18534a1a9510SRong-En Fan
18544a1a9510SRong-En Fan	  wgetbkgrnd
18554a1a9510SRong-En Fan
18564a1a9510SRong-En Fan	Added extensions:
18574a1a9510SRong-En Fan		nofilter()
18584a1a9510SRong-En Fan		use_legacy_coding()
18594a1a9510SRong-En Fan
18604a1a9510SRong-En Fan	Added internal functions:
18614a1a9510SRong-En Fan		_nc_first_db
18624a1a9510SRong-En Fan		_nc_get_source
18634a1a9510SRong-En Fan		_nc_handle_sigwinch
18644a1a9510SRong-En Fan		_nc_is_abs_path
18654a1a9510SRong-En Fan		_nc_is_dir_path
18664a1a9510SRong-En Fan		_nc_is_file_path
18674a1a9510SRong-En Fan		_nc_keep_tic_dir
18684a1a9510SRong-En Fan		_nc_keep_tic_dir
18694a1a9510SRong-En Fan		_nc_last_db
18704a1a9510SRong-En Fan		_nc_next_db
18714a1a9510SRong-En Fan		_nc_read_termtype
18724a1a9510SRong-En Fan		_nc_tic_dir
18734a1a9510SRong-En Fan
18744a1a9510SRong-En Fan		Also (if using the hashed database configuration):
18754a1a9510SRong-En Fan
18764a1a9510SRong-En Fan		_nc_db_close
18774a1a9510SRong-En Fan		_nc_db_first
18784a1a9510SRong-En Fan		_nc_db_get
18794a1a9510SRong-En Fan		_nc_db_have_data
18804a1a9510SRong-En Fan		_nc_db_have_index
18814a1a9510SRong-En Fan		_nc_db_next
18824a1a9510SRong-En Fan		_nc_db_open
18834a1a9510SRong-En Fan		_nc_db_put
18844a1a9510SRong-En Fan
18854a1a9510SRong-En Fan		otherwise
18864a1a9510SRong-En Fan
18874a1a9510SRong-En Fan		_nc_hashed_db
18884a1a9510SRong-En Fan
18894a1a9510SRong-En Fan	Removed internal functions:
18904a1a9510SRong-En Fan		none
18914a1a9510SRong-En Fan
18924a1a9510SRong-En Fan	Modified internal functions:
18934a1a9510SRong-En Fan		_nc_add_to_try
18944a1a9510SRong-En Fan		_nc_do_color
18954a1a9510SRong-En Fan		_nc_expand_try
18964a1a9510SRong-En Fan		_nc_remove_key
18974a1a9510SRong-En Fan		_nc_setupscreen
18984a1a9510SRong-En Fan
18994a1a9510SRong-En Fan    5.5 (October 10, 2005)
19004a1a9510SRong-En Fan	Interface changes:
19014a1a9510SRong-En Fan
19024a1a9510SRong-En Fan	+ terminfo installs "xterm-new" as "xterm" entry rather than
19034a1a9510SRong-En Fan	  "xterm-old" (aka xterm-r6).
19044a1a9510SRong-En Fan
19054a1a9510SRong-En Fan	+ terminfo data is installed using the tic -x option (few systems
19064a1a9510SRong-En Fan	  still use ncurses 4.2).
19074a1a9510SRong-En Fan
19084a1a9510SRong-En Fan	+ modify C++ binding to work with newer C++ compilers by providing
19094a1a9510SRong-En Fan	  initializers and using modern casts.  Old-style header names are
19104a1a9510SRong-En Fan	  still used in this release to allow compiling with not-so-old
19114a1a9510SRong-En Fan	  compilers.
19124a1a9510SRong-En Fan
19134a1a9510SRong-En Fan	+ form and menu libraries now work with wide-character data.
19144a1a9510SRong-En Fan	  Applications which bypassed the form library and manipulated the
19154a1a9510SRong-En Fan	  FIELD.buf data directly will not work properly with libformw, since
19164a1a9510SRong-En Fan	  that no longer points to an array of char.  The set_field_buffer()
19174a1a9510SRong-En Fan	  and field_buffer() functions translate to/from the actual field
19184a1a9510SRong-En Fan	  data.
19194a1a9510SRong-En Fan
19204a1a9510SRong-En Fan	+ change SP->_current_attr to a pointer, adjust ifdef's to ensure that
19214a1a9510SRong-En Fan	  libtinfo.so and libtinfow.so have the same ABI.  The reason for this
19224a1a9510SRong-En Fan	  is that the corresponding data which belongs to the upper-level
19234a1a9510SRong-En Fan	  ncurses library has a different size in each model.
19244a1a9510SRong-En Fan
19254a1a9510SRong-En Fan	+ winnstr() now returns multibyte character strings for the
19264a1a9510SRong-En Fan	  wide-character configuration.
19274a1a9510SRong-En Fan
19284a1a9510SRong-En Fan	+ assume_default_colors() no longer requires that use_default_colors()
19294a1a9510SRong-En Fan	  be called first.
19304a1a9510SRong-En Fan
19314a1a9510SRong-En Fan	+ data_ahead() now works with wide-characters.
19324a1a9510SRong-En Fan
19334a1a9510SRong-En Fan	+ slk_set() and slk_wset() now accept and store multibyte or
19344a1a9510SRong-En Fan	  multicolumn characters.
19354a1a9510SRong-En Fan
19364a1a9510SRong-En Fan	+ start_color() now returns OK if colors have already been started.
19374a1a9510SRong-En Fan	  start_color() also returns ERR if it cannot allocate memory.
19384a1a9510SRong-En Fan
19394a1a9510SRong-En Fan	+ pair_content() now returns -1 for consistency with init_pair() if it
19404a1a9510SRong-En Fan	  corresponds to the default-color.
19414a1a9510SRong-En Fan
19424a1a9510SRong-En Fan	+ unctrl() now returns null if its parameter does not correspond
19434a1a9510SRong-En Fan	  to an unsigned char.
19444a1a9510SRong-En Fan
19454a1a9510SRong-En Fan	Added extensions:
19464a1a9510SRong-En Fan		Experimental mouse version 2 supports wheel mice with buttons
19474a1a9510SRong-En Fan		4 and 5.  This requires ABI 6 because it modifies the encoding
19484a1a9510SRong-En Fan		of mouse events.
19494a1a9510SRong-En Fan
19504a1a9510SRong-En Fan		Experimental extended colors allows encoding of 256 foreground
19514a1a9510SRong-En Fan		and background colors, e.g., with the xterm-256color or
19524a1a9510SRong-En Fan		xterm-88color terminfo entries.  This requires ABI 6 because
19534a1a9510SRong-En Fan		it changes the size of cchar_t.
19544a1a9510SRong-En Fan
19554a1a9510SRong-En Fan	Added internal functions:
19564a1a9510SRong-En Fan		_nc_check_termtype2
19574a1a9510SRong-En Fan		_nc_resolve_uses2
19584a1a9510SRong-En Fan		_nc_retrace_cptr
19594a1a9510SRong-En Fan		_nc_retrace_cvoid_ptr
19604a1a9510SRong-En Fan		_nc_retrace_void_ptr
19614a1a9510SRong-En Fan		_nc_setup_term
19624a1a9510SRong-En Fan
19634a1a9510SRong-En Fan	Removed internal functions:
19644a1a9510SRong-En Fan		none
19654a1a9510SRong-En Fan
19664a1a9510SRong-En Fan	Modified internal functions:
19674a1a9510SRong-En Fan		_nc_insert_ch
19684a1a9510SRong-En Fan		_nc_save_str
19694a1a9510SRong-En Fan		_nc_trans_string
19704a1a9510SRong-En Fan
19714a1a9510SRong-En Fan    5.4 (February 8, 2004)
19724a1a9510SRong-En Fan	Interface changes:
19734a1a9510SRong-En Fan
19744a1a9510SRong-En Fan	+ add the remaining functions for X/Open curses wide-character support.
19754a1a9510SRong-En Fan	  These are only available if the library is configured using the
19764a1a9510SRong-En Fan	  --enable-widec option.
19774a1a9510SRong-En Fan		pecho_wchar()
19784a1a9510SRong-En Fan		slk_wset()
19794a1a9510SRong-En Fan
19804a1a9510SRong-En Fan	+ write getyx() and related 2-return macros in terms of getcury(),
19814a1a9510SRong-En Fan	  getcurx(), etc.
19824a1a9510SRong-En Fan
19834a1a9510SRong-En Fan	+ simplify ifdef for bool declaration in curses.h
19844a1a9510SRong-En Fan
19854a1a9510SRong-En Fan	+ modify ifdef's in curses.h that disabled use of __attribute__() for
19864a1a9510SRong-En Fan	  g++, since recent versions implement the cases which ncurses uses.
19874a1a9510SRong-En Fan
19884a1a9510SRong-En Fan	+ change some interfaces to use const:
19894a1a9510SRong-En Fan		define_key()
19904a1a9510SRong-En Fan		mvprintw()
19914a1a9510SRong-En Fan		mvwprintw()
19924a1a9510SRong-En Fan		printw()
19934a1a9510SRong-En Fan		vw_printw()
19944a1a9510SRong-En Fan		winsnstr()
19954a1a9510SRong-En Fan		wprintw()
19964a1a9510SRong-En Fan
19974a1a9510SRong-En Fan	Added extensions:
19984a1a9510SRong-En Fan		key_defined()
19994a1a9510SRong-En Fan
20004a1a9510SRong-En Fan	Added internal functions:
20014a1a9510SRong-En Fan		_nc_get_locale()
20024a1a9510SRong-En Fan		_nc_insert_ch()
20034a1a9510SRong-En Fan		_nc_is_charable()	wide
20044a1a9510SRong-En Fan		_nc_locale_breaks_acs()
20054a1a9510SRong-En Fan		_nc_pathlast()
20064a1a9510SRong-En Fan		_nc_to_char()		wide
20074a1a9510SRong-En Fan		_nc_to_widechar()	wide
20084a1a9510SRong-En Fan		_nc_tparm_analyze()
20094a1a9510SRong-En Fan		_nc_trace_bufcat()	debug
20104a1a9510SRong-En Fan		_nc_unicode_locale()
20114a1a9510SRong-En Fan
20124a1a9510SRong-En Fan	Removed internal functions:
20134a1a9510SRong-En Fan		_nc_outstr()
20144a1a9510SRong-En Fan		_nc_sigaction()
20154a1a9510SRong-En Fan
20164a1a9510SRong-En Fan	Modified internal functions:
20174a1a9510SRong-En Fan		_nc_remove_string()
20184a1a9510SRong-En Fan		_nc_retrace_chtype()
20194a1a9510SRong-En Fan
20204a1a9510SRong-En Fan    5.3 (October 12, 2002)
20214a1a9510SRong-En Fan	Interface changes:
20224a1a9510SRong-En Fan
20234a1a9510SRong-En Fan	+ change type for bool used in headers to NCURSES_BOOL, which usually
20244a1a9510SRong-En Fan	  is the same as the compiler's definition for 'bool'.
20254a1a9510SRong-En Fan
20264a1a9510SRong-En Fan	+ add all but two functions for X/Open curses wide-character support.
20274a1a9510SRong-En Fan	  These are only available if the library is configured using the
20284a1a9510SRong-En Fan	  --enable-widec option.  Missing functions are
20294a1a9510SRong-En Fan		pecho_wchar()
20304a1a9510SRong-En Fan		slk_wset()
20314a1a9510SRong-En Fan
20324a1a9510SRong-En Fan	+ add environment variable $NCURSES_ASSUMED_COLORS to modify the
20334a1a9510SRong-En Fan	  assume_default_colors() extension.
20344a1a9510SRong-En Fan
20354a1a9510SRong-En Fan	Added extensions:
20364a1a9510SRong-En Fan		is_term_resized()
20374a1a9510SRong-En Fan		resize_term()
20384a1a9510SRong-En Fan
20394a1a9510SRong-En Fan	Added internal functions:
20404a1a9510SRong-En Fan		_nc_altcharset_name()	debug
20414a1a9510SRong-En Fan		_nc_reset_colors()
20424a1a9510SRong-En Fan		_nc_retrace_bool()	debug
20434a1a9510SRong-En Fan		_nc_retrace_unsigned()	debug
20444a1a9510SRong-En Fan		_nc_rootname()
20454a1a9510SRong-En Fan		_nc_trace_ttymode()	debug
20464a1a9510SRong-En Fan		_nc_varargs()		debug
20474a1a9510SRong-En Fan		_nc_visbufn()		debug
20484a1a9510SRong-En Fan		_nc_wgetch()
20494a1a9510SRong-En Fan
20504a1a9510SRong-En Fan	Removed internal functions:
20514a1a9510SRong-En Fan		_nc_background()
20524a1a9510SRong-En Fan
20534a1a9510SRong-En Fan	Modified internal functions:
20544a1a9510SRong-En Fan		_nc_freeall()		debug
20554a1a9510SRong-En Fan
20567a69bbfbSPeter Wemm    5.2 (October 21, 2000)
20577a69bbfbSPeter Wemm	Interface changes:
20587a69bbfbSPeter Wemm
20597a69bbfbSPeter Wemm	+ revert termcap ospeed variable to 'short' (see discussion of the
20607a69bbfbSPeter Wemm	  --with-ospeed configure option).
20617a69bbfbSPeter Wemm
206218259542SPeter Wemm    5.1 (July 8, 2000)
206318259542SPeter Wemm	Interface changes:
206418259542SPeter Wemm
206518259542SPeter Wemm	+ made the extended terminal capabilities
206618259542SPeter Wemm	  (configure --enable-tcap-names) a standard feature.  This should
206718259542SPeter Wemm	  be transparent to applications that do not require it.
206818259542SPeter Wemm
206918259542SPeter Wemm	+ removed the trace() function and related trace support from the
207018259542SPeter Wemm	  production library.
207118259542SPeter Wemm
207218259542SPeter Wemm	+ modified curses.h.in, undef'ing some symbols to avoid conflict
207318259542SPeter Wemm	  with C++ STL.
207418259542SPeter Wemm
207518259542SPeter Wemm	Added extensions:  assume_default_colors().
207618259542SPeter Wemm
207718259542SPeter Wemm    5.0 (October 23, 1999)
207815589c42SPeter Wemm	Interface changes:
207915589c42SPeter Wemm
208015589c42SPeter Wemm	+ implemented the wcolor_set() and slk_color() functions.
208115589c42SPeter Wemm
208215589c42SPeter Wemm	+ move macro winch to a function, to hide details of struct ldat
208315589c42SPeter Wemm
208415589c42SPeter Wemm	+ corrected prototypes for slk_* functions, using chtype rather than
208515589c42SPeter Wemm	  attr_t.
208615589c42SPeter Wemm
208715589c42SPeter Wemm	+ the slk_attr_{set,off,on} functions need an additional void*
208815589c42SPeter Wemm	  parameter according to XSI.
208915589c42SPeter Wemm
209015589c42SPeter Wemm	+ modified several prototypes to correspond with 1997 version of X/Open
209115589c42SPeter Wemm	  Curses:  [w]attr_get(), [w]attr_set(), border_set() have different
209215589c42SPeter Wemm	  parameters.  Some functions were renamed or misspelled:
209315589c42SPeter Wemm	  erase_wchar(), in_wchntr(), mvin_wchntr().  Some developers have used
209415589c42SPeter Wemm	  attr_get().
209515589c42SPeter Wemm
209615589c42SPeter Wemm	Added extensions:  keybound(), curses_version().
209715589c42SPeter Wemm
209815589c42SPeter Wemm	Terminfo database changes:
209915589c42SPeter Wemm
210015589c42SPeter Wemm	+ change translation for termcap 'rs' to terminfo 'rs2', which is
210115589c42SPeter Wemm	  the documented equivalent, rather than 'rs1'.
210215589c42SPeter Wemm
210315589c42SPeter Wemm	The problems are subtler in recent releases.
210415589c42SPeter Wemm
210515589c42SPeter Wemm	a) This release provides users with the ability to define their own
210615589c42SPeter Wemm	   terminal capability extensions, like termcap.  To accomplish this,
210715589c42SPeter Wemm	   we redesigned the TERMTYPE struct (in term.h).  Very few
210815589c42SPeter Wemm	   applications use this struct.  They must be recompiled to work with
210915589c42SPeter Wemm	   the 5.0 library.
211015589c42SPeter Wemm
211115589c42SPeter Wemm	a) If you use the extended terminfo names (i.e., you used configure
211215589c42SPeter Wemm	   --enable-tcap-names), the resulting terminfo database can have some
211315589c42SPeter Wemm	   entries which are not readable by older versions of ncurses.  This
211415589c42SPeter Wemm	   is a bug in the older versions:
211515589c42SPeter Wemm
211615589c42SPeter Wemm	   + the terminfo database stores booleans, numbers and strings in
211715589c42SPeter Wemm	     arrays.  The capabilities that are listed in the arrays are
211815589c42SPeter Wemm	     specified by X/Open.  ncurses recognizes a number of obsolete and
211915589c42SPeter Wemm	     extended names which are stored past the end of the specified
212015589c42SPeter Wemm	     entries.
212115589c42SPeter Wemm
212215589c42SPeter Wemm	   + a change to read_entry.c in 951001 made the library do an lseek()
212315589c42SPeter Wemm	     call incorrectly skipping data which is already read from the
212415589c42SPeter Wemm	     string array.  This happens when the number of strings in the
212515589c42SPeter Wemm	     terminfo data file is greater than STRCOUNT, the number of
212615589c42SPeter Wemm	     specified and obsolete or extended strings.
212715589c42SPeter Wemm
212815589c42SPeter Wemm	   + as part of alignment with the X/Open final specification, in the
212915589c42SPeter Wemm	     990109 patch we added two new terminfo capabilities:
213015589c42SPeter Wemm	     set_a_attributes and set_pglen_inch).  This makes the indices for
213115589c42SPeter Wemm	     the obsolete and extended capabilities shift up by 2.
213215589c42SPeter Wemm
213315589c42SPeter Wemm	   + the last two capabilities in the obsolete/extended list are memu
213415589c42SPeter Wemm	     and meml, which are found in most terminfo descriptions for xterm.
213515589c42SPeter Wemm
213615589c42SPeter Wemm	     When trying to read this terminfo entry, the spurious lseek()
213715589c42SPeter Wemm	     causes the library to attempt to read the final portion of the
213815589c42SPeter Wemm	     terminfo data (the text of the string capabilities) 4 characters
213915589c42SPeter Wemm	     past its starting point, and reads 4 characters too few.  The
214015589c42SPeter Wemm	     library rejects the data, and applications are unable to
214115589c42SPeter Wemm	     initialize that terminal type.
214215589c42SPeter Wemm
214315589c42SPeter Wemm	   FIX: remove memu and meml from the xterm description.  They are
214415589c42SPeter Wemm	   obsolete, not used by ncurses.  (It appears that the feature was
214515589c42SPeter Wemm	   added to xterm to make it more like hpterm).
214615589c42SPeter Wemm
214715589c42SPeter Wemm	   This is not a problem if you do not use the -x option of tic to
214815589c42SPeter Wemm	   create a terminfo database with extended names.  Note that the
214915589c42SPeter Wemm	   user-defined terminal capabilities are not affected by this bug,
215015589c42SPeter Wemm	   since they are stored in a table after the older terminfo data ends,
215115589c42SPeter Wemm	   and are invisible to the older libraries.
215215589c42SPeter Wemm
215315589c42SPeter Wemm	c) Some developers did not wish to use the C++ binding, and used the
215415589c42SPeter Wemm	   configure --without-cxx option.  This causes problems if someone
215515589c42SPeter Wemm	   uses the ncurses library from C++ because that configure test
215615589c42SPeter Wemm	   determines the type for C++'s bool and makes ncurses match it, since
215715589c42SPeter Wemm	   both C++ and curses are specified to declare bool.  Calling ncurses
215815589c42SPeter Wemm	   functions with the incorrect type for bool will cause execution
215915589c42SPeter Wemm	   errors.  In 5.0 we added a configure option "--without-cxx-binding"
216015589c42SPeter Wemm	   which controls whether the binding itself is built and installed.
216115589c42SPeter Wemm
216218259542SPeter Wemm    4.2 (March 2, 1998)
216315589c42SPeter Wemm	Interface changes:
216415589c42SPeter Wemm
216515589c42SPeter Wemm	+ correct prototype for termattrs() as per XPG4 version 2.
216615589c42SPeter Wemm
216715589c42SPeter Wemm	+ add placeholder prototypes for color_set(), erasewchar(),
216815589c42SPeter Wemm	  term_attrs(), wcolor_set() as per XPG4 version 2.
216915589c42SPeter Wemm
217015589c42SPeter Wemm	+ add macros getcur[xy] getbeg[xy] getpar[xy], which are defined in
217115589c42SPeter Wemm	  SVr4 headers.
217215589c42SPeter Wemm
217315589c42SPeter Wemm	New extensions: keyok() and define_key().
217415589c42SPeter Wemm
217515589c42SPeter Wemm	Terminfo database changes:
217615589c42SPeter Wemm
217715589c42SPeter Wemm	+ corrected definition in curses.h for ACS_LANTERN, which was 'I'
217815589c42SPeter Wemm	  rather than 'i'.
217915589c42SPeter Wemm
218015589c42SPeter Wemm    4.1 (May 15, 1997)
218115589c42SPeter Wemm
218215589c42SPeter Wemm	We added these extensions:  use_default_colors().  Also added
218315589c42SPeter Wemm	configure option --enable-const, to support the use of const where
218415589c42SPeter Wemm	X/Open should have, but did not, specify.
218515589c42SPeter Wemm
218615589c42SPeter Wemm	The terminfo database content changed the representation of color for
218715589c42SPeter Wemm	most entries that use ANSI colors.  SVr4 curses treats the setaf/setab
218815589c42SPeter Wemm	and setf/setb capabilities differently, interchanging the red/blue
218915589c42SPeter Wemm	colors in the latter.
219015589c42SPeter Wemm
219115589c42SPeter Wemm    4.0 (December 24, 1996)
219215589c42SPeter Wemm
219306bfebdeSXin LI	We bumped to version 4.0 because the newly released Linux dynamic
219406bfebdeSXin LI	loader (ld.so.1.8.5) did not load shared libraries whose ABI and REL
219515589c42SPeter Wemm	versions were inconsistent.  At that point, ncurses ABI was 3.4 and the
219615589c42SPeter Wemm	REL was 1.9.9g, so we made them consistent.
219715589c42SPeter Wemm
219815589c42SPeter Wemm    1.9.9g (December 1, 1996)
219915589c42SPeter Wemm
220015589c42SPeter Wemm	This fixed most of the problems with 1.9.9e, and made these interface
220115589c42SPeter Wemm	changes:
220215589c42SPeter Wemm
220315589c42SPeter Wemm	+ remove tparam(), which had been provided for compatibility with
220415589c42SPeter Wemm	  some termcap.  tparm() is standard, and does not conflict with
220515589c42SPeter Wemm	  application's fallback for missing tparam().
220615589c42SPeter Wemm
220715589c42SPeter Wemm	+ turn off hardware echo in initscr().  This changes the sense of the
220815589c42SPeter Wemm	  echo() function, which was initialized to echoing rather than
220915589c42SPeter Wemm	  nonechoing (the latter is specified).  There were several other
221015589c42SPeter Wemm	  corrections to the terminal I/O settings which cause applications to
221115589c42SPeter Wemm	  behave differently.
221215589c42SPeter Wemm
221315589c42SPeter Wemm	+ implemented several functions (such as attr_on()) which were
221415589c42SPeter Wemm	  available only as macros.
221515589c42SPeter Wemm
221615589c42SPeter Wemm	+ corrected several typos in curses.h.in (i.e., the mvXXXX macros).
221715589c42SPeter Wemm
221815589c42SPeter Wemm	+ corrected prototypes for delay_output(),
221915589c42SPeter Wemm	  has_color, immedok() and idcok().
222015589c42SPeter Wemm
222115589c42SPeter Wemm	+ corrected misspelled getbkgd().  Some applications used the
222215589c42SPeter Wemm	  misspelled name.
222315589c42SPeter Wemm
222415589c42SPeter Wemm	+ added _yoffset to WINDOW.  The size of WINDOW does not impact
222515589c42SPeter Wemm	  applications, since they use only pointers to WINDOW structs.
222615589c42SPeter Wemm
222715589c42SPeter Wemm	These changes were made to the terminfo database:
222815589c42SPeter Wemm
222915589c42SPeter Wemm	+ removed boolean 'getm' which was available as an extended name.
223015589c42SPeter Wemm
223115589c42SPeter Wemm	We added these extensions: wresize(), resizeterm(), has_key() and
223215589c42SPeter Wemm	mcprint().
223315589c42SPeter Wemm
223415589c42SPeter Wemm    1.9.9e (March 24, 1996)
223515589c42SPeter Wemm
223615589c42SPeter Wemm	not recommended (a last-minute/untested change left the forms and
223715589c42SPeter Wemm	menus libraries unusable since they do not repaint the screen).
223815589c42SPeter Wemm	Foreground/background colors are combined incorrectly, working properly
223915589c42SPeter Wemm	only on a black background.  When this was released, the X/Open
224015589c42SPeter Wemm	specification was available only in draft form.
224115589c42SPeter Wemm
224215589c42SPeter Wemm	Some applications (such as lxdialog) were "fixed" to work with the
224315589c42SPeter Wemm	incorrect color scheme.
224415589c42SPeter Wemm
224515589c42SPeter Wemm
22467a656419SBaptiste DaroussinFOR SYSTEM INTEGRATORS:
22477a656419SBaptiste Daroussin----------------------
22480e3d5408SPeter Wemm
22490e3d5408SPeter Wemm    Configuration and Installation:
22500e3d5408SPeter Wemm
22514a1a9510SRong-En Fan	On platforms where ncurses is assumed to be installed in /usr/lib,
2252aae38d10SBaptiste Daroussin	the configure script uses "/usr" as a default.  These include any
2253aae38d10SBaptiste Daroussin	that use the Linux kernel, as well as these special cases:
22540e3d5408SPeter Wemm
2255aae38d10SBaptiste Daroussin		FreeBSD, NetBSD, OpenBSD, Cygwin, MinGW
22564a1a9510SRong-En Fan
22574a1a9510SRong-En Fan	For other platforms, the default is "/usr/local".  See the discussion
22584a1a9510SRong-En Fan	of the "--disable-overwrite" option.
22594a1a9510SRong-En Fan
22604a1a9510SRong-En Fan	The location of the terminfo is set indirectly by the "--datadir"
22614a1a9510SRong-En Fan	configure option, e.g., /usr/share/terminfo, given a datadir of
22624a1a9510SRong-En Fan	/usr/share.  You may want to override this if you are installing
22634a1a9510SRong-En Fan	ncurses libraries in nonstandard locations, but wish to share the
22644a1a9510SRong-En Fan	terminfo database.
22654a1a9510SRong-En Fan
22664a1a9510SRong-En Fan	Normally the ncurses library is configured in a pure-terminfo mode;
22674a1a9510SRong-En Fan	that is, with the --disable-termcap option.  This makes the ncurses
22680e3d5408SPeter Wemm	library smaller and faster.  The ncurses library includes a termcap
22694a1a9510SRong-En Fan	emulation that queries the terminfo database, so even applications that
22704a1a9510SRong-En Fan	use raw termcap to query terminal characteristics will win (providing
22714a1a9510SRong-En Fan	you recompile and relink them!).
22720e3d5408SPeter Wemm
22734a1a9510SRong-En Fan	If you must configure with termcap fallback enabled, you may also wish
22744a1a9510SRong-En Fan	to use the --enable-getcap option.  This speeds up termcap-based
22754a1a9510SRong-En Fan	startups, at the expense of not allowing personal termcap entries to
22764a1a9510SRong-En Fan	reference the terminfo tree.  See comments in
22774a1a9510SRong-En Fan	ncurses/tinfo/read_termcap.c for further details.
22780e3d5408SPeter Wemm
22790e3d5408SPeter Wemm	Note that if you have $TERMCAP set, ncurses will use that value
22800e3d5408SPeter Wemm	to locate termcap data.  In particular, running from xterm will
22810e3d5408SPeter Wemm	set $TERMCAP to the contents of the xterm's termcap entry.
22820e3d5408SPeter Wemm	If ncurses sees that, it will not examine /etc/termcap.
22830e3d5408SPeter Wemm
22840e3d5408SPeter Wemm    Keyboard Mapping:
22850e3d5408SPeter Wemm
22860e3d5408SPeter Wemm	The terminfo file assumes that Shift-Tab generates \E[Z (the ECMA-48
22870e3d5408SPeter Wemm	reverse-tabulation sequence) rather than ^I.  Here are the loadkeys -d
22880e3d5408SPeter Wemm	mappings that will set this up:
22890e3d5408SPeter Wemm
22900e3d5408SPeter Wemm		keycode	 15 = Tab	      Tab
22910e3d5408SPeter Wemm			alt     keycode  15 = Meta_Tab
22920e3d5408SPeter Wemm			shift	keycode  15 = F26
22930e3d5408SPeter Wemm		string F26 ="\033[Z"
22940e3d5408SPeter Wemm
22950e3d5408SPeter Wemm    Naming the Console Terminal
22960e3d5408SPeter Wemm
22974a1a9510SRong-En Fan	In various systems there has been a practice of designating the system
2298*21817992SBaptiste Daroussin	console driver type as 'console'.  Please do not do this!  It
22994a1a9510SRong-En Fan	complicates peoples' lives, because it can mean that several different
23004a1a9510SRong-En Fan	terminfo entries from different operating systems all logically want to
2301*21817992SBaptiste Daroussin	be called 'console'.
23020e3d5408SPeter Wemm
23030e3d5408SPeter Wemm	Please pick a name unique to your console driver and set that up
23040e3d5408SPeter Wemm	in the /etc/inittab table or local equivalent.  Send the entry to the
23050e3d5408SPeter Wemm	terminfo maintainer (listed in the misc/terminfo file) to be included
2306*21817992SBaptiste Daroussin	in the terminfo file, if it is not already there.  See the
23070e3d5408SPeter Wemm	term(7) manual page included with this distribution for more on
23080e3d5408SPeter Wemm	conventions for choosing type names.
23090e3d5408SPeter Wemm
23100e3d5408SPeter Wemm	Here are some recommended primary console names:
23110e3d5408SPeter Wemm
23120e3d5408SPeter Wemm		linux	-- Linux console driver
23130e3d5408SPeter Wemm		freebsd	-- FreeBSD
23140e3d5408SPeter Wemm		netbsd	-- NetBSD
23150e3d5408SPeter Wemm		bsdos	-- BSD/OS
23160e3d5408SPeter Wemm
23170e3d5408SPeter Wemm	If you are responsible for integrating ncurses for one of these
231806bfebdeSXin LI	distributions, please either use the recommended name or get back
23190e3d5408SPeter Wemm	to us explaining why you don't want to, so we can work out nomenclature
23200e3d5408SPeter Wemm	that will make users' lives easier rather than harder.
23210e3d5408SPeter Wemm
232215589c42SPeter Wemm
23237a656419SBaptiste DaroussinMODERN XTERM VERSIONS:
232415589c42SPeter Wemm---------------------
232515589c42SPeter Wemm
23260e3d5408SPeter Wemm	The terminfo database file included with this distribution assumes you
23274a1a9510SRong-En Fan	are running a modern xterm based on XFree86 (i.e., xterm-new).  The
23284a1a9510SRong-En Fan	earlier X11R6 entry (xterm-r6) and X11R5 entry (xterm-r5) is provided
23294a1a9510SRong-En Fan	as well.  See the --without-xterm-new configure script option if you
23304a1a9510SRong-En Fan	are unable to update your system.
23310e3d5408SPeter Wemm
233215589c42SPeter Wemm
233315589c42SPeter WemmCONFIGURING FALLBACK ENTRIES:
233415589c42SPeter Wemm----------------------------
233515589c42SPeter Wemm
23360e3d5408SPeter Wemm	In order to support operation of ncurses programs before the terminfo
23370e3d5408SPeter Wemm	tree is accessible (that is, in single-user mode or at OS installation
23380e3d5408SPeter Wemm	time) the ncurses library can be compiled to include an array of
23397a656419SBaptiste Daroussin	pre-fetched fallback entries.
23407a656419SBaptiste Daroussin
23417a656419SBaptiste Daroussin	NOTE: This must be done on a machine which has ncurses' infocmp and
23427a656419SBaptiste Daroussin	terminfo database installed (as well as ncurses' tic and infocmp
23437a656419SBaptiste Daroussin	programs).  That is because the fallback sources are generated and
23447a656419SBaptiste Daroussin	compiled into the library before the build-tree's copy of infocmp is
23457a656419SBaptiste Daroussin	available.
23460e3d5408SPeter Wemm
23470e3d5408SPeter Wemm	These entries are checked by setupterm() only when the conventional
23480e3d5408SPeter Wemm	fetches from the terminfo tree and the termcap fallback (if configured)
23490e3d5408SPeter Wemm	have been tried and failed.  Thus, the presence of a fallback will not
23500e3d5408SPeter Wemm	shadow modifications to the on-disk entry for the same type, when that
23510e3d5408SPeter Wemm	entry is accessible.
23520e3d5408SPeter Wemm
23534a1a9510SRong-En Fan	By default, there are no entries on the fallback list.  After you have
23544a1a9510SRong-En Fan	built the ncurses suite for the first time, you can change the list
23554a1a9510SRong-En Fan	(the process needs infocmp(1)).  To do so, use the script
235673f0a83dSXin LI	ncurses/tinfo/MKfallback.sh.  The configure script option
23574a1a9510SRong-En Fan	--with-fallbacks does this (it accepts a comma-separated list of the
23584a1a9510SRong-En Fan	names you wish, and does not require a rebuild).
23590e3d5408SPeter Wemm
23600e3d5408SPeter Wemm	If you wanted (say) to have linux, vt100, and xterm fallbacks, you
236173f0a83dSXin LI	might use the commands
23620e3d5408SPeter Wemm
23630e3d5408SPeter Wemm		cd ncurses;
236473f0a83dSXin LI		tinfo/MKfallback.sh \
236573f0a83dSXin LI			$TERMINFO \
236673f0a83dSXin LI			../misc/terminfo.src \
236773f0a83dSXin LI			`which tic` \
2368aae38d10SBaptiste Daroussin			`which infocmp` \
236973f0a83dSXin LI			linux vt100 xterm >fallback.c
237073f0a83dSXin LI
2371aae38d10SBaptiste Daroussin	The first four parameters of the script are normally supplied by
237273f0a83dSXin LI	the configured makefiles via the "--with-fallbacks" option.  They
237373f0a83dSXin LI	are
237473f0a83dSXin LI
237573f0a83dSXin LI		1) the location of the terminfo database
237673f0a83dSXin LI		2) the source for the terminfo entries
237773f0a83dSXin LI		3) the location of the tic program, used to create a terminfo
237873f0a83dSXin LI		   database.
2379aae38d10SBaptiste Daroussin		4) the location of the infocmp program, used to print a terminfo
2380aae38d10SBaptiste Daroussin		   description.
23810e3d5408SPeter Wemm
23820e3d5408SPeter Wemm	Then just rebuild and reinstall the library as you would normally.
23830e3d5408SPeter Wemm	You can restore the default empty fallback list with
23840e3d5408SPeter Wemm
238573f0a83dSXin LI		tinfo/MKfallback.sh \
238673f0a83dSXin LI			$TERMINFO \
238773f0a83dSXin LI			../misc/terminfo.src \
238873f0a83dSXin LI			`which tic` \
2389aae38d10SBaptiste Daroussin			`which infocmp` \
239073f0a83dSXin LI			>fallback.c
23910e3d5408SPeter Wemm
23920e3d5408SPeter Wemm	The overhead for an empty fallback list is one trivial stub function.
2393aae38d10SBaptiste Daroussin	Any non-empty fallback list is const'd and therefore lives in shareable
23940e3d5408SPeter Wemm	text space.  You can look at the comment trailing each initializer in
23950e3d5408SPeter Wemm	the generated ncurses/fallback.c file to see the core cost of the
23960e3d5408SPeter Wemm	fallbacks.  A good rule of thumb for modern vt100-like entries is that
23970e3d5408SPeter Wemm	each one will cost about 2.5K of text space.
23980e3d5408SPeter Wemm
239915589c42SPeter Wemm
24000e3d5408SPeter WemmBSD CONVERSION NOTES:
240115589c42SPeter Wemm--------------------
240215589c42SPeter Wemm
24030e3d5408SPeter Wemm	If you need to support really ancient BSD programs, you probably
24040e3d5408SPeter Wemm	want to configure with the --enable-bsdpad option.  What this does
24050e3d5408SPeter Wemm	is enable code in tputs() that recognizes a numeric prefix on a
24060e3d5408SPeter Wemm	capability as a request for that much trailing padding in milliseconds.
24070e3d5408SPeter Wemm	There are old BSD programs that do things like tputs("50").
24080e3d5408SPeter Wemm
24090e3d5408SPeter Wemm	(If you are distributing ncurses as a support-library component of
24100e3d5408SPeter Wemm	an application you probably want to put the remainder of this section
24110e3d5408SPeter Wemm	in the package README file.)
24120e3d5408SPeter Wemm
24130e3d5408SPeter Wemm	The following note applies only if you have configured ncurses with
24140e3d5408SPeter Wemm	--enable-termcap.
24150e3d5408SPeter Wemm
24160e3d5408SPeter Wemm------------------------------- CUT HERE --------------------------------
24170e3d5408SPeter Wemm
24180e3d5408SPeter WemmIf you are installing this application privately (either because you
24190e3d5408SPeter Wemmhave no root access or want to experiment with it before doing a root
24200e3d5408SPeter Wemminstallation), there are a couple of details you need to be aware of.
24210e3d5408SPeter WemmThey have to do with the ncurses library, which uses terminfo rather
24220e3d5408SPeter Wemmthan termcap for describing terminal characteristics.
24230e3d5408SPeter Wemm
2424aae38d10SBaptiste DaroussinThough the ncurses library is terminfo-based, it can interpret your
24250e3d5408SPeter WemmTERMCAP variable (if present), any local termcap files you reference
2426aae38d10SBaptiste Daroussinthrough it, and the system termcap file.  However, to avoid slowing
2427aae38d10SBaptiste Daroussindown your application startup, it does this only once per terminal type!
24280e3d5408SPeter Wemm
24290e3d5408SPeter WemmThe first time you load a given terminal type from your termcap
24300e3d5408SPeter Wemmdatabase, the library initialization code will automatically write it
24310e3d5408SPeter Wemmin terminfo format to a subdirectory under $HOME/.terminfo.  After
24320e3d5408SPeter Wemmthat, the initialization code will find it there and do a (much
24330e3d5408SPeter Wemmfaster) terminfo fetch.
24340e3d5408SPeter Wemm
24350e3d5408SPeter WemmUsually, all this means is that your home directory will silently grow
24360e3d5408SPeter Wemman invisible .terminfo subdirectory which will get filled in with
24370e3d5408SPeter Wemmterminfo descriptions of terminal types as you invoke them.  If anyone
24380e3d5408SPeter Wemmever installs a global terminfo tree on your system, this will quietly
24390e3d5408SPeter Wemmstop happening and your $HOME/.terminfo will become redundant.
24400e3d5408SPeter Wemm
24410e3d5408SPeter WemmThe objective of all this logic is to make converting from BSD termcap
24420e3d5408SPeter Wemmas painless as possible without slowing down your application (termcap
24430e3d5408SPeter Wemmcompilation is expensive).
24440e3d5408SPeter Wemm
24450e3d5408SPeter WemmIf you don't have a TERMCAP variable or custom personal termcap file,
24460e3d5408SPeter Wemmyou can skip the rest of this dissertation.
24470e3d5408SPeter Wemm
24480e3d5408SPeter WemmIf you *do* have a TERMCAP variable and/or a custom personal termcap file
24490e3d5408SPeter Wemmthat defines a terminal type, that definition will stop being visible
24500e3d5408SPeter Wemmto this application after the first time you run it, because it will
24510e3d5408SPeter Wemminstead see the terminfo entry that it wrote to $HOME/terminfo the
24520e3d5408SPeter Wemmfirst time around.
24530e3d5408SPeter Wemm
24540e3d5408SPeter WemmSubsequently, editing the TERMCAP variable or personal TERMCAP file
24550e3d5408SPeter Wemmwill have no effect unless you explicitly remove the terminfo entry
24560e3d5408SPeter Wemmunder $HOME/terminfo.  If you do that, the entry will be recompiled
24570e3d5408SPeter Wemmfrom your termcap resources the next time it is invoked.
24580e3d5408SPeter Wemm
24590e3d5408SPeter WemmTo avoid these complications, use infocmp(1) and tic(1) to edit the
24600e3d5408SPeter Wemmterminfo directory directly.
24610e3d5408SPeter Wemm
24620e3d5408SPeter Wemm------------------------------- CUT HERE --------------------------------
24630e3d5408SPeter Wemm
24647a656419SBaptiste DaroussinUSING GPM:
24657a656419SBaptiste Daroussin---------
246606bfebdeSXin LI	Ncurses 4.1 and up can be configured to use GPM (General Purpose Mouse)
246706bfebdeSXin LI	which is used with Linux console.  Be aware that GPM is commonly
24680e3d5408SPeter Wemm	installed as a shared library which contains a wrapper for the curses
24690e3d5408SPeter Wemm	wgetch() function (libcurses.o).  Some integrators have simplified
24704a1a9510SRong-En Fan	linking applications by combining all or part of libcurses.so into the
24714a1a9510SRong-En Fan	libgpm.so file, producing symbol conflicts with ncurses (specifically
24724a1a9510SRong-En Fan	the wgetch function).  This was originally the BSD curses, but
24734a1a9510SRong-En Fan	generally whatever curses library exists on the system.
24744a1a9510SRong-En Fan
24754a1a9510SRong-En Fan	You may be able to work around this problem by linking as follows:
24760e3d5408SPeter Wemm
24770e3d5408SPeter Wemm		cc -o foo foo.o -lncurses -lgpm -lncurses
24780e3d5408SPeter Wemm
24790e3d5408SPeter Wemm	but the linker may not cooperate, producing mysterious errors.
24804a1a9510SRong-En Fan	See the FAQ, as well as the discussion under the --with-gpm option:
24810e3d5408SPeter Wemm
2482aae38d10SBaptiste Daroussin	https://invisible-island.net/ncurses/ncurses.faq.html#using_gpm_lib
24830e3d5408SPeter Wemm
24847a656419SBaptiste Daroussin
24857a656419SBaptiste DaroussinBUILDING WITH A CROSS-COMPILER:
24867a656419SBaptiste Daroussin------------------------------
248718259542SPeter Wemm	Ncurses can be built with a cross-compiler.  Some parts must be built
248818259542SPeter Wemm	with the host's compiler since they are used for building programs
248918259542SPeter Wemm	(e.g., ncurses/make_hash and ncurses/make_keys) that generate tables
24904a1a9510SRong-En Fan	that are compiled into the ncurses library.  The essential thing to do
24914a1a9510SRong-En Fan	is set the BUILD_CC environment variable to your host's compiler, and
24924a1a9510SRong-En Fan	run the configure script configuring for the cross-compiler.
24934a1a9510SRong-En Fan
24944a1a9510SRong-En Fan	The configure options --with-build-cc, etc., are provided to make this
24954a1a9510SRong-En Fan	simpler.  Since make_hash and make_keys use only ANSI C features, it
24964a1a9510SRong-En Fan	is normally not necessary to provide the other options such as
24974a1a9510SRong-En Fan	--with-build-libs, but they are provided for completeness.
24980e3d5408SPeter Wemm
249918259542SPeter Wemm	Note that all of the generated source-files which are part of ncurses
250018259542SPeter Wemm	will be made if you use
25010e3d5408SPeter Wemm
250218259542SPeter Wemm		make sources
250318259542SPeter Wemm
250418259542SPeter Wemm	This would be useful in porting to an environment which has little
250518259542SPeter Wemm	support for the tools used to generate the sources, e.g., sed, awk and
250618259542SPeter Wemm	Bourne-shell.
25070e3d5408SPeter Wemm
25084a1a9510SRong-En Fan	When ncurses has been successfully cross-compiled, you may want to use
25094a1a9510SRong-En Fan	"make install" (with a suitable target directory) to construct an
25104a1a9510SRong-En Fan	install tree.  Note that in this case (as with the --with-fallbacks
25117a656419SBaptiste Daroussin	option), ncurses uses the development platform's tic to do the "make
25127a656419SBaptiste Daroussin	install.data" portion.
25134a1a9510SRong-En Fan
251406bfebdeSXin LI	The system's tic program is used to install the terminal database,
25157a656419SBaptiste Daroussin	even for cross-compiles.  For best results, the tic program should be
25167a656419SBaptiste Daroussin	from the most current version of ncurses.
251706bfebdeSXin LI
25187a656419SBaptiste Daroussin	NOTE:  the system's tic program may use a different terminfo database
25197a656419SBaptiste Daroussin	format than the target system.  For instance, as described in term(5),
25207a656419SBaptiste Daroussin	the conventional terminfo layout uses a directory hierarchy with one
25217a656419SBaptiste Daroussin	letter names, while some platforms use two-letter names to work with
25227a656419SBaptiste Daroussin	case-insensitive filesystems.  The configure script searches for a tic
25237a656419SBaptiste Daroussin	program using the AC_CHECK_TOOL macro, which will prefer programs
25247a656419SBaptiste Daroussin	using the canonical host prefix in their name.  You can use this fact
25257a656419SBaptiste Daroussin	to provide a cross-compiler support utility tic, otherwise you can
25267a656419SBaptiste Daroussin	override the configure script's choice using --with-tic-path
25277a656419SBaptiste Daroussin
25287a656419SBaptiste Daroussin
25297a656419SBaptiste DaroussinBUG REPORTS:
25307a656419SBaptiste Daroussin-----------
25310e3d5408SPeter Wemm	Send any feedback to the ncurses mailing list at
25320e3d5408SPeter Wemm	bug-ncurses@gnu.org. To subscribe send mail to
25330e3d5408SPeter Wemm	bug-ncurses-request@gnu.org with body that reads:
25340e3d5408SPeter Wemm	subscribe ncurses <your-email-address-here>
25350e3d5408SPeter Wemm
253618259542SPeter Wemm	The Hacker's Guide in the doc directory includes some guidelines
25370e3d5408SPeter Wemm	on how to report bugs in ways that will get them fixed most quickly.
25384a1a9510SRong-En Fan
2539*21817992SBaptiste Daroussin-- vile:txtmode fc=78
2540