forked from openwsn-berkeley/openwsn-fw
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
FW-190. Adding missing SCons* files.
- Loading branch information
Showing
5 changed files
with
188 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
import os | ||
|
||
Import('env') | ||
|
||
localEnv = env.Clone() | ||
|
||
# scons doesn't let us look to parent directories for source, so the | ||
# bsp/chips/at86rf231/radio.c is off limits from this file. To keep things | ||
# simple, each SConscript file in bsp/chips/* will return a list of objects | ||
# which can be appended to the source list. Don't forget to specify a variant_dir, | ||
# or else the build will occur directly in the chips directory. | ||
|
||
rf231 = localEnv.SConscript( | ||
os.path.join('#','firmware','openos','bsp','chips','at86rf231','SConscript'), | ||
variant_dir = 'rf231', | ||
exports = {'env': env}, | ||
) | ||
|
||
target = 'libbsp' | ||
bsp_dir = os.path.join('#','firmware','openos','bsp','boards','iot-lab_M3') | ||
source = \ | ||
Glob('*.c') + \ | ||
Glob('source/*.c') + \ | ||
[rf231] | ||
|
||
libbsp = localEnv.Library( | ||
target=target, | ||
source=source, | ||
) | ||
|
||
Alias('libbsp', libbsp) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
import os | ||
|
||
Import('env') | ||
|
||
env.SconscriptScanner() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import os | ||
|
||
Import('env') | ||
|
||
# create build environment | ||
buildEnv = env.Clone() | ||
|
||
# inherit environment from user (PATH, etc) | ||
buildEnv['ENV'] = os.environ | ||
|
||
# choose bsp. Normally this would be the same as the board name, | ||
# however, there are cases where one might want to make separate build | ||
# configuration for the same board. | ||
buildEnv['BSP'] = buildEnv['board'] | ||
|
||
bsp_dir = os.path.join('#','firmware','openos','bsp','boards',buildEnv['board']) | ||
|
||
# include board/bsp-specific directories | ||
buildEnv.Append( | ||
CPPPATH = [ | ||
bsp_dir, | ||
os.path.join(bsp_dir,'inc'), | ||
os.path.join(bsp_dir,'source'), | ||
] | ||
) | ||
|
||
Return('buildEnv') |