You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

36 lines
1.0KB

  1. .POSIX:
  2. .SUFFIXES:
  3. meli:
  4. cargo build $(FEATURES)--release
  5. PREFIX ?= /usr/local
  6. ifdef MELI_FEATURES
  7. FEATURES ?= --features="$(MELI_FEATURES)"
  8. else
  9. FEATURES ?=
  10. endif
  11. .PHONY: clean
  12. clean:
  13. rm -r ./target/
  14. .PHONY: uninstall
  15. uninstall:
  16. rm -f $(DESTDIR)$(PREFIX)/bin/meli
  17. rm $(DESTDIR)$(PREFIX)/share/man/man1/meli.1.gz
  18. rm $(DESTDIR)$(PREFIX)/share/man/man5/meli.conf.5.gz
  19. .PHONY: install
  20. install: meli
  21. mkdir -p $(DESTDIR)$(PREFIX)/bin
  22. mkdir -p $(DESTDIR)$(PREFIX)/share/man/man1
  23. mkdir -p $(DESTDIR)$(PREFIX)/share/man/man5
  24. cp -f target/release/meli $(DESTDIR)$(PREFIX)/bin
  25. gzip < meli.1 > $(DESTDIR)$(PREFIX)/share/man/man1/meli.1.gz
  26. gzip < meli.conf.5 > $(DESTDIR)$(PREFIX)/share/man/man5/meli.conf.5.gz
  27. @echo "\n You might want to read the \"STARTING WITH meli\" section in the manpage (\`man meli\`)"
  28. @echo " - Report bugs in the mailing list or git issue tracker https://git.meli.delivery"
  29. @echo " - If you have a specific feature or workflow you want to use, you can post in the mailing list or git issue tracker."