1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20 import os
21
22 import configuration
23 import buildtools
24
25
27 """"""
30
31 - def write(self, buildFilePath):
32 sisConfigs = self.configSet.getConfigurations()
33 commandList = buildtools.CommandList()
34 for config in sisConfigs:
35 makeSisArgs = ['-v', config['name'] + '.pkg', config['name'] + '.sis']
36 makeSisCommand = buildtools.Command(config['makesis.tool'], config['path'], makeSisArgs)
37 commandList.addCommand(makeSisCommand)
38
39 signSisArgs = ['-v', config['name'] + '.sis', config['name'] + '.sisx', config['cert'], config['key']]
40 signSisCommand = buildtools.Command(config['signsis.tool'], config['path'], signSisArgs)
41 commandList.addCommand(signSisCommand, newstage=True)
42
43
44
45 srcFile = os.path.join(config['path'], config['name'] + '.sisx')
46 todir = config['build.sisfiles.dir']
47
48 mkdirCommand = buildtools.Command('mkdir', config['path'], [todir])
49 commandList.addCommand(mkdirCommand, newstage=True)
50
51 copyCommand = buildtools.Command('xcopy', config['path'], [srcFile, todir])
52 commandList.addCommand(copyCommand, newstage=True)
53
54 self.writeBuildFile(commandList, buildFilePath)
55