Commit 12948963 authored by Legodev's avatar Legodev

support for pbo project

parent b2912a40
......@@ -4,7 +4,8 @@ from pathlib import Path
from utils.findconfigfiles import findconfigfiles
from utils.getdependencylist import getdependencylist
from utils.createaddonbuildercmd import createaddonbuildercmd, arma3ToolsPath, addonBuilderExePath, createsigncmd, \
DSSignFileExePath, MakePboExePath, MakePboOptions, createmikeromakepbocmd
DSSignFileExePath, MakePboExePath, MakePboOptions, createmikeromakepbocmd, createmikeropboprojectcmd, \
pboProjectExePath, pboProjectOptions
from utils.createaddonmakefiledependencies import createmakefilealldependencies, createaddonmakefiledependencies, \
createaddonmakefiledependenciesrefs, createaddonmakefiledependenciessign
......@@ -34,6 +35,8 @@ if createMakefile:
print('DSSIGNFILEEXEPATH={}'.format(DSSignFileExePath), file=f)
print('MAKEPBOEXEPATH={}'.format(MakePboExePath), file=f)
print('MAKEPBOOPTIONS={}'.format(MakePboOptions), file=f)
print('PBOPROJECTEXEPATH={}'.format(pboProjectExePath), file=f)
print('PBOPROJECTOPTIONS={}'.format(pboProjectOptions), file=f)
print('SOURCEADDONSPATH={}'.format(sourceAddonsPath), file=f)
print('DESTINATIONPATH={}'.format(destinationpath), file=f)
print('PROJECTPATH={}'.format(projectPath), file=f)
......@@ -55,7 +58,7 @@ if createMakefile:
print(createaddonmakefiledependencies(addon, sourceAddonPath, destinationpath, dependencies), file=f)
# print('\t{}'.format(createaddonbuildercmd(projectPath, sourceAddonPath, namespace,
# addon, destinationpath, keypath)[1]), file=f)
print('\t{}'.format(createmikeromakepbocmd(sourceAddonsPath, addon, destinationpath)[1]), file=f)
print('\t{}'.format(createmikeropboprojectcmd(sourceAddonsPath, addon, destinationpath)[1]), file=f)
print("", file=f)
print(createaddonmakefiledependenciessign(addon, destinationpath, branch), file=f)
print('\t{}'.format(createsigncmd(addon, destinationpath, keypath)[1]), file=f)
......
......@@ -5,8 +5,9 @@ mikerosToolsPath = Path("C:/Program Files (x86)/Mikero/DePboTools/bin/")
addonBuilderExePath = arma3ToolsPath / "AddonBuilder/AddonBuilder.exe"
DSSignFileExePath = arma3ToolsPath / "DSSignFile/DSSignFile.exe"
MakePboExePath = mikerosToolsPath / "MakePbo.exe"
MakePboOptions = "-PgFWBX=thumbs.db,*.txt,*.h,*.dep,*.cpp,*.bak,*.png,*.log,source"
MakePboOptions = "-PsgFWBX=thumbs.db,*.txt,*.h,*.dep,*.cpp,*.hpp,*.bak,*.png,*.log,source"
pboProjectExePath = mikerosToolsPath / "pboProject.exe"
pboProjectOptions = "+Clean +Noisy +P +G +F"
def createaddonbuildercmd(projectPath, sourceAddonsPath, namespace, addon, destinationpath, keypath):
sourceAddonPath = sourceAddonsPath / addon
......@@ -42,3 +43,12 @@ def createmikeromakepbocmd(sourceAddonsPath, addon, destinationpath):
"${DESTINATIONPATH}")
return cmd, cmdshell
def createmikeropboprojectcmd(sourceAddonsPath, addon, destinationpath):
sourceAddonPath = sourceAddonsPath / addon
cmd = (str(pboProjectExePath), MakePboOptions, str(sourceAddonPath), str(destinationpath))
cmdshell = 'cmd.exe /C "\\"{}\\" {} \\"{}\\" +Mod={}\\ "'.format("${PBOPROJECTEXEPATH}", "${PBOPROJECTOPTIONS}", sourceAddonPath,
"${DESTINATIONPATH}")
return cmd, cmdshell
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment