Fix missing python3 command on Windows

This commit is contained in:
2019-09-03 14:09:36 +02:00
parent f62826f92c
commit 6249edce8d

View File

@@ -277,9 +277,9 @@ def lib_svn_step(dir):
workdir='lib/' + dir) workdir='lib/' + dir)
def rsync_step(id, branch, rsync_script): def rsync_step(python_command, id, branch, rsync_script):
return ShellCommand(name='rsync', return ShellCommand(name='rsync',
command=['python3', rsync_script, id, branch], command=[python_command, rsync_script, id, branch],
description='uploading', description='uploading',
descriptionDone='uploaded', descriptionDone='uploaded',
workdir='install') workdir='install')
@@ -299,6 +299,11 @@ def generic_builder(id, libdir='', branch='', rsync=False):
if libdir != '': if libdir != '':
f.addStep(lib_svn_step(libdir)) f.addStep(lib_svn_step(libdir))
if id.startswith('win'):
python_command = 'python'
else:
python_command = 'python3'
f.addStep(lib_svn_step('tests')) f.addStep(lib_svn_step('tests'))
for submodule in ('blender-translations', for submodule in ('blender-translations',
@@ -310,18 +315,18 @@ def generic_builder(id, libdir='', branch='', rsync=False):
f.addStep(git_step(branch)) f.addStep(git_step(branch))
f.addStep(git_submodules_update()) f.addStep(git_submodules_update())
f.addStep(Compile(command=['python3', compile_script, id], timeout=3600)) f.addStep(Compile(command=[python_command, compile_script, id], timeout=3600))
f.addStep(Test(command=['python3', test_script, id])) f.addStep(Test(command=[python_command, test_script, id]))
f.addStep(ShellCommand( f.addStep(ShellCommand(
name='package', name='package',
command=['python3', command=[python_command,
pack_script, pack_script,
id, id,
branch or Interpolate('%(src:blender:branch)s')], branch or Interpolate('%(src:blender:branch)s')],
description='packaging', description='packaging',
descriptionDone='packaged')) descriptionDone='packaged'))
if rsync: if rsync:
f.addStep(rsync_step(id, branch, rsync_script)) f.addStep(rsync_step(python_command, id, branch, rsync_script))
else: else:
f.addStep(FileUpload(name='upload', f.addStep(FileUpload(name='upload',
workersrc='buildbot_upload.zip', workersrc='buildbot_upload.zip',