15 lines
273 B
Makefile
15 lines
273 B
Makefile
CC=gcc
|
|
all: tests
|
|
shortcodes.c: shortcodes.rl
|
|
ragel -G2 shortcodes.rl -o shortcodes.c
|
|
%.o: %.c
|
|
$(CC) -fPIC -c -o $@ $^
|
|
tests.so: shortcodes.o tests.o
|
|
$(CC) -shared -o $@ $^ -lbg -lcgreen
|
|
test: tests.so
|
|
cgreen-runner $^
|
|
clean:
|
|
rm -f shortcodes.c *.o *.so
|
|
|
|
.PHONY: test
|