.ONESHELL:
.SHELLFLAGS := -ec
+
+PACKAGE := misma
PREFIX ?= /usr/local
INSTALL ?= install
MKDIR_P := mkdir -p
CHMOD := chmod
GROFF := groff
B := build
-all := misma misma.8
+all := $(PACKAGE) $(PACKAGE).8
all: $(all)
-PACKAGE := misma
SLOGAN := the minimal snapshot manager
AUTHOR := Andre Noll
EMAIL := maan@tuebingen.mpg.de
LICENSE_URL := https://www.gnu.org/licenses/gpl-3.0-standalone.html
LOGLEVELS := LL_DEBUG,LL_INFO,LL_NOTICE,LL_WARNING,LL_ERROR,LL_CRIT,LL_EMERG
-units := misma util version misma.lsg
+units := $(PACKAGE) $(PACKAGE).lsg util version
deps := $(addprefix $(B)/, $(addsuffix .d, $(units)))
objs := $(addprefix $(B)/, $(addsuffix .o, $(units)))
CC_CMD = $(CC) -c -o $@ $(XCPPFLAGS) $(CPPFLAGS) \
$(XCFLAGS) $(CFLAGS) -MMD -MF $(B)/$(*F).d -MT $@
-$(objs): misma.h $(B)/misma.lsg.h Makefile
+$(objs): $(PACKAGE).h $(B)/$(PACKAGE).lsg.h Makefile
$(B):
@$(MKDIR_P) $@
$(M4_CMD) -D MODE=svg $< > $@
$(B)/index.html: index.html.m4 Makefile
$(M4_CMD) $< > $@
-$(B)/misma.suite: misma.suite.m4 Makefile
+$(B)/$(PACKAGE).suite: $(PACKAGE).suite.m4 Makefile
$(M4_CMD) $< > $@
$(B)/%.lsg.c: $(B)/%.suite
$(call SAY, LSGC $<)
endif
install install-strip: all
$(MKDIR_P) $(DESTDIR)$(sbindir) $(DESTDIR)$(mandir)
- $(INSTALL_PROGRAM) $(strip_option) misma $(DESTDIR)$(sbindir)
- $(INSTALL_DATA) misma.8 $(DESTDIR)$(mandir)
+ $(INSTALL_PROGRAM) $(strip_option) $(PACKAGE) $(DESTDIR)$(sbindir)
+ $(INSTALL_DATA) $(PACKAGE).8 $(DESTDIR)$(mandir)
clean:
$(RM) $(B)/*.o $(all)
Documentation
~~~~~~~~~~~~~
-See misma.suite.m4. Or build the man page with \"make\" and run
-\"man -l misma.8\".
+See $(PACKAGE).suite.m4. Or build the man page with \"make\" and run
+\"man -l $(PACKAGE).8\".
Dependencies
~~~~~~~~~~~~