		 CONFIGURATION AND INSTALLATION OF NN & NN-TK
		 --------------------------------------------


This file describes the necessary steps to configure and install nn.
You are advised to read this file before proceeding with the installation.

If you want to use NNTP (accessing news from a remote host), you must
also read the file NNTP.

NN & NN-TK
----------
It is a compile option (TK) as to whether NN (the character interface)
or NN-TK (the X windows interface) is built.

To build NN-TK you need to have TCL and TK installed.

The following command line prompts are used in the examples:
   `$' is used when no special privileges are required.
   `#' is used when SUPER USER privileges may be required.


				STEP 1

		            Run ./configure
		            ---------------

NN/NN-TK now uses gnu autoconfig, doing
	./configure
will run a script that tries to configure nn for your system
and will produce a file nnconfig.h, this can be manually edited
if there are problems with the decisions that configure makes.

If configure doesn't find inews then NN will use it's own version.

Configure caches information in config.cache, if the distribution
is moved to a different system it may be necessary to delete that
file,  make clean   will do that.

				STEP 2

		 EDIT config.h TO REFLECT YOUR SYSTEM
		 ------------------------------------
This contains parameters for the configuration of NN such as
whether to build NN or NN-TK, whether to include NNTP support,
where to install etc.

For each required configuration parameter, the config.h file contains
verbose comments explaining the meaning of each parameter in the file.
Read and follow these instructions carefully.  If you do that, nn
should compile and run without problems.

Notice that every time you edit config.h, the file update.h is
modified to make a new configuration level for the version in the
source directory.  The current configuration is showed in the version
string as #number.

                        STEP 2.1: NN or NN-tk
                        ---------------------
Whether the TK define is set determines whether NN or NN-TK is 
built, TKINCLUDE and TKLIB  only need to be set if the TCL/TK
if configure did set them, ie TK version is less than 4.1.

                        STEP 2.2: NNTP
                        --------------
The NNTP define determines if NNTP support is to be compiled in.
Even if NNTP is defined you can still read news from a local
news spool by either not having the NNTP server file or setting
it to the local host.

See the file doc/NNTP for further info.

			STEP 2.3: LOCALIZE NN
			---------------------

You will have to specify a number of files and directories which nn
has to know about to work properly.  If you don't specify these, nn
will in most cases use it own alternatives which will correspond to
common practices on most installations.

The following directories and files can be defined in config.h:


BIN_DIRECTORY		(mandatory)

	The directory where you want the user programs to be
	installed.  The following programs will be installed in that
	directory:

	nn		The news reader program
	nn-tk		The X  windows news reader program

	nnacct		Accounting, quota, and access management
	nncheck		Check for unread articles (link to nn)
	nngrep		Grep for news groups (link to nn)
	nnpost		Standalone posting program (link to nn).
	nntidy		Cleans up the rc file (link to nn)


LIB_DIRECTORY

	The directory where nn's auxiliary programs and files will
	be installed unless another directory is specified by one of
	the following definitions.



CLIENT_DIRECTORY	(optional, default = LIB_DIRECTORY)

	Contains the auxiliary programs and files required by the nn
	program:

	aux	The shell script used in connection with replies etc.
		It knows about common editors like vi and gnu emacs to
		have them position the cursor appropriately.  To add
		support for your own favorite editor, you should edit
		the file aux.sh, not the compiled `aux' script!



HELP_DIRECTORY		(optional, default = CLIENT_DIRECTORY/help)

	The directory where the help files and online manual are
	stored.  This directory is an obvious candidate for sharing in
	a network.


CACHE_DIRECTORY		(optional, default = each user's .nn directory)

	Only used with NNTP!! Directory to be used as a common storage
	for temporary cache files when nn is used with NNTP.  Using a
	common directory for cache files allows you to clean these out
	on reboot with a single "rm" command in the rc file:
	 	(cd CACHE_DIRECTORY; rm -f *)
	But of course this requires that you use a separate directory
	for the cache!


TMP_DIRECTORY		(optional, default = /usr/tmp)

	The directory to be used as temporary storage for files used
	when editing responses etc.


NEWS_DIRECTORY		(optional, default = /usr/spool/news)

	The directory containing the news spool directories and files.
	It is not required when a remote NNTP server is used.


NEWS_LIB_DIRECTORY	(optional, default = /usr/lib/news)

	The directory containing the news system's active file and
	other related files.

	When a remote NNTP server is used, it is still needed as the
	location of the (mini-)inews program if posting is allowed
	(unless INEWS is explicitly defined to override the default
	location).


				STEP 3

			 COMPILE THE SOFTWARE: make
			 --------------------------

To compile the software, you just have to run one of the following
make commands.

To make the complete package , do

	$ make all

This step actually applies the C preprocessor to xmakefile to
produces ymakefile which is then used to make NN. This preprocessor
step will probably produce error message, these can be ignored.


				STEP 4

		       INSTALLING THE SOFTWARE: ./inst
		       -------------------------------

Installation of the nn software is handled entirely via a script
"./inst" created during the compilation.  The components of nn are
split into five parts, which can be installed separately or in various
combinations depending on whether you run a stand-alone system or
networked systems sharing the database and other parts of the nn
package.  The five components are:

1) User files and programs (machince dependent, shareable)
   Install the BIN_DIRECTORY programs.

2) Auxiliary programs (configuration dependent, shareable)
   Install the CLIENT_DIRECTORY files and programs, this includes
   the tcl directory when NN-TK keeps its tcl files.

3) Documentation (shareable)
   Install the MAN pages in the proper directories.

4) Help files (shareable)
   Install the HELP_DIRECTORY files (except online manual).

5) Online manual (shareable with 5)
   Format and install the online manual in HELP_DIRECTORY.

6) The nn-tk binary
   Install in BIN_DIRECTOR

7) Install inews, needed if inews not found on system.

Unless you have defined yourself as the owner of the nn package and
have write permission on all the necessary directories, you will need
to be super-user to install nn, so start with

	$ su

Now run the installation script:

	# ./inst

The `inst' script will list a menu with the following choices:

