* ./goodies:
- New: In buildCoriolis.py, adds a "--rm-build" option which removes the tool's build directory before building it. A very crude way to ensure that nothing obsolete form a previous build will gets in the way...
This commit is contained in:
parent
ffc3fb7eee
commit
17ac99fa46
|
@ -57,6 +57,7 @@ class ProjectBuilder:
|
|||
self._rootDir = os.path.join ( os.environ["HOME"], "coriolis-2.x" )
|
||||
self._quiet = False
|
||||
self._buildMode = "Release"
|
||||
self._rmBuild = False
|
||||
self._doBuild = True
|
||||
self._noCache = False
|
||||
self._enableShared = "ON"
|
||||
|
@ -83,6 +84,7 @@ class ProjectBuilder:
|
|||
elif attribute == "rootDir": self._rootDir = os.path.expanduser(value)
|
||||
elif attribute == "quiet": self._quiet = value
|
||||
elif attribute == "buildMode": self._buildMode = value
|
||||
elif attribute == "rmBuild": self._rmBuild = value
|
||||
elif attribute == "doBuild": self._doBuild = value
|
||||
elif attribute == "noCache": self._noCache = value
|
||||
elif attribute == "enableShared": self._enableShared = value
|
||||
|
@ -156,6 +158,12 @@ class ProjectBuilder:
|
|||
if not os.path.isdir(toolSourceDir):
|
||||
print "[ERROR] Missing tool source directory: \"%s\" (skipped)." % toolSourceDir
|
||||
return
|
||||
|
||||
if self._rmBuild:
|
||||
print "Removing tool build directory: \"%s\"." % toolBuildDir
|
||||
command = [ "/bin/rm", "-r", toolBuildDir ]
|
||||
self._execute ( command, "Removing tool build directory" )
|
||||
|
||||
if not os.path.isdir(toolBuildDir):
|
||||
print "Creating tool build directory: \"%s\"." % toolBuildDir
|
||||
os.makedirs ( toolBuildDir )
|
||||
|
@ -372,6 +380,7 @@ if __name__ == "__main__":
|
|||
parser.add_option ( "--root" , action="store" , type="string", dest="rootDir" )
|
||||
parser.add_option ( "--no-build" , action="store_true" , dest="noBuild" )
|
||||
parser.add_option ( "--no-cache" , action="store_true" , dest="noCache" )
|
||||
parser.add_option ( "--rm-build" , action="store_true" , dest="rmBuild" )
|
||||
parser.add_option ( "--svn-tag" , action="store" , type="string", dest="svnTag" )
|
||||
parser.add_option ( "--svn-method" , action="store" , type="string", dest="svnMethod")
|
||||
parser.add_option ( "--make" , action="store" , type="string", dest="makeArguments")
|
||||
|
@ -399,6 +408,7 @@ if __name__ == "__main__":
|
|||
if options.rootDir: builder.rootDir = options.rootDir
|
||||
if options.noBuild: builder.doBuild = False
|
||||
if options.noCache: builder.noCache = True
|
||||
if options.rmBuild: builder.rmBuild = True
|
||||
if options.makeArguments: builder.makeArguments = options.makeArguments
|
||||
if options.svnMethod: builder.svnMethod = options.svnMethod
|
||||
if options.svnTag: builder.svnTag = options.svnTag
|
||||
|
|
Loading…
Reference in New Issue