Makefile 723 B

12345678910111213141516171819202122232425262728293031
  1. PROGRAMS=motds32
  2. CONFIGS=motds32.conf
  3. usage:
  4. @echo "This makefile allows you to:"
  5. @echo " o install MOTDstat"
  6. @echo " o unintall MOTDstat"
  7. @echo
  8. @echo Examples:
  9. @echo " make install"
  10. @echo " make uninstall"
  11. install:
  12. for prog in $(PROGRAMS); do \
  13. install -m 0755 bin/$$prog /usr/bin; \
  14. done
  15. if test ! -d /etc/motds32; then mkdir -p /etc/motds32; touch /etc/motds32/Stats32.txt; chmod 777 /etc/motds32/Stats32.txt; fi
  16. for config in $(CONFIGS); do \
  17. if test ! -e /etc/motds32/$$config; then install -m 644 ./etc/motds32/$$config /etc/motds32; fi \
  18. done
  19. uninstall:
  20. for prog in $(PROGRAMS); do \
  21. rm -f /usr/bin/$$prog; \
  22. done
  23. rm -rf /etc/motds32/ /etc/motd.full
  24. mv -f /etc/motd.orig /etc/motd