PREREQUISITES

        Required
            * gcc       : GNU C compiler
            * make      : GNU make
            * sh        : POSIX type shell
            * coreutils : GNU core utilities package (chmod, install, mkdir, mv, rm, uname)
            * sed       : Stream editor
            * perl      : Practical Extraction and Report Language (perlpod)

        Optional (depending on build targets):
            * gettext     : Framework to help GNU packages produce multi-lingual messages.
            * ncurses     : CRT screen handling and optimization package.
            * groff       : GNU troff text formatting system.
            * ghostscript : An interpreter for the PostScript language and for PDF (ps2pdf)

        Check if you have GNU make(1) and GNU gcc(1) installed on your
        system. On some systems GNU make may be installed as 'gmake' command.

            make --version
            gcc --version

        If you are not able to generate the documentation files, download the documentation
        package wcd-<version>-doc.tar.gz with the generated documentation files and unpack
        it over the source package.


BASIC INSTALLATION

        Change to directory src/

        To compile using GNU make:

            make all

        Options that can be enabled during compiling

            UCS=1       Enable Unicode (UTF8) support
                        The default value is empty.
                        On Cygwin the default value is 1.

            UNINORM=1   Enable Unicode normalization.
                        The default value is empty.
                        On Cygwin the default value is 1.
                        Requires libunistring, see
                        http://www.gnu.org/s/libunistring/
                        http://en.wikipedia.org/wiki/Unicode_normalization

            ENABLE_NLS=1
                        Enable native language support.
                        That is, use locale files.
                        The default value is 1.

            STATIC=1    Enable static linking. Make a
                        standalone wcd binary.
                        The default value is empty.

            DEBUG=1     A debug enabled build can be made by
                        adding DEBUG=1 to the make command.

            LFS=
                        Large File Support (LFS) is by default enabled. This
                        enables the use of 64 bit file system interface on 32
                        bit systems.  This makes it possible to open files
                        larger than 2GB on 32 bit systems, provided the OS
                        has LFS support builtin. To disable LFS make the LFS
                        variable empty. Example:

                        Disable LFS:
                        make clean install LFS=

            CURSES=<curses|ncurses|ncursesw|pdcurses>

                        Select curses library.
                        The default value is 'ncurses'.
                        Only an expert should change this.

            NCURSES_DEBUG=1
                        Link with ncurses debug enabled library by
                        adding NCURSES_DEBUG=1 to the make command.

            ASCII_TREE=1
                        Draw graphical tree with
                        ASCII characters.
                        The default value is empty.

            EXT=.exe    Set executable extension
                        The default value is '.exe' to
                        make a distinction between the binary
                        and the function/alias.

            HMTLEXT=html
                        Set HTML manual file extension.
                        The default value is 'htm' to
                        support all platforms.

        An example to enable unicode support, provided that the library
        libncursesw is also available:

            make UCS=1 clean all

        To disable Native Language Support,
        reset the ENABLE_NLS variable:

            make ENABLE_NLS=

        To disable curses and compile with plain stdin/stdout
        interface type, reset the CURSES variable:

            make CURSES=

        To install:

            make all strip install

        Now go to section SHELL INTEGRATION below.

INSTALLATION NAMES

        By default the 'install' target will install the program in
        /usr/bin, the language files in /usr/share/locale
        and the man page in /usr/share/man. You can specify an
        installation prefix other than /usr by modifying the
        'prefix' variable. An Example:

            make prefix=$HOME clean all
            make prefix=$HOME strip install

SHELL INTEGRATION

        See manual page section "INSTALLATION" how to manually configure the
        shell to use the program.  It is required to configure your shell,
        otherwise wcd cannot work.

        Alternatively you can use the shell scripts that are provided to
        install the wcd function (sh) or alias (csh) under /etc/profile.d/.
        To install these scripts type:

            make install-profile

        If you wish that Wcd stores its files under $HOME/.wcd instead of
        $HOME, add DOTWCD=1. This will add a definition of WCDHOME=$HOME/.wcd
        (see manual).

            make install-profile DOTWCD=1

        Under Cygwin these shell scripts are always installed.

DOCUMENTATION

        Manual pages are generated from Perl POD files. By default
        the manual pages are are created in text and html format.
        To create a manual in PDF format type:

            make pdf

        PDF generation requires GhostScript to be installed.

BINARY DISTRIBUTION PACKAGE CREATION

        After installation, a package can be created that contains
        a ready-to-run wcd binary.

          Type `make dist' to create a .tar.gz file.

          Type `make dist-zip' to create a .zip file.


PORTABILITY

        See also file SOURCE.txt.

        --

        A compile error occurs when you use gcc < 3.0 and
        <stdbool.h> is included somewhere (e.g. in curses.h).

        Thanks to Kevin M. Rosenberg, apply the following patch:

            patch -p1 < patch/wcd_bool.diff

        --

        Conflicting curses.h ncurses.h

        On some systems curses.h is conflicting with ncurses.h. To
        compile wcd you can solve this by creating a symbolic link
        curses.h in the wcd source directory pointing to the ncurses.h
        file and adding -I. to CFLAGS in old/Makefile.ncurses.gcc.

        This problem was seen on a BSDI BSD/OS 4.0 system.
        /usr/local/include/ncurses.h


End of file
