From: Manfred Steiner Date: Thu, 7 Nov 2024 17:04:01 +0000 (+0100) Subject: Projektvorlagen VSCode/AVR/Level-1: Makefiles geändert (Fix UART FDEV_SETUP_STREAM... X-Git-Url: https://git.htl-mechatronik.at/public/?a=commitdiff_plain;h=0a74126b8b608aea2ca1d6683abf94e78127205d;p=project-template.git Projektvorlagen VSCode/AVR/Level-1: Makefiles geändert (Fix UART FDEV_SETUP_STREAM Problem bei avr-g++) --- diff --git a/vscode-avr-c-cpp/arduino-nano-1/Makefile b/vscode-avr-c-cpp/arduino-nano-1/Makefile index 7e1fa9d..3a56c18 100644 --- a/vscode-avr-c-cpp/arduino-nano-1/Makefile +++ b/vscode-avr-c-cpp/arduino-nano-1/Makefile @@ -21,7 +21,8 @@ OBJ = $(OBJ_CPP:src/%.c=build/%.o) OBJ_SIM_CPP = $(SRC:src/%.cpp=sim/build/%.o) OBJ_SIM = $(OBJ_SIM_CPP:src/%.c=sim/build/%.o) -CC= avr-g++ +CCP= avr-g++ +CC= avr-gcc CFLAGS= -Wall -mmcu=$(DEVICE) -Os -DF_CPU=$(CPU_FREQUENCE) -c CFLAGS += @@ -90,7 +91,7 @@ build/%.o: src/%.c build/%.o: src/%.cpp @mkdir -p $(dir $@) - $(CC) $(CFLAGS) -o $@ $< + $(CCP) $(CFLAGS) -o $@ $< # -------------------------------------------------------------------------------- # simulation/debugging with gdb or simuc diff --git a/vscode-avr-c-cpp/nano-1284-1/Makefile b/vscode-avr-c-cpp/nano-1284-1/Makefile index e95febd..8a81127 100644 --- a/vscode-avr-c-cpp/nano-1284-1/Makefile +++ b/vscode-avr-c-cpp/nano-1284-1/Makefile @@ -21,7 +21,8 @@ OBJ = $(OBJ_CPP:src/%.c=build/%.o) OBJ_SIM_CPP = $(SRC:src/%.cpp=sim/build/%.o) OBJ_SIM = $(OBJ_SIM_CPP:src/%.c=sim/build/%.o) -CC= avr-g++ +CCP= avr-g++ +CC= avr-gcc CFLAGS= -Wall -mmcu=$(DEVICE) -Os -DF_CPU=$(CPU_FREQUENCE) -c CFLAGS += @@ -90,7 +91,7 @@ build/%.o: src/%.c build/%.o: src/%.cpp @mkdir -p $(dir $@) - $(CC) $(CFLAGS) -o $@ $< + $(CCP) $(CFLAGS) -o $@ $< # -------------------------------------------------------------------------------- # simulation/debugging with gdb or simuc diff --git a/vscode-avr-c-cpp/nano-644-1/Makefile b/vscode-avr-c-cpp/nano-644-1/Makefile index 03912d7..a93c8d0 100644 --- a/vscode-avr-c-cpp/nano-644-1/Makefile +++ b/vscode-avr-c-cpp/nano-644-1/Makefile @@ -21,7 +21,8 @@ OBJ = $(OBJ_CPP:src/%.c=build/%.o) OBJ_SIM_CPP = $(SRC:src/%.cpp=sim/build/%.o) OBJ_SIM = $(OBJ_SIM_CPP:src/%.c=sim/build/%.o) -CC= avr-g++ +CCP= avr-g++ +CC= avr-gcc CFLAGS= -Wall -mmcu=$(DEVICE) -Os -DF_CPU=$(CPU_FREQUENCE) -c CFLAGS += @@ -90,7 +91,7 @@ build/%.o: src/%.c build/%.o: src/%.cpp @mkdir -p $(dir $@) - $(CC) $(CFLAGS) -o $@ $< + $(CCP) $(CFLAGS) -o $@ $< # -------------------------------------------------------------------------------- # simulation/debugging with gdb or simuc diff --git a/vscode-avr-c-cpp/sure-1/Makefile b/vscode-avr-c-cpp/sure-1/Makefile index cbde53e..fc7cfc5 100644 --- a/vscode-avr-c-cpp/sure-1/Makefile +++ b/vscode-avr-c-cpp/sure-1/Makefile @@ -21,7 +21,8 @@ OBJ = $(OBJ_CPP:src/%.c=build/%.o) OBJ_SIM_CPP = $(SRC:src/%.cpp=sim/build/%.o) OBJ_SIM = $(OBJ_SIM_CPP:src/%.c=sim/build/%.o) -CC= avr-g++ +CCP= avr-g++ +CC= avr-gcc CFLAGS= -Wall -mmcu=$(DEVICE) -Os -DF_CPU=$(CPU_FREQUENCE) -c CFLAGS += @@ -90,7 +91,7 @@ build/%.o: src/%.c build/%.o: src/%.cpp @mkdir -p $(dir $@) - $(CC) $(CFLAGS) -o $@ $< + $(CCP) $(CFLAGS) -o $@ $< # -------------------------------------------------------------------------------- # simulation/debugging with gdb or simuc