some cosmethic changes
[midnight-commander.git] / INSTALL
blob0bec3a995a80637a83295ed0cdf8249c7bbf4d8e
1 This file contains:
3 - Installation instructions and notes for GNU Midnight Commander
4 - Where to get more information on GNU Midnight Commander
5 - Common problems
6 - Information on porting the program
7 - Obtaining the missing pieces of GNU Midnight Commander
10 Installation instructions for GNU Midnight Commander
11 ----------------------------------------------------
13    The `configure' shell script attempts to guess correct values for
14 various system-dependent variables used during compilation, and creates
15 the makefiles.  It also creates a file `config.status' that you can run in
16 the future to recreate the current configuration.
18 NeXTStep users, make sure you read the "Compiling under NeXTStep" section.
20 To compile this package:
22 1.  Configure the package for your system.
24    Normally, you just `cd' to the directory containing the package's
25 source code and type `./configure'.  If you're using `csh' on an old
26 version of SystemV, you might need to type `sh configure' instead to
27 prevent `csh' from trying to execute `configure' itself.  Under AIX, you
28 may need to use ksh instead of sh.
30    Running `configure' takes a while.  While it is running, it
31 prints some messages that tell what it is doing.  If you don't want to
32 see any messages, run `configure' with the `--quiet' option.
34    To compile the package in a different directory than the one containing
35 the source code, you must use a version of `make' supporting the `VPATH'
36 variable, such as GNU `make'.  `cd' to the directory where you want the
37 object files and executables to go and run the `configure' script with the
38 path to it.  If for some reason `configure' is not in the source code
39 directory that you are configuring, then it will report that it can't find
40 the source code.  In that case, run `configure' with the option
41 `--srcdir=DIR', where DIR is the directory that contains the source code.
43    By default, `make install' will install the package's files in
44 `/usr/local/bin', `/usr/local/man', etc.  You can specify an installation
45 prefix other than `/usr/local' by giving `configure' the option
46 `--prefix=PATH'.  Alternately, you can do so by consistently giving a
47 value for the `prefix' variable when you run `make', e.g.,
49      make prefix=/usr/gnu
50      make prefix=/usr/gnu install
52    You can specify separate installation prefixes for architecture
53 specific files and architecture-independent files.  If you give
54 `configure' the option `--exec-prefix=PATH' or set the `make' variable
55 `exec_prefix' to PATH, the package will use PATH as the prefix for
56 installing programs and libraries.  Data files and documentation will
57 still use the regular prefix.  Normally, all files are installed using the
58 same prefix.
60    If run on GNU/Linux, Midnight Commander detects if you have the gpm
61 library installed.  If you installed the gpm mouse library in a
62 non-standard place, you will need to use the --with-gpm-mouse flag with
63 the directory base where you installed the gpm package.
65    `configure' also recognizes the following options:
67 `--help'
68      Print a summary of the options to `configure', and exit.
70 `--quiet'
71 `--silent'
72      Do not print messages saying which checks are being made.
74 `--verbose'
75      Print the results of the checks.
77 `--version'
78      Print the version of Autoconf used to generate the `configure'
79      script, and exit.
81 `--without-edit'
82      Configures the program to be compiled without the built-in file
83      editor.  The built-in editor is compiled in by default.
85 `--with-ext2undel[=PATH]'
86      On systems that use the Extended 2 file system and have the
87      libext2fs.a library available, this compiles into the Midnight
88      Commander the support code for recovering deleted files (the
89      undel virtual file system). 
90      Use =PATH if libext2fs.a is installed in a non-standard place. 
91      The configure will append `lib' and `include' to find the ext2fs 
92      libraries and include files respectively.
94 `--with-gpm-mouse[=PATH]'
95      Use this flag if your gpm mouse package cannot be detected by the
96      configure. Use =PATH if it is installed in a non-standard place.
97      The configure will append `lib' and `include' to find the libgpm.a
98      and gpm.h files respectively.
100 `--without-gpm-mouse'
101      Use this flag to disable gpm mouse support (e.g. if you want to
102      use mouse only on X terminals).
104 `--with-hsc'
105      Compiles support for HSC firewall into the ftp virtual file system.
106      Use this option with caution - it disables support for normal FTP
107      proxies.
109 `--with-mmap', `--without-mmap'
110      Force using or not using the mmap function.  It is currently used
111      in the internal viewer.  `--with-mmap' may be useful on some
112      versions of AIX where the `configure' script decides that mmap is
113      broken, but it's actually suitable for the internal viewer.
115 `--with-subshell[=optional]', `--without-subshell' 
116      The subshell support is by default turned on, you can disable
117      this by using the --without-subshell option.  If you pass the
118      =optional parameter, then the subshell support is turned off by
119      default.  To turn it on, specify the `-U' option to the program.
121 `--with-tm-x-support'
122      This option enables minimal X Window support in the text edition. It 
123      enables MC to query the status of the modifiers CONTROL and SHIFT 
124      when invoked in a terminal emulator under X11. That's necessary 
125      to recognize some optional but handy key combinations like Ctrl-Home 
126      and Shift-Cursor key.
128 `--without-vfs'
129      This option disables the Virtual File System switch code in the
130      Midnight Commander and uses the standard file system calls for
131      file access.  If you specify this option you will not get the
132      transparent tar File system manipulation as well nor the
133      networked Midnight Commander file system.
135 `--with-mcfs'
136      This option enables mcfs - a non-standard remote filesystem
137      designed specifically for the Midnight Commander.  It also enables
138      a server for that filesystem, mcserv.  Please note that the
139      implementation of mcfs is not optimized for speed.  There may be
140      security issues with mcserv - don't run it if you don't need it.
142 `--with-samba'
143      This option enables remote VFS over the SMB protocol.  A stripped
144      down version of samba distibuted with the sources is compiled and
145      linked with the mc executable.  It is recommended that you install
146      Samba client, since mc uses some files from Samba under certain
147      conditions.  Please visit http://www.samba.org/ to learn more.
149 `--disable-largefile'
150      This option disables support for large files (2 gigabytes and more)
151      on the systems where file operations use 32-bit offsets by default,
152      but support for 64-bit offsets is available.  May be useful for
153      slow processors and embedded systems.
155 You may also tell configure which display library you want to use with the
156 Midnight Commander.  The configure script will use S-Lang as default, but
157 you can override this by using any of the following flags (please note
158 that S-Lang is included as part of the distribution and is tested much 
159 better than everything else),
161 `--with-slang' (default)
162      This is used to configure the program to use the S-Lang screen
163      library.  This is included as part of GNU Midnight Commander,
164      you don't need it installed on your system.  If S-Lang is installed
165      on your system it will be used if possible.  You can force usage of
166      the included S-Lang with the `--with-included-slang' option.
168      S-Lang tries to use the terminfo database if it's available,
169      otherwise it uses the termcap database.  At the compile time, you
170      may force using the termcap database by using the option
171      `--with-termcap', which also enables `--with-included-slang'.
173 `--with-ncurses[=directory]'
174      Use this flag (either with or without the =directory part), if
175      you want to compile with ncurses instead of the default S-Lang.
177      Use the =directory part if your ncurses is not installed in any of the
178      places configure will check (/usr/include, /usr/include/ncurses,
179      /usr/local/include and /usr/local/include/ncurses).
180      The argument to this flag is the base directory where the ncurses
181      files are located.  The configure will append lib and include to
182      find the libncurses.a and ncurses.h file respectively.  For
183      example, if you have installed ncurses under /gnu/lib and
184      /gnu/include, you specify: --with-ncurses=/gnu
186    Run `configure --help' to see the full list of options.
188    On systems that require unusual options for compilation or linking
189 that the package's `configure' script does not know about, you can give
190 `configure' initial values for variables by setting them in the
191 environment.  In Bourne-compatible shells, you can do that on the
192 command line like this:
194      CC='gcc -traditional' LIBS=-lposix ./configure
196 On systems that have the `env' program, you can do it like this:
198      env CC='gcc -traditional' LIBS=-lposix ./configure
200    Here are the `make' variables that you might want to override with
201 environment variables when running `configure'.
203    For these variables, any value given in the environment overrides the
204 value that `configure' would choose:
206  - Variable: CC
207      C compiler program.  The default is `cc'.
209  - Variable: CFLAGS
210      The default flags used to build the program.
212  - Variable: INSTALL
213      Program to use to install files.  The default is `install' if you
214      have it, `cp' otherwise.
216    For these variables, any value given in the environment is added to
217 the value that `configure' decides to use:
219  - Variable: LIBS
220      Libraries to link with, in the form `-lfoo -lbar...'.
222    If you need to do unusual things to compile the package, we encourage
223 you to figure out how `configure' could check whether to do them, and mail
224 diffs or instructions to the address given in the README so we can include
225 them in the next release.
227 2.  Type `make' to compile the package.
229 3.  If the package comes with self-tests and you want to run them,
230 type `make check'.  If you're not sure whether there are any, try it;
231 if `make' responds with something like
232         make: *** No way to make target `check'.  Stop.
233 then the package does not come with self-tests.
235 4.  Type `make install' to install programs, data files, and the
236 documentation.  On GNU/Linux the console screen saver is installed as
237 well.
239 5.  You can remove the program binaries and object files from the source
240 directory by typing `make clean'.  If you want to clean the source tree
241 completely, so that it contains only those files that should be packaged
242 in the archive, issue `make distclean'.  If you've run configure in a
243 different directory than the source tree, distclean won't remove your *.o
244 and linked programs in that directory.
246 6.  GNU Midnight Commander allows you to stay in the last current
247 directory after exiting MC.  This is done with a shell function, the man
248 page has more information about this.
250    The file `configure.in' is used to create `configure' by a program
251 called `autoconf'.  You only need it if you want to regenerate
252 `configure' using a newer version of `autoconf'.
254 Compiling under NeXTStep 
255 ------------------------
257 These instructions were provided by Gregor Hoffleit
258 <flight@mathi.uni-heidelberg.DE>, he recommends configuring the
259 program like this:
261 export CC="cc -posix"
262 configure --without-subshell --with-termcap
265 Where to get more information on GNU Midnight Commander
266 -------------------------------------------------------
268 There are two mailing lists for the program:
270 mc:         Discussion on GNU Midnight Commander file manager.
271 mc-devel:   For discussion between the developers of the program.
273 to subscribe to the mailing lists, visit their respective pages:
275 http://mail.gnome.org/mailman/listinfo/mc/
276 http://mail.gnome.org/mailman/listinfo/mc-devel/
279 Notes about GNU Midnight Commander installation
280 ------------------------------------------------
282 GNU Midnight Commander has been run in the following configurations:
284 i386-*-linux
285 sparc-*-linux
286 alpha-*-linux
287 powerpc-*-linux
288 mips-dec-ultrix4.3
289 mips-dec-{open,net}bsd1.0
290 mips-sgi-irix5.2
291 mips-sgi-irix5.3
292 rs6000-ibm-aix3.2.5
293 sparc-sun-sunos4.1
294 sparc-sun-netbsd1.0
295 sparc-sun-solaris2.3
296 hppa-hp-hpux9
297 hppa-hp-hpux7
298 m68k-apple-aux
299 mc88110-aviion-dgux5.4
300 i386-*-bsdi2
301 i386-*-freebsd4.3
302 i386-*-openbsd2.9
304 Midnight Commander is written in a portable manner and uses GNU Autoconf
305 for configuration, so it is expected to compile without changes on many
306 other operating systems.
308 You will need GNU C (or an ANSI C Compiler) and glib library version
309 1.2.x to compile the source.  GNU Midnight Commander now comes with the
310 S-Lang screen manager, a fast screen manager, so don't need to worry
311 about screen libraries.
313 If you insist on using ncurses, it's recommended to use ncurses 4.1 and
314 above, since the older versions don't support resizing of the xterm
315 window.
317 GNU Midnight Commander comes with the mouse support on xterms and in the
318 Linux console.  In order to take advantage of the mouse support on the
319 Linux console you will need the gpm mouse server (see the section
320 "Obtaining the missing pieces of GNU Midnight Commander" in this file).
322 Once you get the Mouse Server, compile it and install it, then you
323 will have to specify the `--with-gpm-mouse' flag to the configure
324 program if you installed it in a non-standard directory.  If you
325 installed the gpm package under /usr or /usr/local, you don't need to
326 specify this flag; configure will find gpm for you.  The support for
327 mice on xterms is always compiled in.
329 We are working on further enhancements to the program, but we're not sure
330 which ones must go first.  If you would like to point us in the Right
331 Direction we will be glad to hear from you (you could check the file TODO
332 included with this distribution for the current projects).
334 If you happen to find an undocumented feature that doesn't do what you
335 expected, please write to mc@gnome.org telling as much as you can about
336 the problem you're experiencing.  Please don't send personal messages to
337 the maintainers.
340 Porting the program
341 -------------------
343 Random notes on porting to other architectures.  
345 GNU Midnight Commander uses by default the S-Lang library for handling
346 the display.  You may want to download the latest version of S-Lang
347 or use a slightly modified S-Lang version 0.99.38 included with the
348 Midnight Commander.  The included library is very stable and has been
349 used for years without problems.  You shouldn't expect any problems
350 porting S-Lang to your platform.
352 Another possibility is to download and install ncurses on your OS.
353 GNU Midnight Commander can use ncurses as well as the display engine.
354 However, you may encounter minor differences, for instance, you will
355 be unable to force the color mode by giving the "-c" switch to GNU
356 Midnight Commander.
359 Obtaining the missing pieces of GNU Midnight Commander
360 ------------------------------------------------------
362 GNU Midnight Commander will build without requiring you to get any other
363 software packages, however, you may be interested in enhancing the
364 Midnight Commander environment with some of these:
366 o Terminal database
368   There are many incomplete terminal databases out there, however, a
369   complete terminfo is bundled with ncurses.  (It is simple to generate
370   the termcap database using the infocmp utility in ncurses).
372   Some terminfo data are included with the mc distribution (lib/*.ti).
373   Particularly linux, xterm and vt100. Use e.g. ''tic linux.ti'' to
374   use them.
376   If you want to run mc on xterm/color_xterm/ansi_xterm (not rxvt), then
377   you might read lib/README.xterm for further information.
379 o GLib
381   Midnight Commander requires GLib.  You can get GLib from
383   ftp://ftp.gtk.org/pub/gtk/
385   Note that only versions 1.2.x are supported.  Older versions won't
386   even be detected.  Newer versions won't be detected either - they use a
387   new package system that is not supported yet by GNU Midnight Commander.
389 o In the past GNU Midnight Commander required the ncurses library to
390   build, now it's optional.  You can get ncurses from
392   ftp://ftp.gnu.org/gnu/ncurses/
393   ftp://dickey.his.com/ncurses/
395 o The general purpose mouse (gpm) daemon is available at:
397   ftp://ftp.systemy.it/pub/develop/
399 And the GNU Compiler Collection may be obtained from the following sites:
401 ftp://gcc.gnu.org/pub/gcc/releases/
402 ftp://ftp.gnu.org/gnu/gcc/
403 http://gcc.gnu.org/mirrors.html