picrin/Makefile

23 lines
385 B
Makefile
Raw Normal View History

2013-10-19 14:05:42 -04:00
CC=gcc
2013-10-20 05:49:35 -04:00
all: build run
build: build-lib build-main
2013-10-09 04:10:58 -04:00
2013-10-20 05:44:26 -04:00
build-main:
2013-10-20 07:57:10 -04:00
$(CC) -Wall -o bin/picrin -I./include -L./lib -lpicrin -lreadline tools/main.c
2013-10-20 05:44:26 -04:00
build-lib:
2013-10-11 02:20:53 -04:00
cd src; \
yacc -d parse.y; \
lex scan.l
2013-10-20 08:06:53 -04:00
$(CC) -Wall -shared -o lib/libpicrin.so -I./include -lreadline src/*.c
2013-10-09 04:10:58 -04:00
2013-10-10 03:45:23 -04:00
clean:
2013-10-11 02:20:53 -04:00
rm -f src/y.tab.c src/y.tab.h src/lex.yy.c
2013-10-20 05:44:26 -04:00
rm -f lib/libpicrin.so
2013-10-11 02:20:53 -04:00
rm -f bin/picrin
2013-10-10 03:45:23 -04:00
2013-10-09 04:10:58 -04:00
run:
bin/picrin