summaryrefslogtreecommitdiffstats
path: root/linux/Makefile
diff options
context:
space:
mode:
authorLibravatar bigfoot547 <bigfoot@figboot.dev>2026-07-08 01:37:28 -0500
committerLibravatar bigfoot547 <bigfoot@figboot.dev>2026-07-08 01:37:28 -0500
commit766dee7f4292f82be19265544a59e1282e29e208 (patch)
tree650ed821b698cc7d5ad07ed51d5630334d4dd329 /linux/Makefile
parentbegin work on pc side (diff)
ignore the overengineered line splitting algorithmHEADmaster
Diffstat (limited to 'linux/Makefile')
-rw-r--r--linux/Makefile27
1 files changed, 27 insertions, 0 deletions
diff --git a/linux/Makefile b/linux/Makefile
new file mode 100644
index 0000000..45123bf
--- /dev/null
+++ b/linux/Makefile
@@ -0,0 +1,27 @@
+CC := gcc
+
+CFLAGS := -Wall -Wextra -Wpedantic -O0 -g -fsanitize=address
+LDFLAGS := -O0 -g -fsanitize=address
+
+BUILDDIR := build
+SOURCES := main.c util.c
+OBJS := $(SOURCES:%=$(BUILDDIR)/%.o)
+IMGNAME := exitest
+
+.PHONY: all
+all: $(BUILDDIR)/$(IMGNAME)
+
+$(BUILDDIR)/$(IMGNAME): $(OBJS)
+ $(CC) $(OBJS) -o $@ $(LDFLAGS)
+
+$(BUILDDIR)/%.c.o: %.c
+ $(CC) -c $(CFLAGS) $< -o $@
+
+$(OBJS): | $(BUILDDIR)
+
+$(BUILDDIR):
+ mkdir $(BUILDDIR)
+
+.PHONY: clean
+clean:
+ -rm -rvf $(BUILDDIR)