forked from elovalo/elovalo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSConstruct
54 lines (43 loc) · 1.44 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
49
50
51
52
53
54
# -*- mode: python; coding: utf-8 -*-
import os
from generators import effects, playlists
cwd = GetLaunchDir()
effects.generate(
os.path.join(cwd, 'src', 'effects') + '/*.c',
os.path.join(cwd, 'src', 'effects.c')
)
playlists.generate(
os.path.join(cwd, 'src/playlists/'),
os.path.join(cwd, 'src/playlists/')
)
AddOption('--no-avr',
dest='build_avr',
action='store_false',
default=True,
help='Do not build to AVR architecture')
AddOption('--no-release',
dest='build_release',
action='store_false',
default=True,
help='Do not build release target')
AddOption('--program',
dest='program',
action='store_true',
default=False,
help='Program the microcontroller after build')
AddOption('--no-exporter',
dest='build_exporter',
action='store_false',
default=True,
help='Do not build exporter')
AddOption('--no-asm',
dest='use_asm',
action='store_false',
default=True,
help='Do not use optimized interrupt handlers')
if GetOption('build_avr'):
SConscript('debug.scons', variant_dir='build/debug', duplicate=0)
if GetOption('build_avr') and GetOption('build_release'):
SConscript('release.scons', variant_dir='build/release', duplicate=0)
if GetOption('build_exporter'):
SConscript('exporter.scons', variant_dir='build/exporter', duplicate=0)