Use pkg-config where possible.