aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authortslil clingman <tslil@posteo.de>2021-01-17 21:06:04 -0500
committertslil <tslil@posteo.de>2026-08-28 19:37:41 +0100
commit8915093ce1ed103cc52481118e1ab47bec663236 (patch)
tree31364afb829258d83688e95e02b17fbcda0cf918 /Makefile
parente2530bfb517b7a0dc0a9d3b6c7e3d074258b1405 (diff)
Revert "Starting work on MCU port"
This reverts commit 43eec01361eb6174142180c29afef960e041514e.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile47
1 files changed, 3 insertions, 44 deletions
diff --git a/Makefile b/Makefile
index 6814aee..1dfb930 100644
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,4 @@
IDIR=include
-
-# -------------------------------------------------------------------
-# Computer stuff
TPDIR=3rd-party
DEFINES=-DDETERMINISTIC
CFLAGS=-O3 -Wall -Wextra -std=c99 -D_DEFAULT_SOURCE $(DEFINES) -I$(IDIR) -I$(TPDIR)
@@ -14,27 +11,6 @@ PROG=ctaklm
STAT=pptdb
SIZE=size
-# -------------------------------------------------------------------
-# MCU stuff
-MCU=atmega32u4
-F_CPU=20000000UL
-ACC=avr-gcc
-ACFLAGS=-Os -Wall -fpack-struct -fshort-enums -funsigned-bitfields -funsigned-char -I$(IDIR)
-AOBJCOPY=avr-objcopy
-AOBJSIZE=avr-size
-
-AVRDUDE=avrdude
-ADFLAGS=-p $(MCU) -c avr109 -b 57600 -P /dev/serial/by-id/usb-Arduino_LLC_Arduino_Micro-if00
-
-TARGET=mcu
-AHEX=$(TARGET).hex
-ASRC=src/$(TARGET).c $(wildcard include/*.c)
-AOBJ=$(patsubst %.c, %.o, $(ASRC))
-AASM=$(patsubst %.c, %.s, $(ASRC))
-
-# -------------------------------------------------------------------
-# Targets
-
%.o: %.c
cc -c $< -o $@ $(CFLAGS)
@@ -45,25 +21,8 @@ $(PROG): src/$(PROG).o $(OBJS)
$(STAT): src/$(STAT).o $(OBJS)
$(CC) $(CFLAGS) src/$(STAT).o $(OBJS) -o $(STAT)
-avr: $(AHEX) $(AASM) ASUMMARY upload
-
-$(AHEX): $(AOBJ)
- $(AOBJCOPY) -S -j .text -j .data -O ihex $< $@
-
-$(AOBJ): $(ASRC)
- $(ACC) $(ACFLAGS) -DF_CPU=$(F_CPU) -mmcu=$(MCU) $(ASRC) -o $@
-
-%.s: %.c
- $(ACC) -S $(ACFLAGS) -DF_CPU=$(F_CPU) -mmcu=$(MCU) $< -o $@
-
-ASUMMARY: $(AOBJ)
- @echo ----------------------------------------------------------------------
- @$(AOBJSIZE) $(AOBJ) $(AHEX)
-
-upload: $(TARGET).hex
- $(AVRDUDE) $(ADFLAGS) -D -U flash:w:$<:i
-
clean:
- rm -f $(PROG) $(STAT) $(OBJS)
- rm -f $(AOBJ) $(AHEX) $(AASM)
+ rm -f $(PROG)
+ rm -f $(STAT)
rm -f src/*.o
+ rm -f $(OBJS)