diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..10e7c66 --- /dev/null +++ b/Makefile @@ -0,0 +1,17 @@ +CC=tcc +SRC=src +OBJ=obj +SOURCES=$(wildcard $(SRC)/*.c) +OBJECTS=$(patsubst $(SRC)/%.c, $(OBJ)/%.o, $(SOURCES)) +BIN=main + + +$(BIN): $(OBJECTS) + $(CC) $(OBJECTS) -o $(BIN) + +$(OBJ)/%.o: $(SRC)/%.c + $(CC) -c $< -o $@ + +clean: + rm -r $(BIN) $(OBJ)/*.o + |