]> CyberLeo.Net >> Repos - FreeBSD/releng/10.0.git/blob - contrib/less/README
- Copy stable/10 (r259064) to releng/10.0 as part of the
[FreeBSD/releng/10.0.git] / contrib / less / README
1 **************************************************************************
2 **************************************************************************
3 **                                                                      **
4 ** The FreeBSD Project has chosen to redistribute and modify Less under **
5 ** the 'Less License' (as described in the 'LICENSE' file).             **
6 **                                                                      **
7 **************************************************************************
8 **************************************************************************
9
10                             Less, version 458
11
12     This is the distribution of less, version 458, released 04 Apr 2013.
13     This program is part of the GNU project (http://www.gnu.org).
14
15     This program is free software.  You may redistribute it and/or
16     modify it under the terms of either:
17
18     1. The GNU General Public License, as published by the Free
19        Software Foundation; either version 3, or (at your option) any
20        later version.  A copy of this license is in the file COPYING.
21     or
22     2. The Less License, in the file LICENSE.
23
24     Please report any problems to bug-less@gnu.org.
25     See http://www.greenwoodsoftware.com/less for the latest info.
26
27 =========================================================================
28
29 This is the distribution of "less", a paginator similar to "more" or "pg".
30
31 The formatted manual page is in less.man.
32 The manual page nroff source is in less.nro.
33 Major changes made since the last posted version are in NEWS.
34
35 =======================================================================
36 INSTALLATION (Unix systems only):
37
38 1. Move the distributed source to its own directory and unpack it,
39    if you have not already done so.  
40
41 2. Type "sh configure".
42    This will generate a Makefile and a defines.h.
43    Warning: if you have a GNU sed, make sure it is version 2.05 or later.
44
45    The file INSTALL describes the usage of the configure program in
46    general.  In addition, these options to configure are supported:
47
48    --with-editor=program
49      Specifies the default editor program used by the "v" command.
50      The default is "vi".
51
52    --with-regex=lib
53      Specifies the regular expression library used by less for pattern
54      matching.  The default is "auto", which means the configure program 
55      finds a regular expression library automatically.  Other values are:
56         posix          Use the POSIX-compatible regcomp.
57         pcre           Use the PCRE library.
58         regcmp         Use the regcmp library.
59         re_comp        Use the re_comp library.
60         regcomp        Use the V8-compatible regcomp.
61         regcomp-local  Use Henry Spencer's V8-compatible regcomp
62                        (source is supplied with less).
63         none           No regular expressions, only simple string matching.
64    --with-secure
65      Builds a "secure" version of less, with some features disabled
66      to prevent users from viewing other files, accessing shell
67      commands, etc.
68
69
70 3. It is a good idea to look over the generated Makefile and defines.h
71    and make sure they look ok.  If you know of any peculiarities of
72    your system that configure might not have detected, you may fix the
73    Makefile now.  Take particular notice of the list of "terminal" 
74    libraries in the LIBS definition in the Makefile; these may need 
75    to be edited.  The terminal libraries will be some subset of
76        -lncurses  -lcurses  -ltermcap  -ltermlib
77
78    If you wish, you may edit defines.h to remove some optional features.
79    If you choose not to include some features in your version, you may
80    wish to edit the manual page "less.nro" and the help page "less.hlp" 
81    to remove the descriptions of the features which you are removing.
82    If you edit less.hlp, you should run "make -f Makefile.aut help.c".
83
84 4. Type "make" and watch the fun.
85
86 5. If the make succeeds, it will generate the programs "less",
87    "lesskey" and "lessecho" in your current directory.  Test the 
88    generated programs.
89
90 6. When satisfied that it works, if you wish to install it
91    in a public place, type "make install".
92
93    The default install destinations are:
94         Executables (less, lesskey, lessecho) in /usr/local/bin
95         Documentation (less.nro, lesskey.nro) in /usr/local/man/man1
96    If you want to install any of these files elsewhere, define
97    bindir and/or mandir to the appropriate directories.
98
99 If you have any problems building or running "less", suggestions, 
100 complaints, etc., you may mail to bug-less@gnu.org.
101
102 Note to hackers: comments noting possible improvements are enclosed
103 in double curly brackets {{ like this }}.
104
105 (Note that the above note was originally written at a time when 
106 "hackers" most commonly meant "enthusiastic and dedicated computer 
107 programmers", not "persons who attempt to circumvent computer security".)
108
109
110
111 =======================================================================
112 INSTALLATION (MS-DOS systems only,
113               with Microsoft C, Borland C, or DJGPP)
114
115 1. Move the distributed source to its own directory.
116    Depending on your compiler, you may need to convert the source 
117    to have CR-LF rather than LF as line terminators.
118
119 2. If you are using Microsoft C, rename MAKEFILE.DSU to MAKEFILE.
120    If you are using Borland C, rename MAKEFILE.DSB to MAKEFILE.
121    If you are using DJGPP, rename MAKEFILE.DSG to MAKEFILE.
122
123 3. Look at MAKEFILE to make sure that the definitions for CC and LIBDIR
124    are correct.  CC should be the name of your C compiler and
125    LIBDIR should be the directory where the C libraries reside (for
126    Microsoft C only).  If these definitions need to be changed, you can
127    either modify the definitions directly in MAKEFILE, or set your
128    environment variables CC and/or LIBDIR to override the definitions
129    in MAKEFILE.
130
131 4. If you wish, you may edit DEFINES.DS to remove some optional features.
132    If you choose not to include some features in your version, you may
133    wish to edit the manual page LESS.MAN and the help page HELP.C
134    to remove the descriptions of the features which you are removing.
135
136 5. Run your "make" program and watch the fun.
137    If your "make" requires a flag to import environment variables,
138    you should use that flag.
139    If your compiler runs out of memory, try running "make -n >cmds.bat" 
140    and then run cmds.bat.
141
142 6. If the make succeeds, it will generate the programs "LESS.EXE" and
143    "LESSKEY.EXE" in your current directory.  Test the generated programs.
144
145 7. When satisfied that it works, you may wish to install LESS.EXE and
146    LESSKEY.EXE in a directory which is included in your PATH.
147
148
149
150 =======================================================================
151 INSTALLATION (Windows-95, Windows-98 and Windows-NT systems only,
152               with Borland C or Microsoft Visual C++)
153
154 1. Move the distributed source to its own directory.
155
156 2. If you are using Borland C, rename Makefile.wnb to Makefile.
157    If you are using Microsoft Visual C++, rename Makefile.wnm to Makefile.
158
159 3. Check the Makefile to make sure the definitions look ok.
160
161 4. If you wish, you may edit defines.wn to remove some optional features.
162    If you choose not to include some features in your version, you may
163    wish to edit the manual page less.man and the help page help.c
164    to remove the descriptions of the features which you are removing.
165
166 5. Type "make" and watch the fun.
167
168 6. If the make succeeds, it will generate the programs "less.exe" and
169    "lesskey.exe" in your current directory.  Test the generated programs.
170
171 7. When satisfied that it works, if you wish to install it
172    in a public place, type "make install".
173    See step 6 of the Unix installation instructions for details
174    on how to change the default installation directories.
175
176
177
178 =======================================================================
179 INSTALLATION (OS/2 systems only,
180               with EMX C)
181
182 1. Move the distributed source to its own directory.
183
184 2. Rename Makefile.o2e to Makefile.
185
186 3. Check the Makefile to make sure the definitions look ok.
187
188 4. If you wish, you may edit defines.o2 to remove some optional features.
189    If you choose not to include some features in your version, you may
190    wish to edit the manual page less.man and the help page help.c
191    to remove the descriptions of the features which you are removing.
192
193 5. Type "make" and watch the fun.
194
195 6. If the make succeeds, it will generate the programs "less.exe" and
196    "lesskey.exe" in your current directory.  Test the generated programs.
197
198 7. Make sure you have the emx runtime installed. You need the emx DLLs
199    emx.dll and emxlibcs.dll and also the termcap database, termcap.dat.
200    Make sure you have termcap.dat either in the default location or
201    somewhere in a directory listed in the PATH or INIT environment 
202    variables.
203
204 8. When satisfied that it works, you may wish to install less.exe,
205    lesskey.exe and scrsize.exe in a directory which is included in 
206    your PATH.  scrsize.exe is required only if you use a terminal
207    emulator such as xterm or rxvt.
208
209
210
211 =======================================================================
212 INSTALLATION (OS-9 systems only,
213               with Microware C or Ultra C)
214
215 1. Move the distributed source to its own directory.
216
217 2. If you are using Microware C, rename Makefile.o9c to Makefile.
218    If you are using Ultra C, rename Makefile.o9u to Makefile.
219
220 3. Check the Makefile to make sure the definitions look ok.
221
222 4. If you wish, you may edit defines.o9 to remove some optional features.
223    If you choose not to include some features in your version, you may
224    wish to edit the manual page less.man and the help page help.c
225    to remove the descriptions of the features which you are removing.
226
227 5. Type "dmake" and watch the fun.
228    The standard OS-9 "make" will probably not work.  If you don't
229    have dmake, you can get a copy from os9archive.rtsi.com.
230
231 6. If the make succeeds, it will generate the programs "less" and
232    "lesskey" in your current directory.  Test the generated programs.
233
234 7. When satisfied that it works, if you wish to install it
235    in a public place, type "dmake install".
236    See step 6 of the Unix installation instructions for details
237    on how to change the default installation directories.
238
239 =======================================================================
240 ACKNOWLEDGMENTS:
241   Some versions of the less distribution are packaged using 
242   Info-ZIP's compression utility.
243   Info-ZIP's software is free and can be obtained as source 
244   code or executables from various anonymous-ftp sites,
245   including ftp.uu.net:/pub/archiving/zip.