|
@@ -28,22 +28,22 @@ OBJ = $(addprefix $(BUILDDIR)/, $(SRC:.c=.o))
|
28
|
28
|
CARGS = -mmcu=$(MCU)
|
29
|
29
|
CARGS += -I$(EXTRAINCDIR)
|
30
|
30
|
CARGS += -Os
|
31
|
|
-CARGS += -funsigned-char
|
32
|
|
-CARGS += -funsigned-bitfields
|
33
|
|
-CARGS += -fpack-struct
|
34
|
|
-CARGS += -fshort-enums
|
|
31
|
+#CARGS += -funsigned-char
|
|
32
|
+#CARGS += -funsigned-bitfields
|
|
33
|
+#CARGS += -fpack-struct
|
|
34
|
+#CARGS += -fshort-enums
|
35
|
35
|
CARGS += -Wall -pedantic -Wstrict-prototypes -Wshadow
|
36
|
36
|
CARGS += -Wpointer-arith -Wcast-qual -Wextra
|
37
|
37
|
CARGS += -Wno-main -Wno-write-strings -Wno-unused-parameter
|
38
|
38
|
CARGS += -std=$(CSTANDARD)
|
39
|
39
|
CARGS += -DF_CPU=$(F_CPU)
|
40
|
|
-CARGS += -ffunction-sections
|
|
40
|
+#CARGS += -ffunction-sections
|
41
|
41
|
|
42
|
42
|
ifeq ($(DEBUG),1)
|
43
|
43
|
CARGS += -DDEBUG
|
44
|
44
|
endif
|
45
|
45
|
|
46
|
|
-LINKER = -Wl,--relax
|
|
46
|
+#LINKER = -Wl,--relax
|
47
|
47
|
|
48
|
48
|
PROGRAMMER = avrisp2
|
49
|
49
|
ISPPORT = usb
|
|
@@ -72,7 +72,7 @@ program: $(BUILDDIR)/$(TARGET).hex
|
72
|
72
|
$(AVRDUDE) -p $(MCU) -c $(PROGRAMMER) -b $(ISPBAUD) -P $(ISPPORT) -e -D -U $(BUILDDIR)/$(TARGET).hex
|
73
|
73
|
|
74
|
74
|
debugProgram:
|
75
|
|
- $(MAKE) BUILDDIR=build/debug TARGET=debug MCU=atmega328p DEBUG=1 PROGRAMMER=arduino ISPPORT=/dev/tty.usbserial-A100OZQ1 program
|
|
75
|
+ $(MAKE) BUILDDIR=build/debug TARGET=debug MCU=atmega328p DEBUG=1 program
|
76
|
76
|
|
77
|
77
|
clean:
|
78
|
78
|
$(RM) $(BUILDDIR)
|