Use target python for obtaining link flags.