From 36492397289c08e34d2f6f80786b7ea5c3ac8617 Mon Sep 17 00:00:00 2001 From: c+1 Date: Wed, 3 May 2023 08:18:24 -0400 Subject: make --- Makefile | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/Makefile b/Makefile index e69de29..6ef7263 100644 --- a/Makefile +++ b/Makefile @@ -0,0 +1,20 @@ +exec = halk.out +sources = $(wildcard src/*.c) +objects = $(sources:.c=.o) +flags = -g + + +$(exec): $(objects) + clang $(objects) $(flags) -o $(exec) + +%.o: %.c include/%.h + clang -c $(flags) $< -o $@ + +install: + make + cp ./halk.out /usr/local/bin/halk + +clean: + -rm *.out + -rm *.o + -rm src/*.o -- cgit v1.2.3