Fix build scripts

This commit is contained in:
Ali 2021-01-15 01:59:56 +04:00
parent d7b6acd141
commit 2a3efb0472
2 changed files with 7 additions and 3 deletions

View File

@ -66,7 +66,7 @@ def get_bazel_version(bazel_path):
command_result = run_executable_with_output(bazel_path, ['--version']).strip('\n')
if not command_result.startswith('bazel '):
raise Exception('{} is not a valid bazel binary'.format(bazel_path))
command_result.replace('bazel ', '')
command_result = command_result.replace('bazel ', '')
return command_result
@ -132,7 +132,7 @@ class BuildEnvironment:
self.bazel_version, actual_bazel_version, self.bazel_path))
self.bazel_version = actual_bazel_version
else:
print('Required bazel version is {}, but {} is reported by {}'.format(
print('Required bazel version is "{}", but "{}"" is reported by {}'.format(
self.bazel_version, actual_bazel_version, self.bazel_path))
exit(1)

View File

@ -266,9 +266,13 @@ def resolve_configuration(bazel_command_line: BazelCommandLine, arguments):
def generate_project(arguments):
bazel_x86_64_path = None
if is_apple_silicon():
bazel_x86_64_path = arguments.bazel_x86_64
bazel_command_line = BazelCommandLine(
bazel_path=arguments.bazel,
bazel_x86_64_path=arguments.bazel_x86_64,
bazel_x86_64_path=bazel_x86_64_path,
override_bazel_version=arguments.overrideBazelVersion,
override_xcode_version=arguments.overrideXcodeVersion
)