Currently libkldelf's linker set will not appear when the library is
statically linked against kldxref. For now, fix this by compiling the
libkldelf source files directly in the kldxref target, instead of
depending on the libkldelf static library.
From jrtc27@, -Wl,--whole-archive is for such purpose, and without the
flag specified objects are otherwise extracted lazily from the static
library .a file. Another way would be to ld -r all the .o files into one
before producing the static library. Except such a fix is not employed
for now and will be implemented in the next diff to bring up a knob in
bsd.lib.mk to facilitate those processes.
Sponsored by: Juniper Networks, Inc.
Suggested by: markj