2020-06-10 18:54:14 +02:00
|
|
|
CC = $(PREFIX)gcc
|
|
|
|
CXX = $(PREFIX)g++
|
|
|
|
CCAS ?= $(CC)
|
2015-07-10 11:57:43 +02:00
|
|
|
ifeq ($(LTO),1)
|
2020-06-10 18:54:14 +02:00
|
|
|
AR = $(PREFIX)gcc-ar
|
|
|
|
RANLIB = $(PREFIX)gcc-ranlib
|
2015-07-10 11:57:43 +02:00
|
|
|
else
|
2020-06-10 18:54:14 +02:00
|
|
|
AR = $(PREFIX)ar
|
|
|
|
RANLIB = $(PREFIX)ranlib
|
2015-07-10 11:57:43 +02:00
|
|
|
endif
|
2020-06-10 18:54:14 +02:00
|
|
|
AS = $(PREFIX)as
|
|
|
|
NM = $(PREFIX)nm
|
|
|
|
LINK = $(PREFIX)gcc
|
|
|
|
LINKXX = $(PREFIX)g++
|
|
|
|
SIZE = $(PREFIX)size
|
2020-02-04 15:21:24 +01:00
|
|
|
_OBJCOPY := $(shell command -v $(PREFIX)objcopy || command -v gobjcopy || command -v objcopy)
|
2020-06-10 18:54:14 +02:00
|
|
|
OBJCOPY ?= $(_OBJCOPY)
|
2016-10-31 22:28:43 +01:00
|
|
|
ifeq ($(OBJCOPY),)
|
2020-06-10 18:54:14 +02:00
|
|
|
$(warning objcopy not found. Hex file will not be created.)
|
|
|
|
OBJCOPY = true
|
2016-10-31 22:28:43 +01:00
|
|
|
endif
|
2019-01-25 16:55:37 +01:00
|
|
|
# Default to the native (g)objdump, helps when using toolchain from docker
|
2020-02-04 15:21:24 +01:00
|
|
|
_OBJDUMP := $(or $(shell command -v $(PREFIX)objdump || command -v gobjdump),objdump)
|
2020-06-10 18:54:14 +02:00
|
|
|
OBJDUMP ?= $(_OBJDUMP)
|
2017-10-06 13:51:47 +02:00
|
|
|
# We use GDB for debugging
|
|
|
|
include $(RIOTMAKE)/tools/gdb.inc.mk
|