diff --git a/build.py b/build.py index 6b1c841f9..986473322 100755 --- a/build.py +++ b/build.py @@ -551,6 +551,10 @@ def build_packages(build_output, version, nightly=False, rc=None, iteration=1): package_build_root = build_root current_location = build_output[platform][arch] + if rc is not None: + # Set iteration to 0 since it's a release candidate + package_iteration = "0.rc{}".format(rc) + if package_type in ['zip', 'tar']: # For tars and zips, start the packaging one folder above # the build root (to include the package name) @@ -572,10 +576,6 @@ def build_packages(build_output, version, nightly=False, rc=None, iteration=1): elif package_type == 'zip': current_location = os.path.join(current_location, name + '.zip') - if rc is not None: - # Set iteration to 0 since it's a release candidate - package_iteration = "0.rc{}".format(rc) - fpm_command = "fpm {} --name {} -a {} -t {} --version {} --iteration {} -C {} -p {} ".format( fpm_common_args, name,