Correct build dir variable substitution.