lib.bash: fix libdepth logic
dist/configure: sh compat