diff options
| author | Mattias Andrée <maandree@kth.se> | 2016-03-12 23:07:37 +0100 |
|---|---|---|
| committer | Mattias Andrée <maandree@kth.se> | 2016-03-12 23:07:37 +0100 |
| commit | a035fc10768bf48d096a33d0748e679e5a3e2540 (patch) | |
| tree | c31f6b4433c3a4713f47f32a295380e40c34f7a3 /Makefile | |
| parent | 64 bits (severely) outshines 16 bits and 8 bits in performance: do some cleanup (diff) | |
| download | libzahl-a035fc10768bf48d096a33d0748e679e5a3e2540.tar.gz libzahl-a035fc10768bf48d096a33d0748e679e5a3e2540.tar.bz2 libzahl-a035fc10768bf48d096a33d0748e679e5a3e2540.tar.xz | |
Add possibility to compare against libtommath
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to 'Makefile')
| -rw-r--r-- | Makefile | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -82,8 +82,16 @@ test-random.c: test-generate.py test: test.c libzahl.a test-random.c $(CC) $(LDFLAGS) $(CFLAGS) $(CPPFLAGS) -o $@ test.c libzahl.a +ifndef BENCHMARK_LIB benchmark: bench/benchmark.c libzahl.a $(CC) $(LDFLAGS) $(CFLAGS) $(CPPFLAGS) -o $@ $^ +endif +ifdef BENCHMARK_LIB +CPPFLAGS += -DBENCHMARK_LIB='"$(BENCHMARK_LIB).h"' +BENCHMARK_libtommath = -ltommath +benchmark: bench/benchmark.c bench/$(BENCHMARK_LIB).h + $(CC) $(LDFLAGS) $(CFLAGS) $(CPPFLAGS) -o $@ bench/benchmark.c $(BENCHMARK_$(BENCHMARK_LIB)) +endif check: test ./test |
