Buildbot: Attempt to make windows cmake builds names matching buldbot's names

Did this in packaging buildbot rule because of several reasons:

- CMake doesn't deliver name of package which we expect it to be for buildbot
- CMake doesn't really know that building happens for buildbot
- Making default CPAck name matching buildbot's naming is kinda stupid

Probably we can pass CPack name via command line arguments, but i'm happy with
the current state and one might change things in the future.
This commit is contained in:
Sergey Sharybin 2015-07-27 11:17:57 +02:00
parent 20ec508ca3
commit e5d7cbd191

@ -123,7 +123,17 @@ else:
os.remove(f)
retcode = subprocess.call(['cpack', '-G', 'ZIP'])
result_file = [f for f in os.listdir('.') if os.path.isfile(f) and f.endswith('.zip')][0]
os.rename(result_file, "{}.zip".format(builder))
# TODO(sergey): Such magic usually happens in SCon's packaging bu we don't have it
# in the CMake yet. For until then we do some magic here.
tokens = result_file.split('-')
blender_version = tokens[1].split('.')
blender_full_version = '.'.join(blender_version[0:2])
git_hash = tokens[2].split('.')[1]
platform = builder.split('_')[0]
builderified_name = 'blender-{}-{}-{}'.format(blender_full_version, git_hash, platform)
os.rename(result_file, "{}.zip".format(builderified_name))
# create zip file
try:
upload_zip = "buildbot_upload.zip"