Skip to content

Commit

Permalink
Add test Makefiles for more IDEs
Browse files Browse the repository at this point in the history
Expand Wizard test script
  • Loading branch information
scaprile committed Oct 8, 2024
1 parent 8a8ff2a commit 00955ed
Show file tree
Hide file tree
Showing 4 changed files with 63 additions and 8 deletions.
12 changes: 12 additions & 0 deletions test/cgt+make/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
ROOT ?= $(realpath $(CURDIR)/../..)
TARGET ?= Debug
DOCKER = docker run --rm -v $(ROOT):$(ROOT) -v $(CURDIR):/root -w $(CURDIR)
IMAGE ?= scaprile/cgt

all: $(PROJECTS)
echo

$(PROJECTS): FORCE
$(DOCKER) $(IMAGE) make -C $@

FORCE:
12 changes: 10 additions & 2 deletions test/cube/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,15 @@ all: $(PROJECTS)

$(PROJECTS): FORCE
(make -C $@ && make -C $@ clean) || ( \
PROJNAME=`xq -r .projectDescription.name $@/.project` && \
$(DOCKER) $(IMAGE) $(PATHTO)headless-build.sh -data workspace -import $@ -cleanBuild $$PROJNAME/$(TARGET) )
COREDIRS=`find $@ -maxdepth 1 -name 'CM*' -print` && ( \
(test "$$COREDIRS" == "" && \
PROJNAME=`xq -r .projectDescription.name $@/.project` && \
$(DOCKER) $(IMAGE) $(PATHTO)headless-build.sh -data workspace -import $@ -cleanBuild $$PROJNAME/$(TARGET) ) || ( \
(test "$$COREDIRS" != "" && \
for core in $$COREDIRS; do \
DIR=`basename $$core` \
PROJNAME=`xq -r .projectDescription.name $@/$$DIR/.project` && \
$(DOCKER) $(IMAGE) $(PATHTO)headless-build.sh -data workspace -import $@/$$DIR -cleanBuild $$PROJNAME/$(TARGET) || exit 1; \
done ))))

FORCE:
16 changes: 16 additions & 0 deletions test/wizard/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,20 @@ ifeq "$(IDE)" "GCC+make"
BUILD = $(MAKE) -f ../gcc+make/Makefile PROJECTS=wizard
endif
ifeq "$(IDE)" "CubeIDE"
<<<<<<< HEAD
BUILD = $(MAKE) -f ../cube/Makefile PROJECTS=wizard
endif
ifeq "$(IDE)" "MCUXpresso"
BUILD = $(MAKE) -f ../xpresso/Makefile PROJECTS=wizard
endif
ifeq "$(IDE)" "Zephyr"
BUILD = true
=======
BUILD = $(MAKE) -f ../cube/Makefile PROJECTS=wizard && rm -rf workspace
endif
ifeq "$(IDE)" "MCUXpresso"
BUILD = $(MAKE) -f ../xpresso/Makefile PROJECTS=wizard && rm -rf workspace
>>>>>>> ae610b57 (Add test Makefiles for IDEs)
endif
ifeq "$(IDE)" "Keil"
BUILD = true
Expand All @@ -26,6 +33,15 @@ endif
ifeq "$(IDE)" "Arduino"
BUILD = true
endif
<<<<<<< HEAD
=======
ifeq "$(IDE)" "CGT+make"
BUILD = $(MAKE) -f ../cgt+make/Makefile PROJECTS=wizard
endif
ifeq "$(IDE)" "Zephyr"
BUILD = $(MAKE) -f ../zephyr/Makefile PROJECTS=wizard BOARD=$(BOARD)
endif
>>>>>>> ae610b57 (Add test Makefiles for IDEs)


firmware.bin: wizard
Expand Down
31 changes: 25 additions & 6 deletions test/wizard/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ rm test.log

STM32="f207 f429 f439 f746 f756 f767 h563 h573 h723 h735 h743 h745 h747 h753 h755"
STIDES="GCC+make CubeIDE"
# Zephyr: !f439
# Keil: f756
for board in $STM32; do
for ide in $STIDES; do
Expand All @@ -28,16 +27,19 @@ for board in $STM32; do
done


NXP="rt1020 rt1024 rt1040 rt1060 rt1064 rt1170 mcxn947"
NXPIDES="GCC+make"
#MCUXpresso: mcxn947
NXP="mcxn947"
NXPIDES="GCC+make MCUXpresso"
for board in $NXP; do
for ide in $NXPIDES; do
for rtos in "baremetal"; do
for rtos in $RTOSES; do
dotest $board $ide $rtos
done
done
done
NXP="rt1020 rt1024 rt1040 rt1060 rt1064 rt1170"
for board in $NXP; do
dotest $board "GCC+make" "baremetal"
done


INFINEON="xmc4400 xmc4700 xmc7200"
Expand All @@ -51,8 +53,19 @@ for board in $INFINEON; do
done


TI="tm4c129"
TIIDES="GCC+make"
for board in $TI; do
for ide in $TIIDES; do
for rtos in $RTOSES; do
dotest $board $ide $rtos
done
done
done
dotest "tms570" "CGT+make" "baremetal"


PICO="evb-pico"
#Zephyr
for board in $PICO; do
for rtos in "baremetal"; do
dotest $board "Pico-SDK" $rtos
Expand All @@ -66,6 +79,12 @@ for board in $ESP; do
done


ZEPHYR="f207 f429 f746 f756 f767 h563 h573 h723 h735 h743 h745 h747 h753 h755 mcxn947 rt1060 rt1064 evb-pico"
for board in $ZEPHYR; do
echo dotest $board "Zephyr" "baremetal"
done


ARDUINO="teensy41"

rm -rf workspace pico-sdk
Expand Down

0 comments on commit 00955ed

Please sign in to comment.