File tree Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change @@ -10,23 +10,35 @@ SRC_HEX = $(BUILD)/MICROBIT.hex
10
10
SRC_MAP = $(CODAL_BUILD ) /MICROBIT.map
11
11
DEST_HEX = ./MICROBIT.hex
12
12
13
+ define CODAL_CLEAN
14
+ git -C $(CODAL_DIR ) checkout CMakeLists.txt
15
+ endef
16
+
17
+ define CODAL_PATCH
18
+ $(call CODAL_CLEAN)
19
+ cat codal.patch | git -C $(CODAL_DIR ) apply -
20
+ endef
21
+
13
22
.PHONY : all codal_build libmicropython clean
14
23
15
24
all : codal_build
16
25
17
26
codal_build : libmicropython
27
+ $(call CODAL_PATCH)
18
28
make -C $(BUILD )
29
+ $(call CODAL_CLEAN)
19
30
arm-none-eabi-size $(CODAL_BUILD ) /MICROBIT
20
31
$(PYTHON3 ) addlayouttable.py $(SRC_HEX ) $(SRC_MAP ) -o $(DEST_HEX )
21
32
22
33
libmicropython : $(CODAL_DIR ) /libraries
34
+ $(call CODAL_CLEAN)
23
35
$(MAKE ) -C codal_port
24
36
25
37
$(CODAL_LIBRARIES ) :
26
38
$(MKDIR ) -p $(BUILD )
27
- git -C $(CODAL_DIR ) checkout CMakeLists.txt
28
- cat codal.patch | git -C $(CODAL_DIR ) apply -
39
+ $(call CODAL_PATCH)
29
40
(cd $( BUILD) && cmake ../$( CODAL_DIR) -DCMAKE_BUILD_TYPE=RelWithDebInfo)
41
+ $(call CODAL_CLEAN)
30
42
31
43
clean :
32
44
$(MAKE ) -C codal_port clean
You can’t perform that action at this time.
0 commit comments