waf: allow boards to tweak build

We define a function build() that can be overrode by Board subclasses.
This commit is contained in:
Gustavo Jose de Sousa 2016-02-24 19:18:00 +00:00 committed by Lucas De Marchi
parent 1fe795f283
commit 8664c0344d
2 changed files with 4 additions and 0 deletions

View File

@ -99,6 +99,9 @@ class Board:
'-Wl,--gc-sections', '-Wl,--gc-sections',
] ]
def build(self, bld):
pass
Board = BoardMeta('Board', Board.__bases__, dict(Board.__dict__)) Board = BoardMeta('Board', Board.__bases__, dict(Board.__dict__))
def get_boards_names(): def get_boards_names():

View File

@ -234,6 +234,7 @@ def build(bld):
_build_dynamic_sources(bld) _build_dynamic_sources(bld)
bld.add_group('build') bld.add_group('build')
boards.get_board(bld.env.BOARD).build(bld)
_build_common_taskgens(bld) _build_common_taskgens(bld)
_build_recursion(bld) _build_recursion(bld)