From b65f29c904ed95c772dbc6b68cb77d23fb47620e Mon Sep 17 00:00:00 2001 From: Brian Candler Date: Tue, 2 May 2023 09:21:52 +0100 Subject: [PATCH] Patch MIBs to import DisplayString from SNMPv2-TC instead of RFC1213-MIB (#868) Fixes #867 Signed-off-by: Brian Candler --- generator/Makefile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/generator/Makefile b/generator/Makefile index 579610d5..c5b57157 100644 --- a/generator/Makefile +++ b/generator/Makefile @@ -129,6 +129,9 @@ mibs: \ $(MIBDIR)/apc-powernet-mib: @echo ">> Downloading apc-powernet-mib" @curl $(CURL_OPTS) -o $(MIBDIR)/apc-powernet-mib "$(APC_URL)" + # Workaround to make DisplayString available (#867) + @sed -i.bak -E 's/(DisplayString[[:space:]]*FROM )RFC1213-MIB/\1SNMPv2-TC/' $(MIBDIR)/apc-powernet-mib + @rm $(MIBDIR)/apc-powernet-mib.bak $(MIBDIR)/ARISTA-ENTITY-SENSOR-MIB: @echo ">> Downloading ARISTA-ENTITY-SENSOR-MIB" @@ -313,4 +316,7 @@ $(MIBDIR)/CyberPower.MIB: @curl $(CURL_OPTS) -o $(TMP) $(CYBERPOWER_URL) @unzip -j -d $(MIBDIR) $(TMP) CyberPower_MIB_v$(CYBERPOWER_VERSION).MIB @mv -v $(MIBDIR)/CyberPower_MIB_v$(CYBERPOWER_VERSION).MIB $@ + # Workaround to make DisplayString available (#867) + @sed -i.bak -E 's/(DisplayString[[:space:]]*FROM )RFC1213-MIB/\1SNMPv2-TC/' $@ + @rm $@.bak @rm -v $(TMP)