Bug 225595 - net-mgmt/lldpd: Update to 0.9.9
Summary: net-mgmt/lldpd: Update to 0.9.9
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Danilo G. Baio
Depends on:
Reported: 2018-01-31 20:56 UTC by Denny Page
Modified: 2018-02-22 17:16 UTC (History)
3 users (show)

See Also:
freebsd: maintainer-feedback+

lldpd-0.9.9.patch (5.97 KB, patch)
2018-02-12 16:15 UTC, Danilo G. Baio
no flags Details | Diff
lldpd-0.9.9-v02.patch (6.20 KB, patch)
2018-02-12 16:29 UTC, Danilo G. Baio
no flags Details | Diff
lldpd-0.9.9-v03.patch (6.26 KB, patch)
2018-02-21 17:40 UTC, Danilo G. Baio
dbaio: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Denny Page 2018-01-31 20:56:51 UTC

Would it be possible to update the lldpd version from 0.9.4 to 0.9.9?

Comment 1 Denny Page 2018-02-06 17:18:18 UTC
As far as I can tell, a patch is not needed. The 0.9.9 distribution appears to build just fine without patching. The patches that are in FreeBSD Ports related to 0.9.4 have been incorporated upstream and can be removed from Ports with the upgrade to 0.9.9.
Comment 2 Mathieu Simon 2018-02-11 21:41:46 UTC
Hi Denny

I've had issues with the default (and to me quite meaningful) defaults with releases >= 0.9.5. Everything works, but as soon as you try building the port with all default options enabled, and that is SNMP to, it breaks the build.

I currently lack a FreeBSD poudriere environment since I'm swapping out some of my VM hosting hardware at home.

Could you try building 0.9.9 within poudriere (poudriere testport that is) and tell me how it goes? I could reliably reproduce this issue with 11.x and 10.x environments, not difference there.

And sorry for the lag in replying.

Comment 3 Mathieu Simon 2018-02-11 21:43:05 UTC
And concerning the patches you mentioned, yes they shouldn't be needed anymore, I remember I cross-checked when I attempted to get 0.9.6 and 0.9.7 included in the ports tree (but failed investigating the SNMP issues back then)

-- Mathieu
Comment 4 Danilo G. Baio freebsd_committer 2018-02-12 16:15:48 UTC
Created attachment 190546 [details]

Build tests are fine:
10.3-RELEASE-p26     amd64|i386
11.1-RELEASE-p6      amd64|i386
12.0-CURRENT 1200057 amd64|i386

It's needed a runtime test.
Comment 5 Danilo G. Baio freebsd_committer 2018-02-12 16:16:37 UTC
`needs-patch` flag says that here in bugzilla is necessary a patch
Comment 6 Danilo G. Baio freebsd_committer 2018-02-12 16:29:30 UTC
Created attachment 190547 [details]

Fixing pkg-plist
Comment 7 Mathieu Simon 2018-02-20 06:17:23 UTC
Hi Danilo

Thank you very much for your patch, I was able to get my poudriere VM back up and running. poudriere testport works fine in 11.1 and 10.4 jails both amd64 and i386.

I've done a quick runtime check against a recent lldpd version on a Linux distribution and an HPE ArubaOS switch. Looks fine to me since sending LLDP packets produce readable and valid output on the receivers and decoding them works too..

Concerning your changes:
* USE_CSTD= gnu99 -> That one seems to be doing the required "magic". As soon as this one is disabled, the port breaks. Oh my, I didn't think about forcing GNU C99 style back when I was attempting to get 0.9.6/.7 working.
* USES= (+)ssl - where did you see the requirement for that one becoming required?
* LIB_DEPENDS= (+)libpkg.so:ports-mgmt/pkg, this one seems (still) to be leaking in from Net-SNMP and shouldn't be required as Baptiste explained in bug #210390,comment#9

-- Mathieu
Comment 8 Danilo G. Baio freebsd_committer 2018-02-21 17:40:52 UTC
Created attachment 190863 [details]

Hummm, thanks for pointing bug 210390.

====> Running Q/A tests (stage-qa)
Warning: you need USES=ssl
Error: /usr/local/sbin/lldpd is linked to /usr/local/lib/libpkg.so.4 from ports-mgmt/pkg but it is not declared as a dependency
Warning: you need LIB_DEPENDS+=libpkg.so:ports-mgmt/pkg
====> Checking for pkg-plist issues (check-plist)
===> Parsing plist
===> Checking for items in STAGEDIR missing from pkg-plist
===> Checking for items in pkg-plist which are not in STAGEDIR
===> No pkg-plist issues found (check-plist)
=>> Checking for staging violations... done

