refactor lib test related link checks using ...

\%options.
re-order check_lib / check_lm

while check_lib is a very historic check, modern search_libs is the base
check_lm operates on. Re-order the functions to logically place check_lm
after search_libs to allow top-down readers remain in continuous flow :)