Makefile.in 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. all: conf build test etc dashboard dist
  2. conf: Makefile conf/substitutions.sed
  3. Makefile: Makefile.in conf/substitutions.sed conf/Makefile conf/substitutions.conf conf/substitute.sh
  4. conf/substitutions.sed: conf/Makefile conf/substitutions.conf
  5. conf/substitutions.conf:
  6. cd conf && ${MAKE}
  7. build: src/Makefile src/nodes2prom src/json-pp
  8. src/Makefile: src/Makefile.in
  9. conf/substitute.sh $> $@
  10. src/nodes2prom: src/Makefile
  11. cd src && ${MAKE} nodes2prom
  12. src/json-pp: src/Makefile
  13. cd src && ${MAKE} json-pp
  14. test: test/Makefile test/tmp
  15. test/Makefile: test/Makefile.in
  16. conf/substitute.sh $> $@
  17. test/tmp:
  18. cd test && ${MAKE} test
  19. etc: etc/Makefile etc/crontab etc/nodes2prometheus.sh
  20. etc/Makefile: etc/Makefile.in
  21. conf/substitute.sh $> $@
  22. etc/crontab:
  23. cd etc && ${MAKE}
  24. etc/nodes2prometheus.sh:
  25. cd etc && ${MAKE}
  26. dashboard: dashboard/Makefile dashboard/%%DASHBOARD_PREFIX%%status.json
  27. dashboard/Makefile: dashboard/Makefile.in
  28. conf/substitute.sh $> $@
  29. dashboard/%%DASHBOARD_PREFIX%%status.json:
  30. cd dashboard && ${MAKE}
  31. dist: dist/Makefile dist/nodes2grafana.txz
  32. dist/Makefile: dist/Makefile.in
  33. conf/substitute.sh $> $@
  34. dist/nodes2grafana.txz:
  35. cd dist && rm -f $@ && ${MAKE}
  36. install: install-bin install-crontab install-dashboard
  37. install-bin: src/nodes2prom src/json-pp etc/nodes2prometheus.sh
  38. %%INSTALL_BIN_CMD%% $> %%BIN_DIR%%
  39. install-crontab: etc/crontab
  40. grep nodes2prometheus.sh %%ETC_DIR%%/crontab > /tmp/crontab.old || \
  41. cat $> >> %%ETC_DIR%%/crontab
  42. -diff /tmp/crontab.old $>
  43. install-dashboard:
  44. cd dashboard && ${MAKE} install
  45. clean:
  46. cd conf && ${MAKE} clean
  47. [ ! -r test/Makefile ] || { cd test && ${MAKE} clean && rm -f Makefile ; }
  48. [ ! -r etc/Makefile ] || { cd etc && ${MAKE} clean && rm -f Makefile ; }
  49. [ ! -r src/Makefile ] || { cd src && ${MAKE} clean && rm -f Makefile ; }
  50. [ ! -r dashboard/Makefile ] || { cd dashboard && ${MAKE} clean && rm -f Makefile ; }
  51. [ ! -r dist/Makefile ] || { cd dist && ${MAKE} clean && rm -f Makefile ; }