net-snmp: import Debian patch to fix link error

This commit is contained in:
K900
2026-07-29 14:43:35 +03:00
parent ef164c0242
commit 85a7c42730
2 changed files with 22 additions and 0 deletions

View File

@@ -0,0 +1,17 @@
Description: Add libnetsnmpaget link to libnetsnmptrapd
Causes a linking issue otherwise
Author: Craig Small <csmall@debian.org>
Reviewed-by: Craig Small <csmall@debian.org>
Last-Update: 2023-08-19
---
--- a/apps/Makefile.in
+++ b/apps/Makefile.in
@@ -237,7 +237,7 @@
$(LINK) ${CFLAGS} -o $@ snmppcap.$(OSUFFIX) ${LDFLAGS} ${USEAGENTLIBS} ${LIBS} -lpcap
libnetsnmptrapd.$(LIB_EXTENSION)$(LIB_VERSION): $(LLIBTRAPD_OBJS)
- $(LIB_LD_CMD) $@ ${LLIBTRAPD_OBJS} $(MIBLIB) $(MYSQL_LIBS) $(USELIBS) $(PERLLDOPTS_FOR_LIBS) $(LDFLAGS)
+ $(LIB_LD_CMD) $@ ${LLIBTRAPD_OBJS} $(MIBLIB) $(MYSQL_LIBS) $(USELIBS) $(USEAGENTLIBS) $(PERLLDOPTS_FOR_LIBS) $(LDFLAGS)
$(RANLIB) $@
snmpinforminstall:

View File

@@ -29,6 +29,11 @@ stdenv.mkDerivation (finalAttrs: {
hash = "sha256-FnB3GfgzGEpLcoNdrDWa4YgSOwa15CgXwAeQ19wThL8=";
};
patches = [
# https://salsa.debian.org/debian/net-snmp/-/blob/master/debian/patches/makefile_trap_needs_agent, vendored because of Anubis
./link-error.patch
];
outputs = [
"bin"
"out"