1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
RIOT/cpu/Makefile.include.llvm

24 lines
856 B
Makefile
Raw Normal View History

export GDBPREFIX ?= $(PREFIX)
export LLVMPREFIX ?= llvm-
export CC = clang
export CXX = clang++
export LINK = $(CC)
export AS = $(LLVMPREFIX)as
export AR = $(LLVMPREFIX)ar
export NM = $(LLVMPREFIX)nm
# There is no LLVM linker yet, use GNU binutils.
#export LINKER = $(LLVMPREFIX)ld
# objcopy does not have a clear substitute in LLVM, use GNU binutils
#export OBJCOPY = $(LLVMPREFIX)objcopy
export OBJCOPY = $(PREFIX)objcopy
export OBJDUMP = $(LLVMPREFIX)objdump
export SIZE = $(LLVMPREFIX)size
export DBG = $(GDBPREFIX)gdb
# LLVM lacks a binutils strip tool as well...
#export STRIP = $(LLVMPREFIX)strip
# Tell clang to cross compile
export CFLAGS += -target $(TARGET_ARCH)
export CXXFLAGS += -target $(TARGET_ARCH)
export LINKFLAGS += -target $(TARGET_ARCH)