Skip to content

Commit 7a5dcff

Browse files
committed
Comments
1 parent 187f9ac commit 7a5dcff

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

tools/project.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,7 @@
126126
args_error(parser, "[ERROR] You should specify an IDE")
127127
ide = options.ide
128128

129+
# Program Number or name
129130
p, n, src= options.program, options.program_name, options.source_dir
130131

131132
if src is None:
@@ -144,6 +145,8 @@
144145
# Export results
145146
successes = []
146147
failures = []
148+
149+
# source is used to generate IDE files to toolchain directly in the source tree and doesn't generate zip file
147150
zip = src is None
148151
clean = src is None
149152

tools/project_api.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
except:
1616
ps = object()
1717

18+
1819
def get_program(n):
1920
p = TEST_MAP[n].n
2021
return p
@@ -23,6 +24,7 @@ def get_program(n):
2324
def get_test(p):
2425
return Test(p)
2526

27+
2628
def get_test_from_name(n):
2729
if not n in TEST_MAP.keys():
2830
# Check if there is an alias for this in private_settings.py
@@ -36,7 +38,12 @@ def get_test_from_name(n):
3638
return None
3739
return get_program(n)
3840

41+
3942
def setup_project(mcu, ide, program = None, source_dir= None, macros = None, build = None):
43+
44+
# Some libraries have extra macros (called by exporter symbols) to we need to pass
45+
# them to maintain compilation macros integrity between compiled library and
46+
# header files we might use with it
4047
lib_symbols = []
4148
if macros:
4249
lib_symbols += macros
@@ -59,7 +66,7 @@ def setup_project(mcu, ide, program = None, source_dir= None, macros = None, bui
5966
if MBED_LIBRARIES in test.dependencies:
6067
test.dependencies.remove(MBED_LIBRARIES)
6168
test.dependencies.append(MBED_BASE)
62-
69+
# Build the project with the same directory structure of the mbed online IDE
6370
project_name = test.id
6471
project_dir = [join(EXPORT_WORKSPACE, project_name)]
6572
project_temp = EXPORT_TMP

0 commit comments

Comments
 (0)