1
0
Fork 0
lesson-lisp/Makefile

28 lines
346 B
Makefile

all: test
CC = gcc
CFLAGS = -Wall -Wextra
OBJS = \
src/builtins.c.o \
src/ctype.c.o \
src/lexer.c.o \
src/main.c.o \
src/object.c.o \
src/parser.c.o \
src/tokens.c.o
repl: lisp
./lisp
test: lisp
./lisp --test
clean:
rm -f lisp $(OBJS)
lisp: $(OBJS)
$(CC) -o $@ $^ $(CFLAGS)
%.c.o: %.c
$(CC) -c $< -o $@ $(CFLAGS)