Blame INSTALL

Packit Service b38f0b
TABLE OF CONTENTS
Packit Service b38f0b
=================
Packit Service b38f0b
Packit Service b38f0b
  Table Of Contents
Packit Service b38f0b
  Quick Instructions
Packit Service b38f0b
* Net-SNMP Specific Information
Packit Service b38f0b
  Long (but you should read these) Instructions
Packit Service b38f0b
  Installing the Perl/SNMP Module
Packit Service b38f0b
* Compilers and Options
Packit Service b38f0b
  Compiling For Multiple Architectures
Packit Service b38f0b
  Installation Names
Packit Service b38f0b
  Optional Features
Packit Service b38f0b
  Sharing Defaults
Packit Service b38f0b
  Operation Controls
Packit Service b38f0b
Packit Service b38f0b
  * = required reading
Packit Service b38f0b
Packit Service b38f0b
QUICK INSTRUCTIONS
Packit Service b38f0b
==================
Packit Service b38f0b
Packit Service b38f0b
  1) Run ./configure
Packit Service b38f0b
     (type "./configure --help" for a quick usage summary.)
Packit Service b38f0b
     (--prefix=PATH will change the default /usr/local installation path.)
Packit Service b38f0b
     (see "Compilers and Options" on changing the compiler to use)
Packit Service b38f0b
Packit Service b38f0b
  2) Optionally edit include/net-snmp/net-snmp-config.h
Packit Service b38f0b
     (due to prompting done by the configure script, this is very rarely
Packit Service b38f0b
      necessary.)
Packit Service b38f0b
Packit Service b38f0b
  3) make
Packit Service b38f0b
Packit Service b38f0b
  4) Run the next command as root:
Packit Service b38f0b
  5) make install
Packit Service b38f0b
Packit Service b38f0b
  6) configure the agent
Packit Service b38f0b
     (either using 'snmpconf' or by crafting an snmpd.conf file manually.
Packit Service b38f0b
      The file 'EXAMPLE.conf' may be a suitable starting point)
Packit Service b38f0b
Packit Service b38f0b
Note: By default, everything will be installed in /usr/local.
Packit Service b38f0b
      (see below for more instructions)
