Skip to content

Commit

Permalink
more ci fix
Browse files Browse the repository at this point in the history
  • Loading branch information
hathach committed Mar 6, 2023
1 parent e62d1a0 commit 02478c5
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 38 deletions.
74 changes: 37 additions & 37 deletions examples/make.mk
Original file line number Diff line number Diff line change
Expand Up @@ -30,43 +30,6 @@ CMDEXE := 1
SHELL := cmd.exe
endif

#-------------- Cross Compiler ------------
# Can be set by board, default to ARM GCC
CROSS_COMPILE ?= arm-none-eabi-

ifeq ($(CC),iccarm)
USE_IAR = 1
endif

ifdef USE_IAR
AS = iasmarm
LD = ilinkarm
OBJCOPY = ielftool
SIZE = size

else
CC = $(CROSS_COMPILE)gcc
CXX = $(CROSS_COMPILE)g++
AS = $(CC) -x assembler-with-cpp
LD = $(CC)

GDB = $(CROSS_COMPILE)gdb
OBJCOPY = $(CROSS_COMPILE)objcopy
SIZE = $(CROSS_COMPILE)size
endif

ifeq ($(CMDEXE),1)
CP = copy
RM = del
MKDIR = mkdir
PYTHON = python
else
CP = cp
RM = rm
MKDIR = mkdir
PYTHON = python3
endif


# Build directory
BUILD := _build/$(BOARD)
Expand Down Expand Up @@ -111,6 +74,43 @@ else
SRC_C += $(subst $(TOP)/,,$(wildcard $(TOP)/$(FAMILY_PATH)/*.c))
endif

#-------------- Cross Compiler ------------
# Can be set by board, default to ARM GCC
CROSS_COMPILE ?= arm-none-eabi-

ifeq ($(CC),iccarm)
USE_IAR = 1
endif

ifdef USE_IAR
AS = iasmarm
LD = ilinkarm
OBJCOPY = ielftool
SIZE = size

else
CC = $(CROSS_COMPILE)gcc
CXX = $(CROSS_COMPILE)g++
AS = $(CC) -x assembler-with-cpp
LD = $(CC)

GDB = $(CROSS_COMPILE)gdb
OBJCOPY = $(CROSS_COMPILE)objcopy
SIZE = $(CROSS_COMPILE)size
endif

ifeq ($(CMDEXE),1)
CP = copy
RM = del
MKDIR = mkdir
PYTHON = python
else
CP = cp
RM = rm
MKDIR = mkdir
PYTHON = python3
endif

#-------------- Source files and compiler flags --------------

# Include all source C in family & board folder
Expand Down
2 changes: 1 addition & 1 deletion hw/bsp/stm32h7/family.mk
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ GCC_CFLAGS += \
-nostdlib -nostartfiles

# suppress warning caused by vendor mcu driver
GCC_CFLAGS += -Wno-error=maybe-uninitialized -Wno-error=cast-align
GCC_CFLAGS += -Wno-error=maybe-uninitialized -Wno-error=cast-align -Wno-error=unused-parameter

# IAR Flags
IAR_CFLAGS += --cpu cortex-m7 --fpu VFPv5_D16
Expand Down

0 comments on commit 02478c5

Please sign in to comment.