summaryrefslogtreecommitdiffstats
path: root/meta-openembedded/meta-oe/recipes-support/libsmi
diff options
context:
space:
mode:
Diffstat (limited to 'meta-openembedded/meta-oe/recipes-support/libsmi')
-rw-r--r--meta-openembedded/meta-oe/recipes-support/libsmi/libsmi/libsmi-fix-the-test-dump-files.patch277
-rw-r--r--meta-openembedded/meta-oe/recipes-support/libsmi/libsmi/smi.conf48
-rw-r--r--meta-openembedded/meta-oe/recipes-support/libsmi/libsmi_0.5.0.bb32
3 files changed, 357 insertions, 0 deletions
diff --git a/meta-openembedded/meta-oe/recipes-support/libsmi/libsmi/libsmi-fix-the-test-dump-files.patch b/meta-openembedded/meta-oe/recipes-support/libsmi/libsmi/libsmi-fix-the-test-dump-files.patch
new file mode 100644
index 000000000..134a8bb41
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/libsmi/libsmi/libsmi-fix-the-test-dump-files.patch
@@ -0,0 +1,277 @@
+From 460d3a5ef450c30b34a663a073ee53329441ef6e Mon Sep 17 00:00:00 2001
+From: Jackie Huang <jackie.huang@windriver.com>
+Date: Tue, 23 Feb 2016 16:34:38 +0800
+Subject: [PATCH] libsmi: fix the test dump files
+
+These test dump files were generated by smidump 0.4.5
+which would not match with the ones generated by 0.4.8,
+so update them with the ones for 0.4.8.
+
+Upstream-Status: Pending
+
+Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
+---
+ test/dumps/cm/MAU-MIB | 8 ++++----
+ test/dumps/cm/RMON2-MIB | 6 +++---
+ test/dumps/sming/IF-MIB | 22 +++++++++++++---------
+ test/dumps/sming/MAU-MIB | 19 +++++++++++--------
+ test/dumps/sming/RMON2-MIB | 40 ++++++++++++++++++++++++----------------
+ test/dumps/sming/SNMPv2-MIB | 11 +++++++----
+ 6 files changed, 62 insertions(+), 44 deletions(-)
+
+diff --git a/test/dumps/cm/MAU-MIB b/test/dumps/cm/MAU-MIB
+index 0d97284..0cfd4e1 100644
+--- a/test/dumps/cm/MAU-MIB
++++ b/test/dumps/cm/MAU-MIB
+@@ -53,7 +53,7 @@
+ <attribute name="text">
+ <composite type="text">
+ <attribute name="string">
+- <string>#Conceptual model of MAU-MIB - generated by smidump 0.4.5#</string>
++ <string>#Conceptual model of MAU-MIB - generated by smidump 0.4.8#</string>
+ </attribute>
+ <attribute name="font">
+ <font name="Courier"/>
+@@ -1294,7 +1294,7 @@
+ <point val="29.52,49.18"/>
+ </attribute>
+ <attribute name="obj_bb">
+- <rectangle val="28.67,32.93;30.37,34.63"/>
++ <rectangle val="28.67,32.93;30.37,34.62"/>
+ </attribute>
+ <attribute name="orth_points">
+ <point val="29.52,49.18"/>
+@@ -1678,7 +1678,7 @@
+ <point val="37.68,49.18"/>
+ </attribute>
+ <attribute name="obj_bb">
+- <rectangle val="28.67,32.93;30.37,34.63"/>
++ <rectangle val="28.67,32.93;30.37,34.62"/>
+ </attribute>
+ <attribute name="orth_points">
+ <point val="37.68,49.18"/>
+@@ -1737,7 +1737,7 @@
+ <point val="29.52,35.78"/>
+ </attribute>
+ <attribute name="obj_bb">
+- <rectangle val="28.67,32.93;30.37,34.63"/>
++ <rectangle val="28.67,32.93;30.37,34.62"/>
+ </attribute>
+ <attribute name="orth_points">
+ <point val="29.52,35.78"/>
+diff --git a/test/dumps/cm/RMON2-MIB b/test/dumps/cm/RMON2-MIB
+index 30ae8dd..1b9d268 100644
+--- a/test/dumps/cm/RMON2-MIB
++++ b/test/dumps/cm/RMON2-MIB
+@@ -53,7 +53,7 @@
+ <attribute name="text">
+ <composite type="text">
+ <attribute name="string">
+- <string>#Conceptual model of RMON2-MIB - generated by smidump 0.4.5#</string>
++ <string>#Conceptual model of RMON2-MIB - generated by smidump 0.4.8#</string>
+ </attribute>
+ <attribute name="font">
+ <font name="Courier"/>
+@@ -2841,8 +2841,8 @@
+ </attribute>
+ <attribute name="orth_points">
+ <point val="18.80,55.45"/>
+- <point val="18.80,68.63"/>
+- <point val="22.80,68.63"/>
++ <point val="18.80,68.62"/>
++ <point val="22.80,68.62"/>
+ <point val="22.80,81.80"/>
+ </attribute>
+ <attribute name="orth_orient">
+diff --git a/test/dumps/sming/IF-MIB b/test/dumps/sming/IF-MIB
+index 21432cb..c2ffc06 100644
+--- a/test/dumps/sming/IF-MIB
++++ b/test/dumps/sming/IF-MIB
+@@ -1,16 +1,18 @@
+ //
+-// This module has been generated by smidump 0.4.5. Do not edit.
++// This module has been generated by smidump 0.4.8. Do not edit.
+ //
+ module IF-MIB {
+
+- import IANAifType-MIB (IANAifType);
+- import IRTF-NMRG-SMING (Counter32, Counter64,
+- DisplayString255, Gauge32,
+- PhysAddress, TimeStamp, TimeTicks,
+- TruthValue);
+- import IRTF-NMRG-SMING-SNMP (AutonomousType, RowStatus,
+- TestAndIncr, mib-2);
+- import SNMPv2-MIB (snmpTraps);
++ import SNMPv2-SMI (MODULE-IDENTITY, OBJECT-TYPE, Counter32,
++ Gauge32, Counter64, Integer32, TimeTicks,
++ mib-2, NOTIFICATION-TYPE);
++ import SNMPv2-TC (TEXTUAL-CONVENTION, DisplayString,
++ PhysAddress, TruthValue, RowStatus,
++ TimeStamp, AutonomousType, TestAndIncr);
++ import SNMPv2-CONF (MODULE-COMPLIANCE, OBJECT-GROUP,
++ NOTIFICATION-GROUP);
++ import SNMPv2-MIB (snmpTraps);
++ import IANAifType-MIB (IANAifType);
+
+ //
+ // MODULE META INFORMATION
+@@ -79,6 +81,7 @@ module IF-MIB {
+ typedef InterfaceIndex {
+ type Integer32 (1..2147483647);
+ format "d";
++ status current;
+ description
+ "A unique value, greater than zero, for each interface or
+ interface sub-layer in the managed system. It is
+@@ -91,6 +94,7 @@ module IF-MIB {
+ typedef InterfaceIndexOrZero {
+ type Integer32 (0..2147483647);
+ format "d";
++ status current;
+ description
+ "This textual convention is an extension of the
+ InterfaceIndex convention. The latter defines a greater
+diff --git a/test/dumps/sming/MAU-MIB b/test/dumps/sming/MAU-MIB
+index 2cffd99..64cf714 100644
+--- a/test/dumps/sming/MAU-MIB
++++ b/test/dumps/sming/MAU-MIB
+@@ -1,15 +1,18 @@
+ //
+-// This module has been generated by smidump 0.4.5. Do not edit.
++// This module has been generated by smidump 0.4.8. Do not edit.
+ //
+ module MAU-MIB {
+
+- import IANA-MAU-MIB (IANAifJackType,
+- IANAifMauAutoNegCapBits,
+- IANAifMauMediaAvailable,
+- IANAifMauTypeListBits);
+- import IF-MIB (InterfaceIndex);
+- import IRTF-NMRG-SMING (Counter32, Counter64, TruthValue);
+- import IRTF-NMRG-SMING-SNMP (AutonomousType, mib-2);
++ import SNMPv2-SMI (Counter32, Integer32, Counter64, OBJECT-TYPE,
++ MODULE-IDENTITY, NOTIFICATION-TYPE, mib-2);
++ import SNMPv2-TC (TruthValue, AutonomousType,
++ TEXTUAL-CONVENTION);
++ import SNMPv2-CONF (OBJECT-GROUP, MODULE-COMPLIANCE,
++ NOTIFICATION-GROUP);
++ import IF-MIB (InterfaceIndex);
++ import IANA-MAU-MIB (IANAifMauTypeListBits,
++ IANAifMauMediaAvailable,
++ IANAifMauAutoNegCapBits, IANAifJackType);
+
+ //
+ // MODULE META INFORMATION
+diff --git a/test/dumps/sming/RMON2-MIB b/test/dumps/sming/RMON2-MIB
+index 423b9bc..04763e5 100644
+--- a/test/dumps/sming/RMON2-MIB
++++ b/test/dumps/sming/RMON2-MIB
+@@ -1,23 +1,26 @@
+ //
+-// This module has been generated by smidump 0.4.5. Do not edit.
++// This module has been generated by smidump 0.4.8. Do not edit.
+ //
+ module RMON2-MIB {
+
+- import IF-MIB (ifIndex);
+- import IRTF-NMRG-SMING (Counter32, DisplayString255,
+- Gauge32, IpAddress, TimeStamp,
+- TimeTicks);
+- import IRTF-NMRG-SMING-SNMP (RowStatus, mib-2);
+- import RMON-MIB (OwnerString, channelEntry,
+- etherStatsEntry, filter,
+- filterEntry, history,
+- historyControlEntry,
+- hostControlEntry, hosts, matrix,
+- matrixControlEntry, statistics);
+- import TOKEN-RING-RMON-MIB (ringStationControlEntry,
+- sourceRoutingStatsEntry,
+- tokenRing, tokenRingMLStatsEntry,
+- tokenRingPStatsEntry);
++ import SNMPv2-SMI (MODULE-IDENTITY, OBJECT-TYPE,
++ Counter32, Integer32, Gauge32,
++ IpAddress, TimeTicks, mib-2);
++ import SNMPv2-TC (TEXTUAL-CONVENTION, RowStatus,
++ DisplayString, TimeStamp);
++ import SNMPv2-CONF (MODULE-COMPLIANCE, OBJECT-GROUP);
++ import IF-MIB (ifIndex);
++ import RMON-MIB (OwnerString, statistics, history,
++ hosts, matrix, filter,
++ etherStatsEntry,
++ historyControlEntry,
++ hostControlEntry,
++ matrixControlEntry, filterEntry,
++ channelEntry);
++ import TOKEN-RING-RMON-MIB (tokenRing, tokenRingMLStatsEntry,
++ tokenRingPStatsEntry,
++ ringStationControlEntry,
++ sourceRoutingStatsEntry);
+
+ //
+ // MODULE META INFORMATION
+@@ -167,6 +170,7 @@ module RMON2-MIB {
+
+ typedef ZeroBasedCounter32 {
+ type Gauge32;
++ status current;
+ description
+ "This TC describes an object that counts events with the
+ following semantics: objects of this type will be set to
+@@ -188,6 +192,7 @@ module RMON2-MIB {
+
+ typedef LastCreateTime {
+ type TimeTicks;
++ status current;
+ description
+ "This TC describes an object that stores the value of the
+ sysUpTime object at the last time its entry was created.
+@@ -208,6 +213,7 @@ module RMON2-MIB {
+
+ typedef TimeFilter {
+ type TimeTicks;
++ status current;
+ description
+ "To be used for the index to a table. Allows an application
+ to download only those rows changed since a particular time.
+@@ -424,6 +430,7 @@ module RMON2-MIB {
+
+ typedef DataSource {
+ type ObjectIdentifier;
++ status current;
+ description
+ "Identifies the source of the data that the associated
+ function is configured to analyze. This source can be any
+@@ -439,6 +446,7 @@ module RMON2-MIB {
+
+ typedef ControlString {
+ type OctetString (0..255);
++ status current;
+ description
+ "This data type is used to communicate with a modem or a
+
+diff --git a/test/dumps/sming/SNMPv2-MIB b/test/dumps/sming/SNMPv2-MIB
+index ca355c8..0c88939 100644
+--- a/test/dumps/sming/SNMPv2-MIB
++++ b/test/dumps/sming/SNMPv2-MIB
+@@ -1,11 +1,14 @@
+ //
+-// This module has been generated by smidump 0.4.5. Do not edit.
++// This module has been generated by smidump 0.4.8. Do not edit.
+ //
+ module SNMPv2-MIB {
+
+- import IRTF-NMRG-SMING (Counter32, DisplayString255,
+- TimeStamp, TimeTicks, snmpModules);
+- import IRTF-NMRG-SMING-SNMP (TestAndIncr, mib-2);
++ import SNMPv2-SMI (MODULE-IDENTITY, OBJECT-TYPE,
++ NOTIFICATION-TYPE, TimeTicks, Counter32,
++ snmpModules, mib-2);
++ import SNMPv2-TC (DisplayString, TestAndIncr, TimeStamp);
++ import SNMPv2-CONF (MODULE-COMPLIANCE, OBJECT-GROUP,
++ NOTIFICATION-GROUP);
+
+ //
+ // MODULE META INFORMATION
+--
+1.9.1
+
diff --git a/meta-openembedded/meta-oe/recipes-support/libsmi/libsmi/smi.conf b/meta-openembedded/meta-oe/recipes-support/libsmi/libsmi/smi.conf
new file mode 100644
index 000000000..7e4da86d9
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/libsmi/libsmi/smi.conf
@@ -0,0 +1,48 @@
+#
+# smi.conf - Global/User SMI configuration file. (EXAMPLE)
+#
+# Copyright (c) 2000 Frank Strauss, Technical University of Braunschweig.
+#
+# See the file "COPYING" for information on usage and redistribution
+# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+#
+# @(#) $Id: smi.conf-example 1134 2001-06-11 09:59:13Z strauss $
+#
+#
+# See smi_config(3) for detailed information on configuration files.
+#
+
+# Extend (note the semicolon) the libsmi default module search path.
+path :/usr/share/mibs/iana
+path :/usr/share/mibs/ietf
+path :/usr/share/mibs/irtf
+path :/usr/share/mibs/tubs
+
+# EXPERIMENTAL: Add a caching method (works only on UNIX systems).
+# NOTE: the cache directory must exist and permissions must be
+# handled appropriately. A simple but insecure way is to apply
+# a tmp flag to the directory (chmod 1777 /usr/local/share/mibs/cache).
+#cache /usr/local/share/mibs/cache /usr/local/bin/smicache -d /usr/local/share/mibs/cache -p http://www.ibr.cs.tu-bs.de/projects/libsmi/smicache/
+
+# Don't show any errors by default.
+level 0
+
+# Preload some basic SMIv2 modules.
+load SNMPv2-SMI
+load SNMPv2-TC
+load SNMPv2-CONF
+
+# Make smilint shout loud to report all errors and warnings.
+smilint: level 9
+
+# But please don't claim about any names longer than 32 chars.
+# (note: this is the prefix of errors `namelength-32-module,
+# -type, -object, -enumeration, and -bit)
+smilint: hide namelength-32
+
+# Preloading some more modules for special applications.
+tcpdump: load DISMAN-SCRIPT-MIB
+tcpdump: load IF-MIB
+
+smiquery: load IF-MIB
+
diff --git a/meta-openembedded/meta-oe/recipes-support/libsmi/libsmi_0.5.0.bb b/meta-openembedded/meta-oe/recipes-support/libsmi/libsmi_0.5.0.bb
new file mode 100644
index 000000000..b537ce67d
--- /dev/null
+++ b/meta-openembedded/meta-oe/recipes-support/libsmi/libsmi_0.5.0.bb
@@ -0,0 +1,32 @@
+SUMMARY = "A Library to Access SMI MIB Information"
+HOMEPAGE = "https://www.ibr.cs.tu-bs.de/projects/libsmi"
+
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://COPYING;md5=3ad3076f9332343a21636cfd351f05b7"
+
+SRC_URI = "https://www.ibr.cs.tu-bs.de/projects/${BPN}/download/${BP}.tar.gz \
+ file://smi.conf \
+ file://libsmi-fix-the-test-dump-files.patch \
+ "
+
+SRC_URI[md5sum] = "4bf47483c06c9f07d1b10fbc74eddf11"
+SRC_URI[sha256sum] = "f21accdadb1bb328ea3f8a13fc34d715baac6e2db66065898346322c725754d3"
+
+RDEPENDS_${PN} += "wget"
+
+inherit autotools
+
+EXTRA_OECONF = "ac_cv_path_SH=${base_bindir}/sh ac_cv_path_WGET=${bindir}/wget"
+
+do_install_append () {
+ install -d ${D}${sysconfdir}
+ install -m 0644 ${WORKDIR}/smi.conf ${D}${sysconfdir}/smi.conf
+}
+
+PACKAGES += "${PN}-mibs ${PN}-pibs ${PN}-yang"
+
+FILES_${PN}-mibs += "${datadir}/mibs"
+FILES_${PN}-pibs += "${datadir}/pibs"
+FILES_${PN}-yang += "${datadir}/yang"
+
+RRECOMMENDS_${PN} = "${BPN}-mibs"
OpenPOWER on IntegriCloud