On 20/07/07, Need Help <[EMAIL PROTECTED]> wrote:
> config_add_mib(OC-STB-HOST-MIB)
>config_require(..../ocStbHostAnalogVideoTable_interface)
>
> What is the significance of these lines? Are they similiar to "include"
> statements?
These two lines are used by the "configure" script, to set up the
build environment.
The "config_add-mib()" line is used add the specified MIB to the
list of MIBs that will be loaded by default. The idea here is that if
you are compiling an agent that implements the OC-STB-HOST-MIB,
then it would probably be useful for "snmpget" and friends to load
this MIB automatically.
The "config_require()" line is used to ensure that the agent will
be compiled with all the necessary code files. You'd typically run
configure --with-mib-modules=myMib
referring to a single pair of code files 'myMib.h' and 'myMib.c'.
The file 'myMib.h' would often include "config_require()" statements
to pull in all the other bits of the MIB implementation - either directly
or via other header files.
If you watch the output of configure, you'll see it chuntering away to
itself, building up a list of code files to compile into the agent. This
list is used to construct the Makefile, which is then used to compile
the selected files, and link them into the agent libraries.
Dave
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders