Bug 1545946

Summary: bad patch in net-snmp src rpm
Product: [Fedora] Fedora Reporter: Robert Story <rs>
Component: net-snmpAssignee: Josef Ridky <jridky>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 26CC: jridky, jsafrane, thozza
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: net-snmp-5.7.3-26.fc27 net-snmp-5.7.3-26.fc26 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-02-20 17:16:46 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Robert Story 2018-02-15 22:41:48 UTC
Description of problem:
net-snmp src rpm contains a bad patch that breaks building the rpm on systems without systemd.

Version-Release number of selected component (if applicable):
net-snmp-5.7.3-25.1.fc27.src.rpm (and likely older versions as well)

How reproducible:
always

Steps to Reproduce:
1. try to build srpm on RHEL/CentOS 6
2.
3.

Actual results:
.libs/snmpd.o: In function `main':
/builddir/build/BUILD/net-snmp-5.7.3/agent/snmpd.c:459: undefined reference to `netsnmp_sd_listen_fds'

Expected results:
no errors

Additional info:
Fix is pretty easy:

--- ../sources/net-snmp-5.7.2-systemd.patch.orig        2018-02-15 17:20:49.271208819 -0500
+++ ../sources/net-snmp-5.7.2-systemd.patch     2018-02-15 17:21:09.691126055 -0500
@@ -82,10 +82,10 @@
  #endif

  #ifndef WIN32
-+#ifndef NETSNMP_NO_SYSYSTEMD
++#ifndef NETSNMP_NO_SYSTEMD
 +    /* check if systemd has sockets for us and don't close them */
 +    prepared_sockets = netsnmp_sd_listen_fds(0);
-+#endif /* NETSNMP_NO_SYSYSTEMD */
++#endif /* NETSNMP_NO_SYSTEMD */
 +
      /*
       * close all non-standard file descriptors we may have

Comment 1 Fedora Update System 2018-02-16 07:55:45 UTC
net-snmp-5.7.3-26.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2018-b2d1237a54

Comment 2 Fedora Update System 2018-02-16 07:55:54 UTC
net-snmp-5.7.3-26.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2018-5a2e230b9d

Comment 3 Josef Ridky 2018-02-16 07:57:22 UTC
Hi Robert, 

thanks for your report. Net-SNMP from Fedora 26 and above has been fixed.

Comment 4 Fedora Update System 2018-02-16 15:58:45 UTC
net-snmp-5.7.3-26.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-5a2e230b9d

Comment 5 Fedora Update System 2018-02-16 16:28:36 UTC
net-snmp-5.7.3-26.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-b2d1237a54

Comment 6 Fedora Update System 2018-02-20 17:16:46 UTC
net-snmp-5.7.3-26.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.

Comment 7 Fedora Update System 2018-03-13 17:15:09 UTC
net-snmp-5.7.3-26.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.