Changed: #1093 Create client_install using bnps made in client_patch.
This commit is contained in:
parent
29dff59e7c
commit
de4d271857
1 changed files with 24 additions and 39 deletions
|
@ -45,14 +45,7 @@ printLog(log, "-------")
|
||||||
printLog(log, time.strftime("%Y-%m-%d %H:%MGMT", time.gmtime(time.time())))
|
printLog(log, time.strftime("%Y-%m-%d %H:%MGMT", time.gmtime(time.time())))
|
||||||
printLog(log, "")
|
printLog(log, "")
|
||||||
|
|
||||||
# Find tools
|
for category in InstallClientData:
|
||||||
BnpMake = findTool(log, ToolDirectories, BnpMakeTool, ToolSuffix)
|
|
||||||
printLog(log, "")
|
|
||||||
|
|
||||||
if BnpMake == "":
|
|
||||||
toolLogFail(log, BnpMakeTool, ToolSuffix)
|
|
||||||
else:
|
|
||||||
for category in InstallClientData:
|
|
||||||
printLog(log, "CATEGORY " + category["Name"])
|
printLog(log, "CATEGORY " + category["Name"])
|
||||||
if (category["UnpackTo"] != None):
|
if (category["UnpackTo"] != None):
|
||||||
targetPath = ClientInstallDirectory
|
targetPath = ClientInstallDirectory
|
||||||
|
@ -64,26 +57,18 @@ else:
|
||||||
mkPath(log, InstallDirectory + "/" + package[0])
|
mkPath(log, InstallDirectory + "/" + package[0])
|
||||||
copyFilesNoTreeIfNeeded(log, InstallDirectory + "/" + package[0], targetPath)
|
copyFilesNoTreeIfNeeded(log, InstallDirectory + "/" + package[0], targetPath)
|
||||||
else:
|
else:
|
||||||
|
sourcePath = ClientPatchDirectory + "/bnp"
|
||||||
targetPath = ClientInstallDirectory + "/data"
|
targetPath = ClientInstallDirectory + "/data"
|
||||||
mkPath(log, targetPath)
|
mkPath(log, targetPath)
|
||||||
for package in category["Packages"]:
|
for package in category["Packages"]:
|
||||||
printLog(log, "PACKAGE " + package[0])
|
printLog(log, "PACKAGE " + package[0])
|
||||||
sourcePath = InstallDirectory + "/" + package[0]
|
sourceBnp = sourcePath + "/" + package[0] + ".bnp"
|
||||||
mkPath(log, sourcePath)
|
|
||||||
targetBnp = targetPath + "/" + package[0] + ".bnp"
|
targetBnp = targetPath + "/" + package[0] + ".bnp"
|
||||||
if (len(package[1]) > 0):
|
if (len(package[1]) > 0):
|
||||||
|
sourceBnp = sourcePath + "/" + package[1][0]
|
||||||
targetBnp = targetPath + "/" + package[1][0]
|
targetBnp = targetPath + "/" + package[1][0]
|
||||||
printLog(log, "TARGET " + package[1][0])
|
printLog(log, "TARGET " + package[1][0])
|
||||||
needUpdateBnp = 1
|
copyFileIfNeeded(log, sourceBnp, targetBnp)
|
||||||
if (len(package) > 2):
|
|
||||||
needUpdateBnp = needUpdate(log, sourcePath + "/" + package[2], targetBnp)
|
|
||||||
else:
|
|
||||||
needUpdateBnp = needUpdateDirNoSubdirFile(log, sourcePath, targetBnp)
|
|
||||||
if (needUpdateBnp):
|
|
||||||
printLog(log, "BNP " + targetBnp)
|
|
||||||
subprocess.call([ BnpMake, "/p", sourcePath, targetPath ] + package[1])
|
|
||||||
else:
|
|
||||||
printLog(log, "SKIP " + targetBnp)
|
|
||||||
printLog(log, "")
|
printLog(log, "")
|
||||||
|
|
||||||
log.close()
|
log.close()
|
||||||
|
|
Loading…
Reference in a new issue