Debian Codegraph @

README

raw
1 Introduction
2 ============
3
4 This is the Gnu Readline library, version 8.3.
5
6 The Readline library provides a set of functions for use by applications
7 that allow users to edit command lines as they are typed in. Both
8 Emacs and vi editing modes are available. The Readline library includes
9 additional functions to maintain a list of previously-entered command
10 lines, to recall and perhaps reedit those lines, and perform csh-like
11 history expansion on previous commands.
12
13 The history facilities are also placed into a separate library, the
14 History library, as part of the build process. The History library
15 may be used without Readline in applications which desire its
16 capabilities.
17
18 The Readline library is free software, distributed under the terms of
19 the [GNU] General Public License as published by the Free Software
20 Foundation, version 3 of the License. For more information, see the
21 file COPYING.
22
23 To build the library, try typing `./configure', then `make'. The
24 configuration process is automated, so no further intervention should
25 be necessary. Readline builds with `gcc' by default if it is
26 available. If you want to use `cc' instead, type
27
28 CC=cc ./configure
29
30 if you are using a Bourne-style shell. If you are not, the following
31 may work:
32
33 env CC=cc ./configure
34
35 Read the file INSTALL in this directory for more information about how
36 to customize and control the build process, including how to build readline
37 in a directory other than the source directory.
38
39 The file rlconf.h contains C preprocessor defines that enable and disable
40 certain Readline features.
41
42 The special make target `everything' will build the static and shared
43 libraries (if the target platform supports them) and the examples.
44
45 Examples
46 ========
47
48 There are several example programs that use Readline features in the
49 examples directory. The `rl' program is of particular interest. It
50 is a command-line interface to Readline, suitable for use in shell
51 scripts in place of `read' (but look at bash's `read -e' first).
52
53 Shared Libraries
54 ================
55
56 There is skeletal support for building shared versions of the
57 Readline and History libraries. The configure script creates
58 a Makefile in the `shlib' subdirectory, and typing `make shared'
59 will cause shared versions of the Readline and History libraries
60 to be built on supported platforms.
61
62 If `configure' is given the `--enable-shared' option, it will attempt
63 to build the shared libraries by default on supported platforms.
64
65 Configure calls the script support/shobj-conf to test whether or
66 not shared library creation is supported and to generate the values
67 of variables that are substituted into shlib/Makefile. If you
68 try to build shared libraries on an unsupported platform, `make'
69 will display a message asking you to update support/shobj-conf for
70 your platform.
71
72 If you need to update support/shobj-conf, you will need to create
73 a `stanza' for your operating system and compiler. The script uses
74 the value of host_os and ${CC} as determined by configure. For
75 instance, FreeBSD 4.2 with any version of gcc is identified as
76 `freebsd4.2-gcc*'.
77
78 In the stanza for your operating system-compiler pair, you will need to
79 define several variables. They are:
80
81 SHOBJ_CC The C compiler used to compile source files into shareable
82 object files. This is normally set to the value of ${CC}
83 by configure, and should not need to be changed.
84
85 SHOBJ_CFLAGS Flags to pass to the C compiler ($SHOBJ_CC) to create
86 position-independent code. If you are using gcc, this
87 should probably be set to `-fpic'.
88
89 SHOBJ_LD The link editor to be used to create the shared library from
90 the object files created by $SHOBJ_CC. If you are using
91 gcc, a value of `gcc' will probably work.
92
93 SHOBJ_LDFLAGS Flags to pass to SHOBJ_LD to enable shared object creation.
94 If you are using gcc, `-shared' may be all that is necessary.
95 These should be the flags needed for generic shared object
96 creation.
97
98 SHLIB_XLDFLAGS Additional flags to pass to SHOBJ_LD for shared library
99 creation. Many systems use the -R option to the link
100 editor to embed a path within the library for run-time
101 library searches. A reasonable value for such systems would
102 be `-R$(libdir)'.
103
104 SHLIB_LIBS Any additional libraries that shared libraries should be
105 linked against when they are created.
106
107 SHLIB_LIBPREF The prefix to use when generating the filename of the shared
108 library. The default is `lib'; Cygwin uses `cyg'.
109
110 SHLIB_LIBSUFF The suffix to add to `libreadline' and `libhistory' when
111 generating the filename of the shared library. Many systems
112 use `so'; HP-UX uses `sl'.
113
114 SHLIB_LIBVERSION The string to append to the filename to indicate the version
115 of the shared library. It should begin with $(SHLIB_LIBSUFF),
116 and possibly include version information that allows the
117 run-time loader to load the version of the shared library
118 appropriate for a particular program. Systems using shared
119 libraries similar to SunOS 4.x use major and minor library
120 version numbers; for those systems a value of
121 `$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)$(SHLIB_MINOR)' is appropriate.
122 Systems based on System V Release 4 don't use minor version
123 numbers; use `$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)' on those systems.
124 Other Unix versions use different schemes.
125
126 SHLIB_DLLVERSION The version number for shared libraries that determines API
127 compatibility between readline versions and the underlying
128 system. Used only on Cygwin. Defaults to $SHLIB_MAJOR, but
129 can be overridden at configuration time by defining DLLVERSION
130 in the environment.
131
132 SHLIB_DOT The character used to separate the name of the shared library
133 from the suffix and version information. The default is `.';
134 systems like Cygwin which don't separate version information
135 from the library name should set this to the empty string.
136
137 SHLIB_STATUS Set this to `supported' when you have defined the other
138 necessary variables. Make uses this to determine whether
139 or not shared library creation should be attempted.
140
141 You should look at the existing stanzas in support/shobj-conf for ideas.
142
143 Once you have updated support/shobj-conf, re-run configure and type
144 `make shared'. The shared libraries will be created in the shlib
145 subdirectory.
146
147 If shared libraries are created, `make install' will install them.
148 You may install only the shared libraries by running `make
149 install-shared' from the top-level build directory. Running `make
150 install' in the shlib subdirectory will also work. If you don't want
151 to install any created shared libraries, run `make install-static'.
152
153 Documentation
154 =============
155
156 The documentation for the Readline and History libraries appears in
157 the `doc' subdirectory. There are three texinfo files and a
158 Unix-style manual page describing the facilities available in the
159 Readline library. The texinfo files include both user and
160 programmer's manuals. HTML versions of the manuals appear in the
161 `doc' subdirectory as well.
162
163 Usage
164 =====
165
166 Our position on the use of Readline through a shared-library linking
167 mechanism is that there is no legal difference between shared-library
168 linking and static linking--either kind of linking combines various
169 modules into a single larger work. The conditions for using Readline
170 in a larger work are stated in section 3 of the GNU GPL.
171
172 Reporting Bugs
173 ==============
174
175 Bug reports for Readline should be sent to:
176
177 [email protected]
178
179 When reporting a bug, please include the following information:
180
181 * the version number and release status of Readline (e.g., 4.2-release)
182 * the machine and OS that it is running on
183 * a list of the compilation flags or the contents of `config.h', if
184 appropriate
185 * a description of the bug
186 * a recipe for recreating the bug reliably
187 * a fix for the bug if you have one!
188
189 If you would like to contact the Readline maintainer directly, send mail
190 to [email protected].
191
192 Since Readline is developed along with bash, the [email protected] mailing
193 list (mirrored to the Usenet newsgroup gnu.bash.bug) often contains
194 Readline bug reports and fixes.
195
196 Chet Ramey
197 [email protected]