Skip to content

Commit 9982734

Browse files
danielinuxmattia-moffa
authored andcommitted
Exclude stm32c0 (too small for clang) and stm32h5 (no ARMORED support)
1 parent f7b2e5a commit 9982734

4 files changed

Lines changed: 6 additions & 12 deletions

File tree

.github/workflows/test-build.yml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,6 @@ jobs:
3232

3333
- name: Install Clang
3434
if: |
35-
inputs.config-file == './config/examples/stm32c0.config' ||
36-
inputs.config-file == './config/examples/stm32c0-rsa2048.config' ||
37-
inputs.config-file == './config/examples/stm32h5.config' ||
38-
inputs.config-file == './config/examples/stm32h5-dualbank.config' ||
3935
inputs.config-file == './config/examples/stm32h7.config' ||
4036
inputs.config-file == './config/examples/stm32h7-octospi.config' ||
4137
inputs.config-file == './config/examples/stm32u5.config' ||
@@ -63,10 +59,6 @@ jobs:
6359
6460
- name: Rebuild wolfboot with Clang
6561
if: |
66-
inputs.config-file == './config/examples/stm32c0.config' ||
67-
inputs.config-file == './config/examples/stm32c0-rsa2048.config' ||
68-
inputs.config-file == './config/examples/stm32h5.config' ||
69-
inputs.config-file == './config/examples/stm32h5-dualbank.config' ||
7062
inputs.config-file == './config/examples/stm32h7.config' ||
7163
inputs.config-file == './config/examples/stm32h7-octospi.config' ||
7264
inputs.config-file == './config/examples/stm32u5.config' ||

arch.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1300,7 +1300,7 @@ ifeq ($(USE_CLANG),1)
13001300
CFLAGS+=-DWOLFSSL_NO_ATOMIC -DWOLFSSL_NO_ATOMICS
13011301
CFLAGS+=-Wno-unknown-attributes -Wno-error=unknown-attributes
13021302
CFLAGS+=-fno-unwind-tables -fno-asynchronous-unwind-tables
1303-
LSCRIPT_FLAGS+=-T hal/clang-discard.ld
1303+
LSCRIPT_FLAGS+=-T $(abspath $(WOLFBOOT_ROOT)/hal/clang-discard.ld)
13041304
endif
13051305

13061306
ifeq ($(USE_GCC),1)

options.mk

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@ ifeq ($(USE_CLANG),1)
1212
ifeq ($(USE_GCC),1)
1313
$(error USE_CLANG=1 is incompatible with USE_GCC=1; set USE_GCC=0)
1414
endif
15+
ifeq ($(ARMORED),1)
16+
$(error USE_CLANG=1 requires ARMORED=0)
17+
endif
1518
endif
1619

1720
# Support for Built-in ROT into OTP flash memory

test-app/Makefile

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,6 @@ ifeq ($(USE_CLANG),1)
109109
# objcopy output then expands the flash-to-RAM gap into a huge sparse image.
110110
# The app image only needs the flash-backed output sections.
111111
OBJCOPY_IMAGE_FLAGS+=-j .text -j .edidx
112-
LDFLAGS+=-T ../hal/clang-discard.ld
113112
endif
114113

115114
ifeq ($(DEBUG_UART),1)
@@ -947,7 +946,7 @@ ifeq ($(ELF_FLASH_SCATTER),1)
947946
SQUASHELF_TOOL = ../tools/squashelf/squashelf
948947
image-orig.elf: $(APP_OBJS) $(LSCRIPT)
949948
@echo "\t[LD] $@"
950-
$(Q)$(LD) $(LDFLAGS) $(APP_OBJS) $(LIBS) $(OUTPUT_FLAG) $@
949+
$(Q)$(LD) $(LDFLAGS) $(LSCRIPT_FLAGS) $(APP_OBJS) $(LIBS) $(OUTPUT_FLAG) $@
951950

952951
image.elf: image-orig.elf
953952
@echo "\t[SQUASHELF] $@"
@@ -956,7 +955,7 @@ else
956955
# Default behavior when ELF_FLASH_SCATTER is not set
957956
image.elf: $(APP_OBJS) $(LSCRIPT)
958957
@echo "\t[LD] $@"
959-
$(Q)$(LD) $(LDFLAGS) $(APP_OBJS) $(LIBS) $(OUTPUT_FLAG) $@
958+
$(Q)$(LD) $(LDFLAGS) $(LSCRIPT_FLAGS) $(APP_OBJS) $(LIBS) $(OUTPUT_FLAG) $@
960959
endif
961960

962961
standalone: image.bin

0 commit comments

Comments
 (0)