set PATH correctly when building target.