Nie możesz wybrać więcej, niż 25 tematów Tematy muszą się zaczynać od litery lub cyfry, mogą zawierać myślniki ('-') i mogą mieć do 35 znaków.

Makefile 2.0 KiB

9 lat temu
9 lat temu
9 lat temu
7 lat temu
7 lat temu
7 lat temu
7 lat temu
7 lat temu
7 lat temu
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. CC = /usr/bin/gcc
  2. CFLAGS = -Wall -g -O3 -Wextra -Wpedantic
  3. LDLIBS = -lcrypto
  4. SOURCES = params.c hash.c fips202.c hash_address.c randombytes.c wots.c xmss.c xmss_core.c xmss_commons.c
  5. HEADERS = params.h hash.h fips202.h hash_address.h randombytes.h wots.h xmss.h xmss_core.h xmss_commons.h
  6. SOURCES_FAST = $(subst xmss_core.c,xmss_core_fast.c,$(SOURCES))
  7. HEADERS_FAST = $(subst xmss_core.c,xmss_core_fast.c,$(HEADERS))
  8. TESTS = test/wots \
  9. test/xmss_determinism \
  10. test/xmss \
  11. test/xmss_fast \
  12. test/xmssmt \
  13. test/xmssmt_fast \
  14. UI = ui/xmss_keypair \
  15. ui/xmss_sign \
  16. ui/xmss_open \
  17. ui/xmssmt_keypair \
  18. ui/xmssmt_sign \
  19. ui/xmssmt_open \
  20. ui/xmss_keypair_fast \
  21. ui/xmss_sign_fast \
  22. ui/xmss_open_fast \
  23. ui/xmssmt_keypair_fast \
  24. ui/xmssmt_sign_fast \
  25. ui/xmssmt_open_fast \
  26. all: tests ui
  27. tests: $(TESTS)
  28. ui: $(UI)
  29. test: $(TESTS:=.exec)
  30. .PHONY: clean test
  31. test/%.exec: test/%
  32. @$<
  33. test/xmss_fast: test/xmss.c $(SOURCES_FAST) $(OBJS) $(HEADERS_FAST)
  34. $(CC) -DXMSS_SIGNATURES=1024 $(CFLAGS) -o $@ $(SOURCES_FAST) $< $(LDLIBS)
  35. test/xmss: test/xmss.c $(SOURCES) $(OBJS) $(HEADERS)
  36. $(CC) $(CFLAGS) -o $@ $(SOURCES) $< $(LDLIBS)
  37. test/xmssmt_fast: test/xmss.c $(SOURCES_FAST) $(OBJS) $(HEADERS_FAST)
  38. $(CC) -DXMSSMT -DXMSS_SIGNATURES=1024 $(CFLAGS) -o $@ $(SOURCES_FAST) $< $(LDLIBS)
  39. test/xmssmt: test/xmss.c $(SOURCES) $(OBJS) $(HEADERS)
  40. $(CC) -DXMSSMT $(CFLAGS) -o $@ $(SOURCES) $< $(LDLIBS)
  41. test/%: test/%.c $(SOURCES) $(OBJS) $(HEADERS)
  42. $(CC) $(CFLAGS) -o $@ $(SOURCES) $< $(LDLIBS)
  43. ui/xmss_%_fast: ui/%.c $(SOURCES_FAST) $(OBJS) $(HEADERS_FAST)
  44. $(CC) $(CFLAGS) -o $@ $(SOURCES_FAST) $< $(LDLIBS)
  45. ui/xmssmt_%_fast: ui/%.c $(SOURCES_FAST) $(OBJS) $(HEADERS_FAST)
  46. $(CC) -DXMSSMT $(CFLAGS) -o $@ $(SOURCES_FAST) $< $(LDLIBS)
  47. ui/xmss_%: ui/%.c $(SOURCES) $(OBJS) $(HEADERS)
  48. $(CC) $(CFLAGS) -o $@ $(SOURCES) $< $(LDLIBS)
  49. ui/xmssmt_%: ui/%.c $(SOURCES) $(OBJS) $(HEADERS)
  50. $(CC) -DXMSSMT $(CFLAGS) -o $@ $(SOURCES) $< $(LDLIBS)
  51. clean:
  52. -$(RM) $(TESTS)
  53. -$(RM) $(UI)