Skip to content
Snippets Groups Projects
Commit 0abdab78 authored by JJ Linden's avatar JJ Linden
Browse files

changed variable names and errors to more accurately reflect the operation being performed

parent 251bf8ce
No related branches found
No related tags found
No related merge requests found
...@@ -622,21 +622,21 @@ def package_finish(self): ...@@ -622,21 +622,21 @@ def package_finish(self):
NSIS_path = os.path.expandvars('${ProgramFiles}\\NSIS\\Unicode\\makensis.exe') NSIS_path = os.path.expandvars('${ProgramFiles}\\NSIS\\Unicode\\makensis.exe')
if not os.path.exists(NSIS_path): if not os.path.exists(NSIS_path):
NSIS_path = os.path.expandvars('${ProgramFiles(x86)}\\NSIS\\Unicode\\makensis.exe') NSIS_path = os.path.expandvars('${ProgramFiles(x86)}\\NSIS\\Unicode\\makensis.exe')
signed=False installer_created=False
sign_attempts=3 nsis_attempts=3
sign_retry_wait=15 nsis_retry_wait=15
while (not signed) and (sign_attempts > 0): while (not installer_created) and (nsis_attempts > 0):
try: try:
sign_attempts-=1; nsis_attempts-=1;
self.run_command('"' + proper_windows_path(NSIS_path) + '" ' + self.dst_path_of(tempfile)) self.run_command('"' + proper_windows_path(NSIS_path) + '" ' + self.dst_path_of(tempfile))
signed=True # if no exception was raised, the codesign worked installer_created=True # if no exception was raised, the codesign worked
except ManifestError, err: except ManifestError, err:
if sign_attempts: if nsis_attempts:
print >> sys.stderr, "codesign failed, waiting %d seconds before retrying" % sign_retry_wait print >> sys.stderr, "nsis failed, waiting %d seconds before retrying" % nsis_retry_wait
time.sleep(sign_retry_wait) time.sleep(nsis_retry_wait)
sign_retry_wait*=2 nsis_retry_wait*=2
else: else:
print >> sys.stderr, "Maximum codesign attempts exceeded; giving up" print >> sys.stderr, "Maximum nsis attempts exceeded; giving up"
raise raise
# self.remove(self.dst_path_of(tempfile)) # self.remove(self.dst_path_of(tempfile))
# If we're on a build machine, sign the code using our Authenticode certificate. JC # If we're on a build machine, sign the code using our Authenticode certificate. JC
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment