makefile 929 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. LIB=/usr/lib/upas
  2. CFLAGS=${UNIX} -g -I. -I../libc -I../common -I/usr/include -I/usr/include/sys
  3. LFLAGS=-g
  4. HOSTNAME=cat /etc/whoami
  5. .c.o: ; $(CC) -c $(CFLAGS) $*.c
  6. all: mail
  7. sedfile:
  8. echo 's+LIBDIR+$(LIB)+g' >sed.file
  9. echo 's+HOSTNAME+$(HOSTNAME)+g' >>sed.file
  10. install: sedfile install.fish install.mail.sh
  11. install.fish:
  12. cp gone.msg $(LIB)
  13. sed -f sed.file gone.fishing >$(LIB)/gone.fishing
  14. -chmod 775 $(LIB)/gone.fishing
  15. -chown bin $(LIB)/gone.fishing $(LIB)/gone.msg
  16. install.mail.sh:
  17. sed -f sed.file mail.sh >/bin/mail
  18. -chown bin /bin/mail
  19. -chmod 775 /bin/mail
  20. install.notify: notify
  21. cp notify $(LIB)/notify
  22. -chmod 775 $(LIB)/notify
  23. -chown bin $(LIB)/notify
  24. install.mail: mail
  25. cp mail /bin
  26. strip /bin/mail
  27. notify: notify.o
  28. cc $(LFLAGS) notify.o -o notify
  29. mail: mail.o ../config/config.o
  30. cc $(LFLAGS) mail.o ../config/config.o -o mail
  31. clean:
  32. -rm -f *.[oOa] core a.out *.sL notify
  33. -rm -f sed.file mail