Fix linking for tools, and add tools: target.