Packit Service b38f0b
Packit Service b38f0b
Net-SNMP Specific Information
Packit Service b38f0b
=============================
Packit Service b38f0b
Packit Service b38f0b
As of UCD-SNMP V3.3.1 the configuration files are now looked for in
Packit Service b38f0b
$(prefix)/share/snmp, where ($prefix) is defined as the value passed
Packit Service b38f0b
to the --prefix argument of the configure script, or /usr/local if
Packit Service b38f0b
undefined.  In version 3.0.3 till 3.3, the files were kept in
Packit Service b38f0b
$(prefix)/lib/snmp
Packit Service b38f0b
Packit Service b38f0b
Optional features to pass to configure for Net-SNMP can be obtained by
Packit Service b38f0b
running configure --help.
Packit Service b38f0b
Packit Service b38f0b
LONG (but you should read these) INSTRUCTIONS
Packit Service b38f0b
=============================================
Packit Service b38f0b
Packit Service b38f0b
   The `configure' shell script attempts to guess correct values for
Packit Service b38f0b
various system-dependent variables used during compilation.  It uses
Packit Service b38f0b
those values to create a `Makefile' in each directory of the package.
Packit Service b38f0b
It may also create one or more `.h' files containing system-dependent
Packit Service b38f0b
definitions.  Finally, it creates a shell script `config.status' that
Packit Service b38f0b
you can run in the future to recreate the current configuration, a file
Packit Service b38f0b
`config.cache' that saves the results of its tests to speed up
Packit Service b38f0b
reconfiguring, a file `config.log' containing compiler output
Packit Service b38f0b
(useful mainly for debugging `configure') and a file `configure-summary'
Packit Service b38f0b
containing the summary displayed at the end of the `configure' run.
Packit Service b38f0b
Packit Service b38f0b
   The file `include/net-snmp/net-snmp-config.h' is also generated
Packit Service b38f0b
at this time.  It contains IMPORTANT information such as the location
Packit Service b38f0b
of log and configuration files.  In some special cases you may need to
Packit Service b38f0b
modify this file but it is prefererable to work out a way of getting
Packit Service b38f0b
`configure' to set things up for your particular environment.
Packit Service b38f0b
Packit Service b38f0b
As the `configure' invocation often gets lengthy and difficult to
Packit Service b38f0b
type or if you have several different ways you want to configure a
Packit Service b38f0b
system, you may want to create a shell script containing your invocation.
Packit Service b38f0b
Packit Service b38f0b
   If you need to do unusual things to compile the package, please try
Packit Service b38f0b
to figure out how `configure' could check whether to do them, and mail
Packit Service b38f0b
diffs or instructions to the address given in the `README' so they can
Packit Service b38f0b
be considered for the next release.  If at some point `config.cache'
Packit Service b38f0b
contains results you don't want to keep, you may remove or edit it.
Packit Service b38f0b
Packit Service b38f0b
   The file `configure.in' is used to create `configure' by a program
Packit Service b38f0b
called `autoconf'.  You only need `configure.in' if you want to change
Packit Service b38f0b
it or regenerate `configure' using a newer version of `autoconf'.
Packit Service b38f0b
Packit Service b38f0b
The simplest way to compile this package is:
Packit Service b38f0b
Packit Service b38f0b
  1. `cd' to the directory containing the package's source code and type
Packit Service b38f0b
     `./configure' to configure the package for your system.  If you're
Packit Service b38f0b
     using `csh' on an old version of System V, you might need to type
Packit Service b38f0b
     `sh ./configure' instead to prevent `csh' from trying to execute
Packit Service b38f0b
     `configure' itself.
Packit Service b38f0b
Packit Service b38f0b
     Running `configure' takes awhile.  While running, it prints some
Packit Service b38f0b
     messages telling which features it is checking for.  When it
Packit Service b38f0b
     completes it prints a short message (also available in configure-summary)
Packit Service b38f0b
     indicating what functionality will be available when compiled.
Packit Service b38f0b
Packit Service b38f0b
  2. If necessary, edit include/net-snmp/net-snmp-config.h (see above).  
Packit Service b38f0b
Packit Service b38f0b
  3. Type `make' to compile the package.
Packit Service b38f0b
Packit Service b38f0b
  4. Type `make test' which runs a variety of tests to see what functionality
Packit Service b38f0b
     has been incorporated and if it works.
Packit Service b38f0b
Packit Service b38f0b
  5. Type `make install' to install the programs and any data files and
Packit Service b38f0b
     documentation.
Packit Service b38f0b
Packit Service b38f0b
  6. You can remove the program binaries and object files from the
Packit Service b38f0b
     source code directory by typing `make clean'.  To also remove the
Packit Service b38f0b
     files that `configure' created (so you can compile the package for
Packit Service b38f0b
     a different kind of computer), type `make distclean'.
Packit Service b38f0b
Packit Service b38f0b
  7. You can remove the application (but not the perl or python modules)
Packit Service b38f0b
     by typing `make uninstall'.
Packit Service b38f0b
Packit Service b38f0b
There may be additional installation issues discussed in the 
Packit Service b38f0b
README's for various platforms such as README.solaris.
Packit Service b38f0b
Packit Service b38f0b
Packit Service b38f0b
Installing the Perl/SNMP Module
Packit Service b38f0b
===============================
Packit Service b38f0b
Packit Service b38f0b
   The Perl/SNMP Module is now bundled with the net-snmp package
Packit Service b38f0b
(which includes other Net-SNMP specific modules as well), all of which
Packit Service b38f0b
are located in the net-snmp/perl directory. The Perl package provides
Packit Service b38f0b
a high level abstract interface to the functionality found in the
Packit Service b38f0b
Net-SNMP libraries and demon applications.
Packit Service b38f0b
Packit Service b38f0b
   It is recommended you install the perl modules as you build the
Packit Service b38f0b
   Net-SNMP package.  The configure script can be run as follows to
Packit Service b38f0b
   automatically find perl and use it to install the perl modules:
Packit Service b38f0b
Packit Service b38f0b
      ./configure --with-perl-modules
Packit Service b38f0b
Packit Service b38f0b
   If you wish to use the embedded perl support available in the
Packit Service b38f0b
   Net-SNMP agent (and starting in Net-SNMP 5.2, the trap receiver),
Packit Service b38f0b
   then use the following option instead:
Packit Service b38f0b
Packit Service b38f0b
      ./configure --enable-embedded-perl --enable-shared
Packit Service b38f0b
Packit Service b38f0b
   Starting with Net-SNMP 5.4, configure enables embedded Perl and the 
Packit Service b38f0b
   Perl modules by default when possible unless explicitly disabled.
Packit Service b38f0b
Packit Service b38f0b
   If you wish to build the perl modules by hand, *install Net-SNMP
Packit Service b38f0b
   first* and then change directories to the perl subdirectory and:
Packit Service b38f0b
Packit Service b38f0b
   Run:
Packit Service b38f0b
            cd perl
Packit Service b38f0b
            perl Makefile.PL
Packit Service b38f0b
            make
Packit Service b38f0b
            make test
Packit Service b38f0b
            make install (as root)
Packit Service b38f0b
Packit Service b38f0b
Packit Service b38f0b
Compilers and Options
Packit Service b38f0b
=====================
Packit Service b38f0b
Packit Service b38f0b
   Some systems require unusual options for compilation or linking that
Packit Service b38f0b
the `configure' script does not know about.  You can give `configure'
Packit Service b38f0b
initial values for variables by setting them in the environment.  Using
Packit Service b38f0b
a Bourne-compatible shell, you can do that on the command line like
Packit Service b38f0b
this:
Packit Service b38f0b
     CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure
Packit Service b38f0b
Packit Service b38f0b
Or on systems that have the `env' program, you can do it like this:
Packit Service b38f0b
     env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure
Packit Service b38f0b
Packit Service b38f0b
Compiling For Multiple Architectures
Packit Service b38f0b
====================================
Packit Service b38f0b
Packit Service b38f0b
   You can compile the package for more than one kind of computer at the
Packit Service b38f0b
same time, by placing the object files for each architecture in their
Packit Service b38f0b
own directory.  To do this, you must use a version of `make' that
Packit Service b38f0b
supports the `VPATH' variable, such as GNU `make'.  `cd' to the
Packit Service b38f0b
directory where you want the object files and executables to go and run
Packit Service b38f0b
the `configure' script.  `configure' automatically checks for the
Packit Service b38f0b
source code in the directory that `configure' is in and in `..'.
Packit Service b38f0b
Packit Service b38f0b
   If you have to use a `make' that does not supports the `VPATH'
Packit Service b38f0b
variable, there is a `maketarget' script that will generate a symlink'ed
Packit Service b38f0b
shadow-directory for the object files. Do a `sh maketarget', then `cd' into
Packit Service b38f0b
targets/`config.guess` and do the configuration and installation.
Packit Service b38f0b
Packit Service b38f0b
Installation Names
Packit Service b38f0b
==================
Packit Service b38f0b
Packit Service b38f0b
   By default, `make install' will install the package's files in
Packit Service b38f0b
`/usr/local/bin', `/usr/local/man', etc.  You can specify an
Packit Service b38f0b
installation prefix other than `/usr/local' by giving `configure' the
Packit Service b38f0b
option `--prefix=PATH'.
Packit Service b38f0b
Packit Service b38f0b
   You can specify separate installation prefixes for
Packit Service b38f0b
architecture-specific files and architecture-independent files.  If you
Packit Service b38f0b
give `configure' the option `--exec-prefix=PATH', the package will use
Packit Service b38f0b
PATH as the prefix for installing programs and libraries.
Packit Service b38f0b
Documentation and other data files will still use the regular prefix.
Packit Service b38f0b
Packit Service b38f0b
   If the package supports it, you can cause programs to be installed
Packit Service b38f0b
with an extra prefix or suffix on their names by giving `configure' the
Packit Service b38f0b
option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
Packit Service b38f0b
Packit Service b38f0b
Optional Features
Packit Service b38f0b
=================
Packit Service b38f0b
Packit Service b38f0b
   Some packages pay attention to `--enable-FEATURE' options to
Packit Service b38f0b
`configure', where FEATURE indicates an optional part of the package.
Packit Service b38f0b
They may also pay attention to `--with-PACKAGE' options, where PACKAGE
Packit Service b38f0b
is something like `gnu-as' or `x' (for the X Window System).  The
Packit Service b38f0b
`README' should mention any `--enable-' and `--with-' options that the
Packit Service b38f0b
package recognizes.
Packit Service b38f0b
Packit Service b38f0b
   For packages that use the X Window System, `configure' can usually
Packit Service b38f0b
find the X include and library files automatically, but if it doesn't,
Packit Service b38f0b
you can use the `configure' options `--x-includes=DIR' and
Packit Service b38f0b
`--x-libraries=DIR' to specify their locations.
Packit Service b38f0b
Packit Service b38f0b
Specifying the System Type
Packit Service b38f0b
==========================
Packit Service b38f0b
Packit Service b38f0b
   There may be some features `configure' can not figure out
Packit Service b38f0b
automatically, but needs to determine by the type of host the package
Packit Service b38f0b
will run on.  Usually `configure' can figure that out, but if it prints
Packit Service b38f0b
a message saying it can not guess the host type, give it the
Packit Service b38f0b
`--host=TYPE' option.  TYPE can either be a short name for the system
Packit Service b38f0b
type, such as `sun4', or a canonical name with three fields:
Packit Service b38f0b
     CPU-COMPANY-SYSTEM
Packit Service b38f0b
Packit Service b38f0b
See the file `config.sub' for the possible values of each field.  If
Packit Service b38f0b
`config.sub' isn't included in this package, then this package doesn't
Packit Service b38f0b
need to know the host type.
Packit Service b38f0b
Packit Service b38f0b
   If you are building compiler tools for cross-compiling, you can also
Packit Service b38f0b
use the `--target=TYPE' option to select the type of system they will
Packit Service b38f0b
produce code for and the `--build=TYPE' option to select the type of
Packit Service b38f0b
system on which you are compiling the package.
Packit Service b38f0b
Packit Service b38f0b
Sharing Defaults
Packit Service b38f0b
================
Packit Service b38f0b
Packit Service b38f0b
   If you want to set default values for `configure' scripts to share,
Packit Service b38f0b
you can create a site shell script called `config.site' that gives
Packit Service b38f0b
default values for variables like `CC', `cache_file', and `prefix'.
Packit Service b38f0b
`configure' looks for `PREFIX/share/config.site' if it exists, then
Packit Service b38f0b
`PREFIX/etc/config.site' if it exists.  Or, you can set the
Packit Service b38f0b
`CONFIG_SITE' environment variable to the location of the site script.
Packit Service b38f0b
A warning: not all `configure' scripts look for a site script.
Packit Service b38f0b
Packit Service b38f0b
Operation Controls
Packit Service b38f0b
==================
Packit Service b38f0b
Packit Service b38f0b
   `configure' recognizes the following options to control how it
Packit Service b38f0b
operates.
Packit Service b38f0b
Packit Service b38f0b
`--cache-file=FILE'
Packit Service b38f0b
     Use and save the results of the tests in FILE instead of
Packit Service b38f0b
     `./config.cache'.  Set FILE to `/dev/null' to disable caching, for
Packit Service b38f0b
     debugging `configure'.
Packit Service b38f0b
Packit Service b38f0b
`--help'
Packit Service b38f0b
     Print a summary of the options to `configure', and exit.
Packit Service b38f0b
Packit Service b38f0b
`--quiet'
Packit Service b38f0b
`--silent'
Packit Service b38f0b
`-q'
Packit Service b38f0b
     Do not print messages saying which checks are being made.
Packit Service b38f0b
Packit Service b38f0b
`--srcdir=DIR'
Packit Service b38f0b
     Look for the package's source code in directory DIR.  Usually
Packit Service b38f0b
     `configure' can determine that directory automatically.
Packit Service b38f0b
Packit Service b38f0b
`--version'
Packit Service b38f0b
     Print the version of Autoconf used to generate the `configure'
Packit Service b38f0b
     script, and exit.
Packit Service b38f0b
Packit Service b38f0b
`configure' also accepts some other, not widely useful, options.
Packit Service b38f0b