Skip to content

Commit 49bbe71

Browse files
larocheaggarg
andauthored
Demo/CORTEX_MPS2_QEMU_IAR_GCC add path to IMAGE and remove mapfile (FreeRTOS#1223)
For Demo/CORTEX_MPS2_QEMU_IAR_GCC gcc Makefile: - simplify IMAGE var to already include full path - clean target also removes mapfile Signed-off-by: Florian La Roche <Florian.LaRoche@gmail.com> Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
1 parent 8e54579 commit 49bbe71

File tree

1 file changed

+7
-7
lines changed
  • FreeRTOS/Demo/CORTEX_MPS2_QEMU_IAR_GCC/build/gcc

1 file changed

+7
-7
lines changed

FreeRTOS/Demo/CORTEX_MPS2_QEMU_IAR_GCC/build/gcc/Makefile

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
OUTPUT_DIR := ./output
2-
IMAGE := RTOSDemo.out
2+
IMAGE := $(OUTPUT_DIR)/RTOSDemo.out
33

44
# The directory that contains the /source and /demo sub directories.
55
FREERTOS_ROOT = ./../../../..
@@ -35,7 +35,7 @@ SOURCE_FILES += $(KERNEL_DIR)/portable/MemMang/heap_4.c
3535
SOURCE_FILES += $(KERNEL_DIR)/portable/GCC/ARM_CM3/port.c
3636

3737
#
38-
# Common demo files for the "full" build, as opposed to the "blinky" build -
38+
# Common demo files for the "full" build, as opposed to the "blinky" build -
3939
# these files are build by all the FreeRTOS kernel demos.
4040
#
4141
DEMO_ROOT = $(FREERTOS_ROOT)/Demo
@@ -95,27 +95,27 @@ DEP_FILES := $(SOURCE_FILES:%.c=$(OUTPUT_DIR)/%.d)
9595
DEP_FILES_NO_PATH = $(notdir $(DEP_FILES))
9696
DEP_OUTPUT = $(DEP_FILES_NO_PATH:%.d=$(OUTPUT_DIR)/%.d)
9797

98-
all: $(OUTPUT_DIR)/$(IMAGE)
98+
all: $(IMAGE)
9999

100100
%.o : %.c
101101
$(OUTPUT_DIR)/%.o : %.c $(OUTPUT_DIR)/%.d Makefile
102102
$(CC) $(CFLAGS) -c $< -o $@
103103

104-
$(OUTPUT_DIR)/$(IMAGE): ./mps2_m3.ld $(OBJS_OUTPUT) Makefile
104+
$(IMAGE): ./mps2_m3.ld $(OBJS_OUTPUT) Makefile
105105
@echo ""
106106
@echo ""
107107
@echo "--- Final linking ---"
108108
@echo ""
109109
$(LD) $(OBJS_OUTPUT) $(CFLAGS) -Xlinker --gc-sections -Xlinker -T ./mps2_m3.ld \
110110
-Xlinker -Map=$(OUTPUT_DIR)/RTOSDemo.map -specs=nano.specs \
111-
-specs=nosys.specs -specs=rdimon.specs -o $(OUTPUT_DIR)/$(IMAGE)
112-
$(SIZE) $(OUTPUT_DIR)/$(IMAGE)
111+
-specs=nosys.specs -specs=rdimon.specs -o $(IMAGE)
112+
$(SIZE) $(IMAGE)
113113

114114
$(DEP_OUTPUT):
115115
include $(wildcard $(DEP_OUTPUT))
116116

117117
clean:
118-
rm -f $(OUTPUT_DIR)/$(IMAGE) $(OUTPUT_DIR)/*.o $(OUTPUT_DIR)/*.d
118+
rm -f $(IMAGE) $(OUTPUT_DIR)/RTOSDemo.map $(OUTPUT_DIR)/*.o $(OUTPUT_DIR)/*.d
119119

120120
#use "make print-[VARIABLE_NAME] to print the value of a variable generated by
121121
#this makefile.

0 commit comments

Comments
 (0)