-
Notifications
You must be signed in to change notification settings - Fork 3
/
SConstruct
48 lines (39 loc) · 1.18 KB
/
SConstruct
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
import glob
import os
import IEEnv
import VersionControl
VersionControl.setVersion('IEBuild', '6.15.1')
import IEBuild
majorVersion = '0'
minorVersion = '0'
patchVersion = '1'
versionParts = {'major':majorVersion, 'minor':minorVersion, 'patch':patchVersion}
version = '{major}.{minor}.{patch}'.format(**versionParts)
application = 'xcorder'
if "INSTALLPREFIX" not in ARGUMENTS:
if ARGUMENTS.get("RELEASE", "0") == "1" :
ARGUMENTS["INSTALLPREFIX"] = "{root}/apps/{application}/{version}/".format(
root=IEEnv.Environment.rootPath(),
application=application,
version=version,
)
else:
ARGUMENTS["INSTALLPREFIX"] = "{home}/apps/{application}/{version}/".format(
home=os.path.expanduser("~"),
application=application,
version=version,
)
else:
ARGUMENTS["INSTALLPREFIX"] = "{prefix}/apps/{application}/{version}/".format(
prefix=ARGUMENTS["INSTALLPREFIX"],
application=application,
version=version,
)
program = IEBuild.Buildable(
ARGUMENTS,
)
env = program.finalize()
source = []
for pattern in ['*.py', '*.svg', '*.qss', 'README.*', '*LICENSE*', 'xcorder']:
env.Install(ARGUMENTS['INSTALLPREFIX'], glob.glob(pattern))
env.Alias('install', ARGUMENTS['INSTALLPREFIX'])