$ readelf -d work/stage/usr/local/sbin/lldpd

Dynamic section at offset 0x3e668 contains 38 entries:
  Tag                Type                  Name/Value
 0x0000000000000001 NEEDED               Shared library: [libevent-2.1.so.6]
 0x0000000000000001 NEEDED               Shared library: [libm.so.5]
 0x0000000000000001 NEEDED               Shared library: [libkvm.so.7]
 0x0000000000000001 NEEDED               Shared library: [libdevstat.so.7]
 0x0000000000000001 NEEDED               Shared library: [libnetsnmpmibs.so.30]
 0x0000000000000001 NEEDED               Shared library: [libnetsnmpagent.so.30]
 0x0000000000000001 NEEDED               Shared library: [libnetsnmp.so.30]
 0x0000000000000001 NEEDED               Shared library: [libcrypto.so.8]
 0x0000000000000001 NEEDED               Shared library: [libelf.so.2]
 0x0000000000000001 NEEDED               Shared library: [libpkg.so.4]
 0x0000000000000001 NEEDED               Shared library: [libregex.so.1]
 0x0000000000000001 NEEDED               Shared library: [libthr.so.3]
 0x0000000000000001 NEEDED               Shared library: [librt.so.1]
 0x0000000000000001 NEEDED               Shared library: [libc.so.7]
 0x000000000000000f RPATH                Library rpath: [/usr/local/lib/perl5/5.24/mach/CORE]
 0x000000000000001d RUNPATH              Library runpath: [/usr/local/lib/perl5/5.24/mach/CORE]
 0x000000000000000c INIT                 0x406790
 0x000000000000000d FINI                 0x42cfa8
 0x0000000000000004 HASH                 0x4002b8
 0x000000006ffffef5 GNU_HASH             0x400cd8
 0x0000000000000005 STRTAB               0x403800
 0x0000000000000006 SYMTAB               0x401418
 0x000000000000000a STRSZ                6283 (bytes)
 0x000000000000000b SYMENT               24 (bytes)
 0x0000000000000015 DEBUG                0x0
 0x0000000000000003 PLTGOT               0x63e918
 0x0000000000000002 PLTRELSZ             4248 (bytes)
 0x0000000000000014 PLTREL               RELA
 0x0000000000000017 JMPREL               0x4056f8
 0x0000000000000007 RELA                 0x4053e0
 0x0000000000000008 RELASZ               792 (bytes)
 0x0000000000000009 RELAENT              24 (bytes)
 0x000000000000001e FLAGS
 0x000000006ffffffb FLAGS_1
 0x000000006ffffffe VERNEED              0x405390
 0x000000006fffffff VERNEEDNUM           2
 0x000000006ffffff0 VERSYM               0x40508c
 0x0000000000000000 NULL                 0x0

Seems that ssl is needed because of snmp.

Updating patch accordingly.

The second mirror is now updated, I've inserted it again.
Comment 9 Mathieu Simon 2018-02-21 20:47:48 UTC

Thank you Danilo for your patch and for the cross-interation with Vincent at upstream. (https://github.com/vincentbernat/lldpd/issues/231)

The patch is definitely fine to go into the ports tree, no nitpicking from my side. :-)

Denny: As soon as Danilo or any another FreeBSD ports committer goes ahead and imports this patch, you can expect to see lldpd 0.9.9 as binary package within likely 1 week when the build machines  produce new packages.

-- Mathieu
Comment 10 Denny Page 2018-02-21 20:49:09 UTC
Thank you!
Comment 11 commit-hook freebsd_committer 2018-02-21 21:42:08 UTC
A commit references this bug:

Author: dbaio
Date: Wed Feb 21 21:42:03 UTC 2018
New revision: 462545
URL: https://svnweb.freebsd.org/changeset/ports/462545

  net-mgmt/lldpd: Update to 0.9.9

  Patches removed were incorporated upstream.

  Changes:	https://github.com/vincentbernat/lldpd/blob/0.9.9/NEWS

  PR:		225595
  Reported by:	Denny Page <dennypage@me.com>
  Approved by:	Mathieu Simon <freebsd@simweb.ch> (maintainer)

Comment 12 Danilo G. Baio freebsd_committer 2018-02-21 21:43:30 UTC
Comment on attachment 190863 [details]

Committed, thanks!
Comment 13 commit-hook freebsd_committer 2018-02-22 17:16:29 UTC
A commit references this bug:

Author: dbaio
Date: Thu Feb 22 17:15:30 UTC 2018
New revision: 51438
URL: https://svnweb.freebsd.org/changeset/doc/51438

  Add Mathieu Simon to contributors

  Maintainer of net-mgmt/lldpd

  PR:		225595