emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/systemd de5da7f 073/131: update Makefile


From: ELPA Syncer
Subject: [nongnu] elpa/systemd de5da7f 073/131: update Makefile
Date: Sun, 29 Aug 2021 11:35:17 -0400 (EDT)

branch: elpa/systemd
commit de5da7fce705ef9859e0e4ac7300d0a197bae1e8
Author: Mark Oteiza <mvoteiza@udel.edu>
Commit: Mark Oteiza <mvoteiza@udel.edu>

    update Makefile
---
 Makefile | 21 +++++++++++++++++++--
 1 file changed, 19 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index f2e7a88..ae96023 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,8 @@
-SRC = systemd.el systemd-company.el
+SRC = systemd.el
+DATA = unit-directives.txt network-directives.txt
+DISTFILES := Makefile $(SRC) $(DATA) LICENSE README systemd-pkg.el tests
+
+VERSION := $(shell awk '/^;; Version:/ {print $$3}' $(SRC))
 
 PREFIX = /usr/local
 datarootdir := $(PREFIX)/share
@@ -8,6 +12,12 @@ EMACS = emacs
 
 all: $(SRC:.el=.elc)
 
+systemd-pkg.el: $(SRC)
+       printf "(define-package \"systemd\" \"%s\" " $(VERSION) > $@
+       echo "\"Major mode for editing systemd units\")" >> $@
+
+systemd.elc: $(DATA)
+
 check: tests/systemd-tests.el systemd.elc
        @$(EMACS) -Q --batch -L . --eval "(progn \
                (load-file \"tests/systemd-tests.el\") \
@@ -16,11 +26,18 @@ check: tests/systemd-tests.el systemd.elc
 clean:
        $(RM) $(SRC:.el=.elc)
 
+dist: clean systemd-pkg.el
+       mkdir systemd-$(VERSION)
+       cp -r $(DISTFILES) systemd-$(VERSION)
+       tar cf systemd-$(VERSION).tar systemd-$(VERSION)
+       rm -rf systemd-$(VERSION)
+
 install:
        install -d $(DESTDIR)$(emacsdir)/systemd
        install -m644 $(SRC) $(SRC:.el=.elc) -t $(DESTDIR)$(emacsdir)/systemd
+       install -m644 $(DATA) -t $(DESTDIR)$(emacsdir)/systemd
 
 .el.elc:
        $(EMACS) -L . --batch -f batch-byte-compile $<
 
-.PHONY: all check clean install
+.PHONY: all check clean dist install



reply via email to

[Prev in Thread] Current Thread [Next in Thread]