DWM Error when installing slstatus on FreeBSD 13.1

Hello everyone,

Hope you are well, I'm stuck with this output from slstatus install :

Code:
ld: error: undefined symbol: kvm_openfiles
>>> referenced by swap.c
>>>               components/swap.o:(swap_free)
>>> referenced by swap.c
>>>               components/swap.o:(swap_perc)
>>> referenced by swap.c
>>>               components/swap.o:(swap_total)
>>> referenced 1 more times

ld: error: undefined symbol: kvm_getswapinfo
>>> referenced by swap.c
>>>               components/swap.o:(swap_free)
>>> referenced by swap.c
>>>               components/swap.o:(swap_perc)
>>> referenced by swap.c
>>>               components/swap.o:(swap_total)
>>> referenced 1 more times

ld: error: undefined symbol: kvm_close
>>> referenced by swap.c
>>>               components/swap.o:(swap_free)
>>> referenced by swap.c
>>>               components/swap.o:(swap_free)
>>> referenced by swap.c
>>>               components/swap.o:(swap_perc)
>>> referenced 5 more times

ld: error: undefined symbol: cpu_print
>>> referenced by slstatus.c
>>>               slstatus.o:(args)

ld: error: undefined symbol: ram_print
>>> referenced by slstatus.c
>>>               slstatus.o:(args)

ld: error: undefined symbol: wifi_print_preatty
>>> referenced by slstatus.c
>>>               slstatus.o:(args)

ld: error: undefined symbol: battery_icon
>>> referenced by slstatus.c
>>>               slstatus.o:(args)
cc: error: linker command failed with exit code 1 (use -v to see invocation)
*** Error code 1

Does anyone have an idea about the error ? I've check .h files included into my install directory but I've haven't figured yet what is the problem (obviously...).

Thanks to everyone.
 
I did not see 13.1 is EOL. Consider upgrading to the latest release.
https://forums.freebsd.org/threads/topics-about-unsupported-freebsd-versions.40469

I've made update using freebsd-update soft, then I've re run make clean install for my slstatus bar, same output:

Code:
ld: error: undefined symbol: kvm_openfiles
>>> referenced by swap.c
>>>               components/swap.o:(getswapinfo)

ld: error: undefined symbol: kvm_getswapinfo
>>> referenced by swap.c
>>>               components/swap.o:(getswapinfo)

ld: error: undefined symbol: kvm_close
>>> referenced by swap.c
>>>               components/swap.o:(getswapinfo)
>>> referenced by swap.c
>>>               components/swap.o:(getswapinfo)
cc: error: linker command failed with exit code 1 (use -v to see invocation)
*** Error code 1

Stop.
 
You should edit config.mk and adjust as follows. Also, there is a note for FreeBSD. I'm having same errors unless I apply the adjustment for FreeBSD too.
Code:
# OpenBSD: add -lsndio
# FreeBSD: add -lkvm -lsndio
LDLIBS   = -lX11 >>>>> LDLIBS   = -lX11 -lkvm -lsndio
 
Back
Top