@@ -14,7 +14,7 @@ $(error Invalid VARIANT specified: $(VARIANT_DIR))
1414endif
1515
1616# If the build directory is not given, make it reflect the variant name.
17- BUILD ?= build-$(VARIANT )
17+ BUILD ?= $( abspath ./ build-$(VARIANT ) )
1818
1919include ../../py/mkenv.mk
2020-include mpconfigport.mk
@@ -258,15 +258,15 @@ include $(TOP)/py/mkrules.mk
258258
259259test : $(BUILD ) /$(PROG ) $(TOP ) /tests/run-tests.py
260260 $(eval DIRNAME=ports/$(notdir $(CURDIR ) ) )
261- cd $(TOP ) /tests && MICROPY_MICROPYTHON=../ $( DIRNAME ) / $(BUILD ) /$(PROG ) ./run-tests.py
261+ cd $(TOP ) /tests && MICROPY_MICROPYTHON=$(BUILD ) /$(PROG ) ./run-tests.py
262262
263263test//% : $(BUILD ) /$(PROG ) $(TOP ) /tests/run-tests.py
264264 $(eval DIRNAME=ports/$(notdir $(CURDIR ) ) )
265- cd $(TOP ) /tests && MICROPY_MICROPYTHON=../ $( DIRNAME ) / $(BUILD ) /$(PROG ) ./run-tests.py -i " $* "
265+ cd $(TOP ) /tests && MICROPY_MICROPYTHON=$(BUILD ) /$(PROG ) ./run-tests.py -i " $* "
266266
267267test-failures : $(BUILD ) /$(PROG ) $(TOP ) /tests/run-tests.py
268268 $(eval DIRNAME=ports/$(notdir $(CURDIR ) ) )
269- cd $(TOP ) /tests && MICROPY_MICROPYTHON=../ $( DIRNAME ) / $(BUILD ) /$(PROG ) ./run-tests.py --run-failures
269+ cd $(TOP ) /tests && MICROPY_MICROPYTHON=$(BUILD ) /$(PROG ) ./run-tests.py --run-failures
270270
271271print-failures :
272272 cd $(TOP ) /tests && ./run-tests.py --print-failures
@@ -276,18 +276,18 @@ clean-failures:
276276
277277test/% : $(BUILD ) /$(PROG ) $(TOP ) /tests/run-tests.py
278278 $(eval DIRNAME=ports/$(notdir $(CURDIR ) ) )
279- cd $(TOP ) /tests && MICROPY_MICROPYTHON=../ $( DIRNAME ) / $(BUILD ) /$(PROG ) ./run-tests.py -d " $* "
279+ cd $(TOP ) /tests && MICROPY_MICROPYTHON=$(BUILD ) /$(PROG ) ./run-tests.py -d " $* "
280280
281281test_full_no_native : $(BUILD ) /$(PROG ) $(TOP ) /tests/run-tests.py
282282 $(eval DIRNAME=ports/$(notdir $(CURDIR ) ) )
283- cd $(TOP ) /tests && MICROPY_MICROPYTHON=../ $( DIRNAME ) / $(BUILD ) /$(PROG ) ./run-tests.py
284- cd $(TOP ) /tests && MICROPY_MICROPYTHON=../ $( DIRNAME ) / $(BUILD ) /$(PROG ) ./run-tests.py --via-mpy $(RUN_TESTS_MPY_CROSS_FLAGS ) -d basics float micropython
285- cat $(TOP ) /tests/basics/0prelim.py | ./ $(BUILD ) /$(PROG ) | grep -q ' abc'
283+ cd $(TOP ) /tests && MICROPY_MICROPYTHON=$(BUILD ) /$(PROG ) ./run-tests.py
284+ cd $(TOP ) /tests && MICROPY_MICROPYTHON=$(BUILD ) /$(PROG ) ./run-tests.py --via-mpy $(RUN_TESTS_MPY_CROSS_FLAGS ) -d basics float micropython
285+ cat $(TOP ) /tests/basics/0prelim.py | $(BUILD ) /$(PROG ) | grep -q ' abc'
286286
287287test_full : $(BUILD ) /$(PROG ) $(TOP ) /tests/run-tests.py test_full_no_native
288288 $(eval DIRNAME=ports/$(notdir $(CURDIR ) ) )
289- cd $(TOP ) /tests && MICROPY_MICROPYTHON=../ $( DIRNAME ) / $(BUILD ) /$(PROG ) ./run-tests.py --emit native
290- cd $(TOP ) /tests && MICROPY_MICROPYTHON=../ $( DIRNAME ) / $(BUILD ) /$(PROG ) ./run-tests.py --via-mpy $(RUN_TESTS_MPY_CROSS_FLAGS ) --emit native -d basics float micropython
289+ cd $(TOP ) /tests && MICROPY_MICROPYTHON=$(BUILD ) /$(PROG ) ./run-tests.py --emit native
290+ cd $(TOP ) /tests && MICROPY_MICROPYTHON=$(BUILD ) /$(PROG ) ./run-tests.py --via-mpy $(RUN_TESTS_MPY_CROSS_FLAGS ) --emit native -d basics float micropython
291291
292292test_gcov : test_full
293293 gcov -o $(BUILD ) /py $(TOP ) /py/* .c
0 commit comments