1
0
Fork 0
forked from len0rd/rockbox

Restructure and rename deploy-release.py.

Move actual working functionality into a python module, and write a
simple script to use it.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27598 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Dominik Riebeling 2010-07-28 18:37:12 +00:00
parent 980e0c7383
commit a9acd1f45b
2 changed files with 78 additions and 43 deletions

View file

@ -0,0 +1,68 @@
#!/usr/bin/python
# __________ __ ___.
# Open \______ \ ____ ____ | | _\_ |__ _______ ___
# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
# \/ \/ \/ \/ \/
# $Id$
#
# Copyright (c) 2010 Dominik Riebeling
#
# All files in this archive are subject to the GNU General Public License.
# See the file COPYING in the source tree root for full license agreement.
#
# This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
# KIND, either express or implied.
#
import deploy
import sys
deploy.program = "RockboxUtility"
deploy.project = "rbutil/rbutilqt/rbutilqt.pro"
deploy.svnserver = "svn://svn.rockbox.org/rockbox/"
deploy.svnpaths = \
[ "rbutil/",
"tools/ucl",
"tools/rbspeex",
"apps/codecs/libspeex",
"docs/COPYING",
"docs/CREDITS",
"tools/iriver.c",
"tools/Makefile",
"tools/mkboot.h",
"tools/voicefont.c",
"tools/VOICE_PAUSE.wav",
"tools/wavtrim.h",
"tools/iriver.h",
"tools/mkboot.c",
"tools/telechips.c",
"tools/telechips.h",
"tools/voicefont.h",
"tools/wavtrim.c",
"tools/sapi_voice.vbs" ]
deploy.useupx = False
deploy.bundlecopy = {
"icons/rbutilqt.icns" : "Contents/Resources/",
"Info.plist" : "Contents/"
}
# Windows nees some special treatment. Differentiate between program name
# and executable filename.
if sys.platform == "win32":
deploy.progexe = "Release/" + deploy.program + ".exe"
deploy.make = "mingw32-make"
elif sys.platform == "darwin":
deploy.progexe = deploy.program + ".app"
# OS X 10.6 defaults to gcc 4.2. Building universal binaries that are
# compatible with 10.4 requires using gcc-4.0.
if not "QMAKESPEC" in deploy.environment:
deploy.environment["QMAKESPEC"] = "macx-g++40"
else:
deploy.progexe = deploy.program
# all files of the program. Will get put into an archive after building
# (zip on w32, tar.bz2 on Linux). Does not apply on Mac which uses dmg.
deploy.programfiles = [ deploy.progexe ]
deploy.deploy()

View file

@ -63,57 +63,23 @@ except ImportError:
# == Global stuff ==
# Windows nees some special treatment. Differentiate between program name
# and executable filename.
program = "RockboxUtility"
project = "rbutil/rbutilqt/rbutilqt.pro"
program = ""
project = ""
environment = os.environ
progexe = ""
make = "make"
if sys.platform == "win32":
progexe = "Release/" + program + ".exe"
make = "mingw32-make"
elif sys.platform == "darwin":
progexe = program + ".app"
# OS X 10.6 defaults to gcc 4.2. Building universal binaries that are
# compatible with 10.4 requires using gcc-4.0.
if not "QMAKESPEC" in environment:
environment["QMAKESPEC"] = "macx-g++40"
else:
progexe = program
programfiles = []
# all files of the program. Will get put into an archive after building
# (zip on w32, tar.bz2 on Linux). Does not apply on Mac which uses dmg.
programfiles = [ progexe ]
svnserver = "svn://svn.rockbox.org/rockbox/"
svnserver = ""
# Paths and files to retrieve from svn when creating a tarball.
# This is a mixed list, holding both paths and filenames.
svnpaths = [ "rbutil/",
"tools/ucl",
"tools/rbspeex",
"apps/codecs/libspeex",
"docs/COPYING",
"docs/CREDITS",
"tools/iriver.c",
"tools/Makefile",
"tools/mkboot.h",
"tools/voicefont.c",
"tools/VOICE_PAUSE.wav",
"tools/wavtrim.h",
"tools/iriver.h",
"tools/mkboot.c",
"tools/telechips.c",
"tools/telechips.h",
"tools/voicefont.h",
"tools/wavtrim.c",
"tools/sapi_voice.vbs" ]
svnpaths = [ ]
# set this to true to run upx on the resulting binary, false to skip this step.
# only used on w32.
useupx = False
# OS X: files to copy into the bundle. Workaround for out-of-tree builds.
bundlecopy = {
"icons/rbutilqt.icns" : "Contents/Resources/",
"Info.plist" : "Contents/"
}
bundlecopy = { }
# == Functions ==
def usage(myself):
@ -374,8 +340,9 @@ def tempclean(workfolder, nopro):
print "Temporary files kept at %s" % workfolder
def main():
def deploy():
startup = time.time()
try:
opts, args = getopt.getopt(sys.argv[1:], "q:p:t:a:sbdkh",
["qmake=", "project=", "tag=", "add=", "source-only", "binary-only", "dynamic", "keep-temp", "help"])
@ -526,5 +493,5 @@ def main():
if __name__ == "__main__":
main()
deploy()