Fix badge, add missing test makefile

This commit is contained in:
2016-03-27 12:19:45 -07:00
parent 50796e391c
commit d9a31feaa5
2 changed files with 19 additions and 2 deletions

18
tests/Makefile Normal file
View File

@@ -0,0 +1,18 @@
%.o: %.c
gcc -I../src -ansi -Wall -Werror -c -o $@ $<
for file in $$(cat $$(echo $@ | sed 's/\.o$$//').deps); do \
gcc -I../src -ansi -Wall -Werror -c -o ./$${file}.o ../src/$$file.c ; \
done
%.elf: %.o
gcc -o $@ $^ $$(cat $$(echo $@ | sed 's/\.elf$$//').deps | sed 's/$$/\.o/g')
all_targets:=$(shell ls *c | sed 's/\.c$$/\.elf/g')
all: $(all_targets)
.PHONY: clean
clean:
rm -f *o
rm -f *elf