TP8
This commit is contained in:
parent
45f6092d0d
commit
04bb2bec3a
12 changed files with 313 additions and 0 deletions
27
TP8/Makefile
Normal file
27
TP8/Makefile
Normal file
|
@ -0,0 +1,27 @@
|
|||
all: main pdfs dots
|
||||
|
||||
main: main.c libtrees.a
|
||||
gcc $^ -o $@
|
||||
|
||||
part2: part2.c libtrees.a
|
||||
gcc $^ -o $@
|
||||
|
||||
%.o: %.c
|
||||
gcc -c $^ -o $@
|
||||
|
||||
lib%.a: %.o
|
||||
ar rcs $@ $^
|
||||
|
||||
pdfs: $(patsubst %.txt,%.pdf,$(shell ls samples/*.txt))
|
||||
dots: $(patsubst %.txt,%.dot,$(shell ls samples/*.txt))
|
||||
|
||||
samples/%.pdf: samples/%.dot
|
||||
dot -Tpdf $< -o $@
|
||||
|
||||
samples/%.dot: samples/%.txt part2
|
||||
./part2 $<
|
||||
|
||||
.PHONY: clean
|
||||
|
||||
clean:
|
||||
rm -r lib*.a *.o samples/*.dot samples/*.pdf
|
Reference in a new issue