(1)-(6)	Install individual parts of the package.

(s)	Install a complete server + client package (1-6).

(c)	NN (character version) full installation 

(t)	NN-TK full installation 

(h)	Install a client with local auxiliary files, but shared
	documentation and help files (2-3).

(n)	Install a client accessing only the database via a network (2-6).

(m)	Install only the nnmaster (1).

(c)	Install only the client programs (2).

(u)	Update already installed parts of the package.  This will
	check for the existence of the old programs, and only update
	programs and files already installed.  You will typically use
	this after applying patches.

You can also run the `inst' script with the choices as arguments, e.g.

	./inst m c

TCL
---
The tcl files the implement the X interface in NN-TK are installed
in the tcl directory in the CLIENT_DIRECTORY, usually /usr/local/lib/nn/tcl.
NN-TK will will look for the tcl directory in the current directory and
the in .nn before looking in /usr/local/lib/nn/tcl so it is possible to
replace the system wide tcl files with a local copy.

EXMH
----
Using EXMH adds a significant extra capabilities to NN-TK.

To include the EXMH routines create a symbolic link named exmh
in the tcl directory pointing to the EXMH lib directory. It
isn't necessary to have MH installed. If EXMH is not available
NN will still work, but will less functionality.



				STEP 7

		    INSTALL AND EDIT GLOBAL FILES
		    -----------------------------

Depending on your needs, you should create the following files on each
host running nn (you may also just share the files if you like):

CLIENT_DIRECTORY/init
	The global init file for all users on the system.  Users will
	be able to override the definitions in this file, but you can
	probably make some sensible decisions which will prevent
	novice users from getting into trouble, for example set the
	default distribution to "local" etc.

	You can also specify a global presentation sequence here.

	You may use init.sample as a starting point, but don't use it
	without careful examination.  Especially, the sequence part
	is mainly an illustration of the possibilities.  If you are in
	doubt, just delete the sequence part of the file (groups will
	then be presented in pure alphabetical order).

CLIENT_DIRECTORY/routes
	You DO NOT NEED this file if you already run a domain based
	mailer, i.e. when HAVE_ROUTING is defined in config.h.

	Otherwise, you can use it as a configuration file for the
	domain address remapping done by nn in reply addresses and the
	nnmail program.  You may use routes.sample as a starting point
	(it briefly describes how to build a routes file).

	Please notice that neither the routes functionality, nor
	nnmail is a supported part of nn - if you really want to
	run a domain-based mailer, get smail 2.5 or later.  And if you
	ask me how to use it I will answer: "Get SMAIL instead".

CLIENT_DIRECTORY/motd
	Every time you change this file, it will be shown to the nn
	users the next time they invoke nn.  This can be used to
	inform the users about changes in the news environment or
	local policies.  (motd = message of the day)


NNTP_SERVER
	Must contain the host name of the NNTP-server when NNTP is
	used.  If you already run NNTP with your other news readers,
	this file does not need to be modified.

CLIENT_DIRECTORY/nn-defaults
	This file is in X resource format, it contains the defaults 
	for the various NN-TK options. It also contains resources
	setting other aspects of the interface such as colors, fonts
	and adjustments to the EXMH interface. The resources can also
	be set in the X server.

	The system wide nn-defaults can be overridden by having a
	local file in .nn


				STEP 8

		       TEST THE BASIC FUNCTIONS
		       ------------------------

If any of the following tests fails or you see other peculiar
behavior, you should consult the PROBLEMS file.  You may not be the
only one to have seen the problems, and there might even be a solution.

There are a few things you should check to ensure the proper
functioning of nn.

1) Backup your current .newsrc file if you have one.  (Don't save it
   in .newsrc.bak or .newsrc.orig since nn may use these names).

2) Run `nn'.  

3) Does nn find any news?  If not, does nn -x find anything?

4) Can you send mail to yourself?  Try the sequence:
	m (return) (return) testing (return)
	edit the letter
	s (return)

   If not, you should check the REC_MAIL program.

5) Can you post an article to the local test group?  Try:
	:post (return)
   	test (return)
   	local (return)
	edit the article
	s (return)

   If not, you should check the INEWS program.


	     -------------------------------------------
			 IF EVERYTHING WORKS
		 YOU HAVE COMPLETED THE INSTALLATION
	     -------------------------------------------


