mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-05-30 03:27:33 +08:00
[build] ChibiOS binary is produced in OBJDIR folder
prevent unnecessary linking when uploading
This commit is contained in:
@@ -66,14 +66,19 @@ endif
|
|||||||
#ifeq ($(BUILDDIR),.)
|
#ifeq ($(BUILDDIR),.)
|
||||||
# BUILDDIR = build
|
# BUILDDIR = build
|
||||||
#endif
|
#endif
|
||||||
OUTFILES = $(BUILDDIR)/$(PROJECT).elf \
|
|
||||||
$(BUILDDIR)/$(PROJECT).hex \
|
# Various directories
|
||||||
$(BUILDDIR)/$(PROJECT).bin \
|
OBJDIR = $(BUILDDIR)/obj
|
||||||
$(BUILDDIR)/$(PROJECT).dmp \
|
LSTDIR = $(BUILDDIR)/lst
|
||||||
$(BUILDDIR)/$(PROJECT).list
|
|
||||||
|
OUTFILES = $(OBJDIR)/$(PROJECT).elf \
|
||||||
|
$(OBJDIR)/$(PROJECT).hex \
|
||||||
|
$(OBJDIR)/$(PROJECT).bin \
|
||||||
|
$(OBJDIR)/$(PROJECT).dmp \
|
||||||
|
$(OBJDIR)/$(PROJECT).list
|
||||||
|
|
||||||
ifdef SREC
|
ifdef SREC
|
||||||
OUTFILES += $(BUILDDIR)/$(PROJECT).srec
|
OUTFILES += $(OBJDIR)/$(PROJECT).srec
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# Source files groups and paths
|
# Source files groups and paths
|
||||||
@@ -88,10 +93,6 @@ ASRC = $(ACSRC) $(ACPPSRC)
|
|||||||
TSRC = $(TCSRC) $(TCPPSRC)
|
TSRC = $(TCSRC) $(TCPPSRC)
|
||||||
SRCPATHS = $(sort $(dir $(ASMXSRC)) $(dir $(ASMSRC)) $(dir $(ASRC)) $(dir $(TSRC)))
|
SRCPATHS = $(sort $(dir $(ASMXSRC)) $(dir $(ASMSRC)) $(dir $(ASRC)) $(dir $(TSRC)))
|
||||||
|
|
||||||
# Various directories
|
|
||||||
OBJDIR = $(BUILDDIR)/obj
|
|
||||||
LSTDIR = $(BUILDDIR)/lst
|
|
||||||
|
|
||||||
# Object files groups
|
# Object files groups
|
||||||
ACOBJS = $(addprefix $(OBJDIR)/, $(notdir $(ACSRC:.c=.o)))
|
ACOBJS = $(addprefix $(OBJDIR)/, $(notdir $(ACSRC:.c=.o)))
|
||||||
ACPPOBJS = $(addprefix $(OBJDIR)/, $(notdir $(ACPPSRC:.cpp=.o)))
|
ACPPOBJS = $(addprefix $(OBJDIR)/, $(notdir $(ACPPSRC:.cpp=.o)))
|
||||||
@@ -119,7 +120,7 @@ ASFLAGS = $(MCFLAGS) -Wa,-amhls=$(LSTDIR)/$(notdir $(<:.s=.lst)) $(ADEFS)
|
|||||||
ASXFLAGS = $(MCFLAGS) -Wa,-amhls=$(LSTDIR)/$(notdir $(<:.S=.lst)) $(ADEFS)
|
ASXFLAGS = $(MCFLAGS) -Wa,-amhls=$(LSTDIR)/$(notdir $(<:.S=.lst)) $(ADEFS)
|
||||||
CFLAGS = $(MCFLAGS) $(OPT) $(COPT) $(CWARN) -Wa,-alms=$(LSTDIR)/$(notdir $(<:.c=.lst)) $(DEFS)
|
CFLAGS = $(MCFLAGS) $(OPT) $(COPT) $(CWARN) -Wa,-alms=$(LSTDIR)/$(notdir $(<:.c=.lst)) $(DEFS)
|
||||||
CPPFLAGS = $(MCFLAGS) $(OPT) $(CPPOPT) $(CPPWARN) -Wa,-alms=$(LSTDIR)/$(notdir $(<:.cpp=.lst)) $(DEFS) $(UPDEFS)
|
CPPFLAGS = $(MCFLAGS) $(OPT) $(CPPOPT) $(CPPWARN) -Wa,-alms=$(LSTDIR)/$(notdir $(<:.cpp=.lst)) $(DEFS) $(UPDEFS)
|
||||||
LDFLAGS = $(MCFLAGS) $(OPT) -nostartfiles $(LLIBDIR) -Wl,-Map=$(BUILDDIR)/$(PROJECT).map,--cref,--no-warn-mismatch,--library-path=$(RULESPATH)/ld,--script=$(LDSCRIPT)$(LDOPT)
|
LDFLAGS = $(MCFLAGS) $(OPT) -nostartfiles $(LLIBDIR) -Wl,-Map=$(OBJDIR)/$(PROJECT).map,--cref,--no-warn-mismatch,--library-path=$(RULESPATH)/ld,--script=$(LDSCRIPT)$(LDOPT)
|
||||||
|
|
||||||
# Thumb interwork enabled only if needed because it kills performance.
|
# Thumb interwork enabled only if needed because it kills performance.
|
||||||
ifneq ($(strip $(TSRC)),)
|
ifneq ($(strip $(TSRC)),)
|
||||||
|
|||||||
Reference in New Issue
Block a user