You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Makefile.bench.include 2.3KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. # Copyright (c) 2015-2016 The Starwels developers
  2. # Distributed under the MIT software license, see the accompanying
  3. # file COPYING or http://www.opensource.org/licenses/mit-license.php.
  4. bin_PROGRAMS += bench/bench_starwels
  5. BENCH_SRCDIR = bench
  6. BENCH_BINARY = bench/bench_starwels$(EXEEXT)
  7. RAW_TEST_FILES = \
  8. bench/data/block413567.raw
  9. GENERATED_TEST_FILES = $(RAW_TEST_FILES:.raw=.raw.h)
  10. bench_bench_starwels_SOURCES = \
  11. bench/bench_starwels.cpp \
  12. bench/bench.cpp \
  13. bench/bench.h \
  14. bench/checkblock.cpp \
  15. bench/checkqueue.cpp \
  16. bench/Examples.cpp \
  17. bench/rollingbloom.cpp \
  18. bench/crypto_hash.cpp \
  19. bench/ccoins_caching.cpp \
  20. bench/mempool_eviction.cpp \
  21. bench/verify_script.cpp \
  22. bench/base58.cpp \
  23. bench/lockedpool.cpp \
  24. bench/perf.cpp \
  25. bench/perf.h \
  26. bench/prevector_destructor.cpp
  27. nodist_bench_bench_starwels_SOURCES = $(GENERATED_TEST_FILES)
  28. bench_bench_starwels_CPPFLAGS = $(AM_CPPFLAGS) $(STARWELS_INCLUDES) $(EVENT_CLFAGS) $(EVENT_PTHREADS_CFLAGS) -I$(builddir)/bench/
  29. bench_bench_starwels_CXXFLAGS = $(AM_CXXFLAGS) $(PIE_FLAGS)
  30. bench_bench_starwels_LDADD = \
  31. $(LIBSTARWELS_SERVER) \
  32. $(LIBSTARWELS_COMMON) \
  33. $(LIBSTARWELS_UTIL) \
  34. $(LIBSTARWELS_CONSENSUS) \
  35. $(LIBSTARWELS_CRYPTO) \
  36. $(LIBLEVELDB) \
  37. $(LIBLEVELDB_SSE42) \
  38. $(LIBMEMENV) \
  39. $(LIBSECP256K1) \
  40. $(LIBUNIVALUE)
  41. if ENABLE_ZMQ
  42. bench_bench_starwels_LDADD += $(LIBSTARWELS_ZMQ) $(ZMQ_LIBS)
  43. endif
  44. if ENABLE_WALLET
  45. bench_bench_starwels_SOURCES += bench/coin_selection.cpp
  46. bench_bench_starwels_LDADD += $(LIBSTARWELS_WALLET) $(LIBSTARWELS_CRYPTO)
  47. endif
  48. bench_bench_starwels_LDADD += $(BOOST_LIBS) $(BDB_LIBS) $(SSL_LIBS) $(CRYPTO_LIBS) $(MINIUPNPC_LIBS) $(EVENT_PTHREADS_LIBS) $(EVENT_LIBS)
  49. bench_bench_starwels_LDFLAGS = $(RELDFLAGS) $(AM_LDFLAGS) $(LIBTOOL_APP_LDFLAGS)
  50. CLEAN_STARWELS_BENCH = bench/*.gcda bench/*.gcno $(GENERATED_TEST_FILES)
  51. CLEANFILES += $(CLEAN_STARWELS_BENCH)
  52. bench/checkblock.cpp: bench/data/block413567.raw.h
  53. starwels_bench: $(BENCH_BINARY)
  54. bench: $(BENCH_BINARY) FORCE
  55. $(BENCH_BINARY)
  56. starwels_bench_clean : FORCE
  57. rm -f $(CLEAN_STARWELS_BENCH) $(bench_bench_starwels_OBJECTS) $(BENCH_BINARY)
  58. %.raw.h: %.raw
  59. @$(MKDIR_P) $(@D)
  60. @{ \
  61. echo "static unsigned const char $(*F)[] = {" && \
  62. $(HEXDUMP) -v -e '8/1 "0x%02x, "' -e '"\n"' $< | $(SED) -e 's/0x ,//g' && \
  63. echo "};"; \
  64. } > "$@.new" && mv -f "$@.new" "$@"
  65. @echo "Generated $@"