Makefile 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. -include ../../mconfig
  2. objects = tests.o test-dinit.o proctests.o loadtests.o envtests.o test-run-child-proc.o test-bpsys.o
  3. parent_objs = service.o proc-service.o dinit-log.o load-service.o baseproc-service.o dinit-env.o
  4. check: build-tests run-tests
  5. build-tests: tests proctests loadtests envtests
  6. $(MAKE) -C cptests build-tests
  7. run-tests: tests proctests loadtests envtests
  8. ./tests
  9. ./proctests
  10. ./loadtests
  11. ./envtests
  12. $(MAKE) -C cptests run-tests
  13. tests: $(parent_objs) tests.o test-dinit.o test-bpsys.o test-run-child-proc.o
  14. $(CXX) $(SANITIZEOPTS) -o tests $(parent_objs) tests.o test-dinit.o test-bpsys.o test-run-child-proc.o $(CXXOPTS) $(LDFLAGS)
  15. proctests: $(parent_objs) proctests.o test-dinit.o test-bpsys.o test-run-child-proc.o
  16. $(CXX) $(SANITIZEOPTS) -o proctests $(parent_objs) proctests.o test-dinit.o test-bpsys.o test-run-child-proc.o $(CXXOPTS) $(LDFLAGS)
  17. loadtests: $(parent_objs) loadtests.o test-dinit.o test-bpsys.o test-run-child-proc.o
  18. $(CXX) $(SANITIZEOPTS) -o loadtests $(parent_objs) loadtests.o test-dinit.o test-bpsys.o test-run-child-proc.o $(CXXOPTS) $(LDFLAGS)
  19. envtests: $(parent_objs) envtests.o test-dinit.o test-bpsys.o test-run-child-proc.o
  20. $(CXX) $(SANITIZEOPTS) -o envtests $(parent_objs) envtests.o test-dinit.o test-bpsys.o test-run-child-proc.o $(CXXOPTS) $(LDFLAGS)
  21. $(objects): %.o: %.cc
  22. $(CXX) $(CXXOPTS) $(SANITIZEOPTS) -MMD -MP -Iincludes -I../../dasynq/include -I../../build/includes -c $< -o $@
  23. $(parent_objs): %.o: ../%.cc
  24. $(CXX) $(CXXOPTS) $(SANITIZEOPTS) -MMD -MP -Iincludes -I../../dasynq/include -I../../build/includes -c $< -o $@
  25. clean:
  26. $(MAKE) -C cptests clean
  27. rm -f *.o *.d tests proctests loadtests envtests
  28. -include $(objects:.o=.d)
  29. -include $(parent_objs:.o=.d)