Lldpd missing dependencies for libraries: libbsd.so.0

Just tried to build from trunk from a git pull 12hrs ago and it halts during compile with message;
Package lldpd (Link Layer Discovery Protocol daemon) is missing dependencies for the following libraries:
libbsd.so.0

Anyone have any experience in facing this issue? Is it required?

Hello,

you have to select the dependent libraries for lldpd as well in your config-file. In your case libbsd is missing.

The Makefile is showing:

DEPENDS:=+libevent2 +USE_GLIBC:libbsd +LLDPD_WITH_JSON:libjson-c +LLDPD_WITH_SNMP:libnetsnmp

1 Like

Thanks for the tip. Those depends are found in my .config; some were =y and some =m. I've changed it to =y and am trying again now but I was under the impression =y was not necessary and that =m would suffice, is that not the case?

Edit: that didn't work for me
Edit2: just re-installed depends and still same error.

Is there something wrong with source atm?

Sure, "m" should be fine in most cases. Hmm ... I guess you did issue a "make download" after menuconfig? So libbsd-0.8.7.tar.xz is present in the download folder? (just asking).
If yes, then I guess the issue is somewhere else in the code and I cannot help. Then you have to provide more information from the log to people who have more knowledge.

2 Likes

Yes always make download. Will check for it in download folder.

Update: yes, in download folder;
lldpd-1.0.1.tar.gz
libbsd-0.8.7.tar.xz

Thanks for the help.

Ive built before with little issues to work through but got through it. Is it okay to use a config.seed from May?

Sure, you should be able to use any config.seed. If it's too old and things were removed or replaced from the source there could arise problems. But this probably will not solve your problem. You would need an older source tree too. Before the possible error you are facing got introduced.

But you should provide more detailed information first. Maybe there is someone able and willing to track down this for you. What are the lets say the last 20 lines of the log if you error comes up:

make package/network/services/lldpd/{clean,compile} V=s

P. S. On my system (latest git) lldpd is compiled without any issue. So I think it's not a general issue and more a dependency issue like the message you got already. Did you modify any file or applied a patch?

make package/network/services/lldpd/{clean,compile} V

install -d -m0755 /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd/etc/init.d
install -d -m0755 /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd/etc/lldpd.d
install -d -m0755 /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd/etc/config
install -d -m0755 /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd/usr/lib /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd/usr/sbin
cp -fpR /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-install/usr/sbin/lldp{cli,ctl,d} /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd/usr/sbin/
cp -fpR /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-install/usr/lib/liblldpctl.so* /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd/usr/lib/
install -m0755 ./files/lldpd.init /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd/etc/init.d/lldpd
install -m0600 ./files/lldpd.config /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd/etc/config/lldpd
sed -i -e '/agentxsocket/d' /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd/etc/init.d/lldpd /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd/etc/config/lldpd
find /home/user/OpenWRT/LEDE_22-09-18/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/lldpd-1.0.1/ipkg-arm_cortex-a9_vfpv3/lldpd -name 'CVS' -o -name '.svn' -o -name '.#*' -o -name '*~'| xargs -r rm -rf
Package lldpd is missing dependencies for the following libraries:
libbsd.so.0
Makefile:111: recipe for target '/home/user/OpenWRT/LEDE_22-09-18/bin/packages/arm_cortex-a9_vfpv3/base/lldpd_1.0.1-2_arm_cortex-a9_vfpv3.ipk' failed
make[2]: *** [/home/user/OpenWRT/LEDE_22-09-18/bin/packages/arm_cortex-a9_vfpv3/base/lldpd_1.0.1-2_arm_cortex-a9_vfpv3.ipk] Error 1
make[2]: Leaving directory '/home/user/OpenWRT/LEDE_22-09-18/package/network/services/lldpd'
time: package/network/services/lldpd/compile#37.47#7.23#47.36
package/Makefile:107: recipe for target 'package/network/services/lldpd/compile' failed
make[1]: *** [package/network/services/lldpd/compile] Error 2
make[1]: Leaving directory '/home/user/OpenWRT/LEDE_22-09-18'
/home/user/OpenWRT/LEDE_22-09-18/include/toplevel.mk:216: recipe for target 'package/network/services/lldpd/compile' failed
make: *** [package/network/services/lldpd/compile] Error 2

Edit; I do add a couple of additional repos as well to feeds; extra and stangri

So what is

cat package/network/services/lldpd/Makefile | grep DEPENDS

showing? It looks like just libbsd is missing in that line? oO

user@user-VirtualBox:~/OpenWRT/LEDE_22-09-18$ cat package/network/services/lldpd/Makefile | grep DEPENDS
DEPENDS:=+libevent2 +USE_GLIBC:libbsd +LLDPD_WITH_JSON:libjson-c +LLDPD_WITH_SNMP:libnetsnmp

At this point my "latin" ends. :smiley: I cannot help anymore.

1 Like

No worries, thanks anyways.

Going to try again from dirclean and keep it simple, use a new config.

Cheers:)

This is a bug with llpd's build system picking up libbsd, which honestly should be purged from OpenWrt. Deselect libbsd, remove it from build and staging dirs, and recompile lldpd. Ping @stintel

1 Like

Thank you for the advice:)

I would open a pull request to get rid of the dependency, but I bricked my laptop (bad firmware flash).

1 Like

Fixed with https://git.openwrt.org/?p=openwrt/openwrt.git;a=commitdiff;h=4f277eb6402684ca79c9834e8eb30c0e93368e8b

1 Like

Thats too bad... Bios update?

Thank you.

Of course. Will fix once I get an SPI programmer.

1 Like