mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
From: Alexander Dahl <post@lespocky.de>
To: ptxdist@pengutronix.de
Subject: [ptxdist] [PATCH 4/8] net-snmp: added extra menu entries for mib modules
Date: Fri, 20 Sep 2013 15:59:31 +0200	[thread overview]
Message-ID: <1379685575-11135-5-git-send-email-post@lespocky.de> (raw)
In-Reply-To: <1379685575-11135-1-git-send-email-post@lespocky.de>

Previously the MIB modules to be compiled where specified in a space
separated list only. Other packages depending on special modules could
not easily set a dependency. Now there are some extra menu entries to be
referenced by other packages and still the old list. Both are integrated
at build time.

Signed-off-by: Alexander Dahl <post@lespocky.de>
---
 rules/net-snmp.in   |   48 ++++++++++++++++++++++++++++++++++++++++++++++++
 rules/net-snmp.make |    9 ++++++++-
 2 files changed, 56 insertions(+), 1 deletion(-)

diff --git a/rules/net-snmp.in b/rules/net-snmp.in
index 95b7d43..a36a915 100644
--- a/rules/net-snmp.in
+++ b/rules/net-snmp.in
@@ -6,6 +6,7 @@ menuconfig NET_SNMP
 	select GCCLIBS_GCC_S	if NET_SNMP_AGENT
 	select LIBC_DL		if NET_SNMP_AGENT || NET_SNMP_APPLICATIONS
 	select LIBNL		if NET_SNMP_AGENT || NET_SNMP_APPLICATIONS
+	select LM_SENSORS	if NET_SNMP_MIB_MODULES_LM_SENSORS
 
 if NET_SNMP
 
@@ -101,10 +102,57 @@ config NET_SNMP_PERSISTENT_DIR
 	string
 	default	"/var/net-snmp"
 
+menu "additional mib modules        "
+
+config NET_SNMP_MIB_MODULES_AGENTX
+	prompt "agentx"
+	bool
+	help
+	  AgentX support (includes both agentx/master and agentx/client).
+
+config NET_SNMP_MIB_MODULES_UCD_SNMP
+	prompt "ucd_snmp"
+	bool
+	help
+	  UCD-SNMP-MIB specific extensions.
+
+config NET_SNMP_MIB_MODULES_LM_SENSORS
+	prompt "ucd-snmp/lmsensorsMib"
+	bool
+	help
+	  hardware monitoring (LM-SENSORS-MIB)
+
 config NET_SNMP_MIB_MODULES
 	prompt "additional mib modules"
 	string
 	default	""
+	help
+	  space separated list of optional modules
+	    tunnel               Linux TUNNEL-MIB support (ifTable extension)
+	    mibII/interfaces     (old ifTable implementation)
+	    misc/ipfwacc         accounting rules IP firewall information
+	    ipfwchains/ipfwchains  firewall chains under ipfw
+	    sctp-mib             support for the SCTP-MIB
+	    etherlike-mib        support for the EtherLike-MIB
+
+config NET_SNMP_WITHOUT_MIB_MODULES
+	prompt "without these mib modules"
+	string
+	default ""
+	help
+	  space separated list of default mib modules compiled into the
+	  agent (which can be removed):
+	    mibII                  support for the mib-II tree.
+	    snmpv3mibs             support for the snmpv3 mib modules.
+	    agent_mibs             NET-SNMP-AGENT-MIB extensions
+	    notification           mibs supporting specification of trap destinations.
+	    target                 Support for the SNMP WGs TARGET-MIB.
+	    utilities              general agent configuration utilities.
+	    disman/event           support for the DISMAN-EVENT-MIB
+	    disman/schedule        support for the DISMAN-SCHEDULE-MIB
+	    host                   host resources mib support.
+
+endmenu
 
 config NET_SNMP_DEFAULT_MIBS
 	prompt "default mib id's to read"
diff --git a/rules/net-snmp.make b/rules/net-snmp.make
index 894946b..fca6417 100644
--- a/rules/net-snmp.make
+++ b/rules/net-snmp.make
@@ -33,6 +33,12 @@ NET_SNMP_PATH	:= PATH=$(CROSS_PATH)
 NET_SNMP_ENV 	:= $(CROSS_ENV)
 NET_SNMP_BINCONFIG_GLOB := net-snmp-config
 
+NET_SNMP_MIB_MODULES-y	:= $(call remove_quotes,$(PTXCONF_NET_SNMP_MIB_MODULES))
+NET_SNMP_MIB_MODULES-	:= $(call remove_quotes,$(PTXCONF_NET_SNMP_WITHOUT_MIB_MODULES))
+NET_SNMP_MIB_MODULES-$(PTXCONF_NET_SNMP_MIB_MODULES_AGENTX) += agentx
+NET_SNMP_MIB_MODULES-$(PTXCONF_NET_SNMP_MIB_MODULES_UCD_SNMP) += ucd_snmp
+NET_SNMP_MIB_MODULES-$(PTXCONF_NET_SNMP_MIB_MODULES_LM_SENSORS) += ucd-snmp/lmsensorsMib
+
 #
 # autoconf
 #
@@ -42,7 +48,8 @@ NET_SNMP_AUTOCONF := \
 	--with-defaults \
 	--disable-manuals \
 	--without-openssl \
-	--with-mib-modules=$(PTXCONF_NET_SNMP_MIB_MODULES) \
+	--with-mib-modules="$(NET_SNMP_MIB_MODULES-y)" \
+	--with-out-mib-modules="$(NET_SNMP_MIB_MODULES-)" \
 	--with-mibs=$(PTXCONF_NET_SNMP_DEFAULT_MIBS) \
 	--with-logfile=$(call remove_quotes,$(PTXCONF_NET_SNMP_LOGFILE)) \
 	--with-persistent-directory=$(call remove_quotes,$(PTXCONF_NET_SNMP_PERSISTENT_DIR)) \
-- 
1.7.10.4


-- 
ptxdist mailing list
ptxdist@pengutronix.de

  parent reply	other threads:[~2013-09-20 14:00 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-20 13:59 [ptxdist] net-snmp: patch series again Alexander Dahl
2013-09-20 13:59 ` [ptxdist] [PATCH 1/8] net-snmp: improve menu help texts Alexander Dahl
2013-09-20 13:59 ` [ptxdist] [PATCH 2/8] net-snmp: check mib config by default Alexander Dahl
2013-09-20 13:59 ` [ptxdist] [PATCH 3/8] net-snmp: enable rewritten mib modules " Alexander Dahl
2013-09-20 13:59 ` Alexander Dahl [this message]
2013-09-20 13:59 ` [ptxdist] [PATCH 5/8] net-snmp: remove no longer used/needed stuff Alexander Dahl
2013-09-20 13:59 ` [ptxdist] [PATCH 6/8] net-snmp: let user choose MIB files to install Alexander Dahl
2013-09-20 13:59 ` [ptxdist] [PATCH 7/8] net-snmp: reorder menu entries (menus on top) Alexander Dahl
2013-09-20 13:59 ` [ptxdist] [PATCH 8/8] net-snmp: fix vim mode lines Alexander Dahl

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1379685575-11135-5-git-send-email-post@lespocky.de \
    --to=post@lespocky.de \
    --cc=ptxdist@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox