Makefile 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. # ################################################################
  2. # Copyright (c) Facebook, Inc.
  3. # All rights reserved.
  4. #
  5. # This source code is licensed under both the BSD-style license (found in the
  6. # LICENSE file in the root directory of this source tree) and the GPLv2 (found
  7. # in the COPYING file in the root directory of this source tree).
  8. # You may select, at your option, one of the above-listed licenses.
  9. # ################################################################
  10. PRGDIR = ../../programs
  11. VOID = /dev/null
  12. export PATH := .:$(PATH)
  13. .PHONY: all
  14. #all: test-gzip-env
  15. all: test-helin-segv test-hufts test-keep test-list test-memcpy-abuse test-mixed
  16. all: test-null-suffix-clobber test-stdin test-trailing-nul test-unpack-invalid
  17. all: test-zdiff test-zgrep-context test-zgrep-f test-zgrep-signal test-znew-k test-z-suffix
  18. @echo Testing completed
  19. .PHONY: zstd
  20. zstd:
  21. $(MAKE) -C $(PRGDIR) zstd
  22. ln -sf $(PRGDIR)/zstd gzip
  23. @echo PATH=$(PATH)
  24. gzip --version
  25. .PHONY: clean
  26. clean:
  27. @$(MAKE) -C $(PRGDIR) $@ > $(VOID)
  28. @$(RM) *.trs *.log
  29. @echo Cleaning completed
  30. #------------------------------------------------------------------------------
  31. # validated only for Linux, macOS, Hurd and some BSD targets
  32. #------------------------------------------------------------------------------
  33. ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU FreeBSD DragonFly NetBSD))
  34. test-%: zstd
  35. @./test-driver.sh --test-name $* --log-file $*.log --trs-file $*.trs --expect-failure "no" --color-tests "yes" --enable-hard-errors "yes" ./$*.sh
  36. # || echo ignoring error
  37. endif