faster replacement for *BSD's "mkdep" 