Add Makefile

This commit is contained in:
2026-03-29 10:51:26 -04:00
parent 13d311fe28
commit a56b12899e

24
Makefile Normal file
View File

@@ -0,0 +1,24 @@
TARGET = main.elf
OBJS = main.o
LIBS = -lm
KOS_CFLAGS += -O2 -ffunction-sections -fdata-sections
KOS_LDFLAGS += -Wl,--gc-sections
all: rm-elf $(TARGET)
include $(KOS_BASE)/Makefile.rules
clean: rm-elf
-rm -f $(OBJS)
rm-elf:
-rm -f $(TARGET) romdisk.*
$(TARGET): $(OBJS)
kos-cc -o $(TARGET) $(OBJS) $(LIBS)
dist: $(TARGET)
$(KOS_STRIP) $(TARGET)
mkdcdisc -e $(TARGET) -o bad-apple.cdi -n "BAD APPLE" VIDEO.MPG