Bug 13761 - Problems met during net-snmp pkg build
Summary: Problems met during net-snmp pkg build
Status: RESOLVED FIXED
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: 3
Hardware: i586 Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Mageia Bug Squad
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-07-18 11:14 CEST by Gilles Allard
Modified: 2014-07-18 18:21 CEST (History)
0 users

See Also:
Source RPM: net-snmp-5.7.2-7.mga3.src.rpm
CVE:
Status comment:


Attachments
Proposal for a patch to spec file from net-snmp-5.7.2-7.mga3.src.rpm (544 bytes, patch)
2014-07-18 11:16 CEST, Gilles Allard
Details | Diff
Patch to fix failure during snmpd linking (474 bytes, patch)
2014-07-18 11:17 CEST, Gilles Allard
Details | Diff

Description Gilles Allard 2014-07-18 11:14:42 CEST
Description of problem:
1) A minor bug in spec file : at the end of "%prep" step a perl cmd. is used to patch some files under sub-dir. "testing", changing "/tmp/snmp-test" into "$RPM_BUILD_DIR/%{name}-%{version}/test_tmp_dir/snmp-test".
2 files are involved in that patch : "testing/Majefile.in" and "testing/fulltest/suport/simple_TESTCONF.sh". They are invloved in tests.
Because the argument of the perl cmd. is "testing/*" perl refuses to patch the sub-dirs under "testing" and print the following error msgs.

Can't do inplace edit: testing/fulltests is not a regular file.
Can't do inplace edit: testing/rfc1213 is not a regular file, <> line 136.

The consequence is that only "Makefile.in" is patched; "simple_TESTCONF.sh" is ignored. But the build process doesn't fail at all !

The attached file "net-snmp-spec.patch" is a proposal to fix that problem

2) Linking of "snmpd" daemon fails if systemd support is disabled by changing the "--with-systemd" argument of "configure" into "--with-systemd=no". The linking of snmpd binary ends with the following error msg :

/tmp/RPM/BUILD/net-snmp-5.7.2/agent/snmpd.c:457: undefined reference to `netsnmp_sd_listen_fds'
collect2: ld returned 1 exit status

This is due to a bug (obviously a typo) in "agent/snmpd.c" source file
The attached file "net-snmp-5.7.2-no-systemd-bug.patch" fixes this problem

Version-Release number of selected component (if applicable):
net-snmp-5.7.2-7.mga3

How reproducible:
Bug #2 : Easily reproductible

Steps to Reproduce:
1.Change "--with-systemd" configure arg into "--with-systemd=no"
2.Start a "rpmbuild -bc ...." process without applying the proposed patch
  Result is a failure when linking snmpd
3.


Reproducible: 

Steps to Reproduce:
Comment 1 Gilles Allard 2014-07-18 11:16:16 CEST
Created attachment 5297 [details]
Proposal for a patch to spec file from net-snmp-5.7.2-7.mga3.src.rpm
Comment 2 Gilles Allard 2014-07-18 11:17:28 CEST
Created attachment 5298 [details]
Patch to fix failure during snmpd linking
Comment 3 David Walser 2014-07-18 18:21:18 CEST
Changes added in Cauldron in net-snmp-5.7.2-18.mga5.

Changes checked into SVN for Mageia 3 and Mageia 4.

Thanks for the report!

Status: NEW => RESOLVED
Resolution: (none) => FIXED


Note You need to log in before you can comment on or make changes to this bug.