|
1 | 1 | # Simple Makefile for building examples. |
2 | | -# This will build the examples in the current directory by compiling in the |
| 2 | +# This will build the examples in the current directory by compiling in the |
3 | 3 | # full tskit source into each of the examples. This is *not* recommended for |
4 | 4 | # real projects! |
5 | 5 | # |
|
8 | 8 | # |
9 | 9 | # **Note**: This repo uses git submodules, and these must be checked out |
10 | 10 | # correctly for this makefile to work, e.g.: |
11 | | -# |
| 11 | +# |
12 | 12 | # $ git clone [email protected]:tskit-dev/tskit.git --recurse-submodules |
13 | | -# |
| 13 | +# |
14 | 14 | # See the documentation (https://tskit.readthedocs.io/en/stable/c-api.html) |
15 | | -# for more details on how to use the C API, and the tskit build examples |
16 | | -# repo (https://github.com/tskit-dev/tskit-build-examples) for examples |
| 15 | +# for more details on how to use the C API, and the tskit build examples |
| 16 | +# repo (https://github.com/tskit-dev/tskit-build-examples) for examples |
17 | 17 | # of how to set up a production-ready build with tskit. |
18 | 18 | # |
19 | 19 |
|
20 | 20 | CFLAGS=-I../ -I../subprojects/kastore |
21 | 21 | TSKIT_SOURCE=../tskit/*.c ../subprojects/kastore/kastore.c |
22 | 22 |
|
23 | | -all: tree_iteration haploid_wright_fisher tree_traversal |
| 23 | +all: tree_iteration haploid_wright_fisher tree_traversal streaming |
| 24 | + |
| 25 | +tree_iteration: tree_iteration.c |
| 26 | + ${CC} ${CFLAGS} -o $@ $< ${TSKIT_SOURCE} -lm |
24 | 27 |
|
25 | | -tree_iteration: tree_iteration.c |
| 28 | +tree_traversal: tree_traversal.c |
26 | 29 | ${CC} ${CFLAGS} -o $@ $< ${TSKIT_SOURCE} -lm |
27 | 30 |
|
28 | | -tree_traversal: tree_traversal.c |
| 31 | +streaming: streaming.c |
29 | 32 | ${CC} ${CFLAGS} -o $@ $< ${TSKIT_SOURCE} -lm |
30 | 33 |
|
31 | 34 | # This needs GSL |
32 | | -haploid_wright_fisher: haploid_wright_fisher.c |
| 35 | +haploid_wright_fisher: haploid_wright_fisher.c |
33 | 36 | ${CC} ${CFLAGS} -o $@ $< ${TSKIT_SOURCE} -lgsl -lgslcblas -lm |
34 | 37 |
|
35 | 38 | clean: |
|
0 commit comments