diff options
| author | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2010-08-09 17:44:03 +0000 |
|---|---|---|
| committer | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2010-08-09 17:44:03 +0000 |
| commit | 77b682571f80b0aec9a16182600678a1b553a4bb (patch) | |
| tree | 04f61abc534c7456f49a35fd4135701dfea3f2a0 /utils/common/deploy.py | |
| parent | cda31811c3798b18e66b744bf2c2a838e3ff9a44 (diff) | |
| download | rockbox-77b682571f80b0aec9a16182600678a1b553a4bb.zip rockbox-77b682571f80b0aec9a16182600678a1b553a4bb.tar.gz rockbox-77b682571f80b0aec9a16182600678a1b553a4bb.tar.bz2 rockbox-77b682571f80b0aec9a16182600678a1b553a4bb.tar.xz | |
deploy.py: Figure installer filename from NSIS script.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27764 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'utils/common/deploy.py')
| -rwxr-xr-x | utils/common/deploy.py | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/utils/common/deploy.py b/utils/common/deploy.py index ae3817f..662a104 100755 --- a/utils/common/deploy.py +++ b/utils/common/deploy.py @@ -70,7 +70,6 @@ progexe = "" make = "make" programfiles = [] nsisscript = "" -nsissetup = "" svnserver = "" # Paths and files to retrieve from svn when creating a tarball. @@ -257,7 +256,15 @@ def runnsis(versionstring, nsis, srcfolder): print "NSIS failed!" return -1 setupfile = program + "-" + versionstring + "-setup.exe" - shutil.copy(srcfolder + "/" + nsissetup, setupfile) + # find output filename in nsis script file + nsissetup = "" + for line in open(srcfolder + "/" + nsisscript): + if re.match(r'^[^;]*OutFile\s+', line) != None: + nsissetup = re.sub(r'^[^;]*OutFile\s+"(.+)"', r'\1', line).rstrip() + if nsissetup == "": + print "Could not retrieve output file name!" + return -1 + shutil.copy(srcfolder + "/" + os.path.dirname(nsisscript) + "/" + nsissetup, setupfile) return 0 |