2005-11-10 10:09:42 +00:00
|
|
|
.\"
|
|
|
|
.\" Copyright (c) 2005
|
|
|
|
.\" Hartmut Brandt.
|
|
|
|
.\" All rights reserved.
|
|
|
|
.\"
|
|
|
|
.\" Author: Hartmut Brandt <harti@FreeBSD.org>
|
|
|
|
.\"
|
|
|
|
.\" Redistribution and use in source and binary forms, with or without
|
|
|
|
.\" modification, are permitted provided that the following conditions
|
|
|
|
.\" are met:
|
|
|
|
.\" 1. Redistributions of source code must retain the above copyright
|
|
|
|
.\" notice, this list of conditions and the following disclaimer.
|
|
|
|
.\" 2. Redistributions in binary form must reproduce the above copyright
|
|
|
|
.\" notice, this list of conditions and the following disclaimer in the
|
|
|
|
.\" documentation and/or other materials provided with the distribution.
|
|
|
|
.\"
|
|
|
|
.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
|
|
|
|
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
|
|
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
|
|
.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
|
|
|
|
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
|
|
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
|
|
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
|
|
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
|
|
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
|
|
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
|
|
.\" SUCH DAMAGE.
|
|
|
|
.\"
|
|
|
|
.\" $FreeBSD$
|
|
|
|
.\"
|
2005-11-10 12:08:17 +00:00
|
|
|
.Dd November 10, 2005
|
|
|
|
.Dt BSD.SNMPMOD.MK 7
|
2005-11-10 10:09:42 +00:00
|
|
|
.Os
|
|
|
|
.Sh NAME
|
|
|
|
.Nm bsd.snmpmod.mk
|
|
|
|
.Sh SYNOPSIS
|
|
|
|
.Fd .include <bsd.snmpmod.mk>
|
|
|
|
.Sh DESCRIPTION
|
|
|
|
The file
|
|
|
|
.In bsd.snmpmod.mk
|
|
|
|
simplifies the building of modules for the Begemot SNMP daemon
|
|
|
|
.Xr bsnmpd 1 .
|
|
|
|
It provides some common functions for building a module and
|
|
|
|
relies on
|
|
|
|
.In bsd.lib.mk ,
|
|
|
|
which is included by
|
|
|
|
.In bsd.snmpmod.mk
|
|
|
|
to actually build the shared library.
|
|
|
|
.Pp
|
|
|
|
The following
|
|
|
|
.Xr make 1
|
|
|
|
variables control the special functions:
|
2005-11-10 12:08:17 +00:00
|
|
|
.Bl -tag -width ".Va EXTRAMIBDEFS"
|
2005-11-10 10:09:42 +00:00
|
|
|
.It Va MOD
|
|
|
|
The short name of the module.
|
|
|
|
The name of the shared library will be
|
|
|
|
.Pa snmp_${MOD}.so .
|
|
|
|
There must exist a file
|
|
|
|
.Pa ${MOD}_tree.def
|
|
|
|
for compilation with
|
|
|
|
.Xr gensnmptree 1
|
|
|
|
which contains the definition of the MIB tree implemented by the module.
|
|
|
|
.It Va EXTRAMIBDEFS
|
|
|
|
A list of extra MIB definition files for
|
|
|
|
.Xr gensnmptree 1 .
|
|
|
|
This is optional.
|
|
|
|
.It Va XSYM
|
|
|
|
A list of symbols to be extracted from the MIB definition files by
|
|
|
|
.Xr gensnmptree 1 .
|
|
|
|
This is optional.
|
|
|
|
.It Va DEFS
|
2005-11-10 12:08:17 +00:00
|
|
|
A list of MIB definition files to be installed.
|
|
|
|
This is optional.
|
2005-11-10 10:09:42 +00:00
|
|
|
.It Va BMIBS
|
2005-11-10 12:08:17 +00:00
|
|
|
A list of textual MIBs to be installed.
|
|
|
|
This is optional.
|
2005-11-10 10:09:42 +00:00
|
|
|
.El
|
|
|
|
.Pp
|
|
|
|
Three file are automatically created from the MIB definition files and
|
|
|
|
the
|
|
|
|
.Va XSYM
|
|
|
|
variable:
|
2005-11-10 12:08:17 +00:00
|
|
|
.Bl -tag -width ".Va EXTRAMIBDEFS"
|
2005-11-10 10:09:42 +00:00
|
|
|
.It Pa ${MOD}_tree.c
|
|
|
|
This contains a table with the tree implemented by the module.
|
|
|
|
It is automatically included into the
|
|
|
|
.Va SRCS
|
|
|
|
variable.
|
|
|
|
.It Pa ${MOD}_tree.h
|
|
|
|
This contains preprocessor defines for all the OIDs defined by the module
|
|
|
|
and can be included in the module's source code.
|
|
|
|
.It Pa ${MOD}_oid.h
|
|
|
|
OID preprocessor definitions for all the symbols listed in
|
|
|
|
.Va XSYMS .
|
|
|
|
This is to be included into the module's source code.
|
|
|
|
.El
|
|
|
|
.Sh SEE ALSO
|
|
|
|
.Xr bsnmpd 1 ,
|
|
|
|
.Xr gensnmptree 1 ,
|
|
|
|
.Xr snmpmod 3
|