#################################################################### # Distribution Makefile #################################################################### .PHONY: configure install clean all: configure # # BTDIR needs to point to the location of the build tools # BTDIR := ../../quattor-build-tools # # _btincl := $(shell ls $(BTDIR)/quattor-buildtools.mk 2>/dev/null || \ echo quattor-buildtools.mk) include $(_btincl) LIBFILES = html2pan html2updates post-process rpmcheck rpmProvides rpmq2pan_pkg\ rpmRequires AUXFILES = comps2pan-alt.xsl comps2pan.xsl lld2pkgs.xsl #################################################################### # Configure #################################################################### configure: $(COMP) $(addsuffix .pl,$(LIBFILES)) $(AUXFILES) #################################################################### # Install #################################################################### install: configure man @echo installing ... @mkdir -p $(PREFIX)/$(QTTR_PERLLIB)/$(COMP) @mkdir -p $(PREFIX)/$(QTTR_MAN)/man$(MANSECT) @mkdir -p $(PREFIX)/$(QTTR_DOC) @for i in $(LIBFILES) ; do \ install -m 0755 $$i.pl \ $(PREFIX)/$(QTTR_PERLLIB)/$(COMP)/$$i.pl ; \ done @for i in $(AUXFILES) ; do \ install -m 0444 $$i \ $(PREFIX)/$(QTTR_PERLLIB)/$(COMP)/$$i ; \ done @for i in LICENSE MAINTAINER ChangeLog README* ; do \ install -m 0444 $$i $(PREFIX)/$(QTTR_DOC)/$$i ; \ done @install -m 0444 $(COMP).$(MANSECT).gz \ $(PREFIX)$(QTTR_MAN)/man$(MANSECT)/$(COMP).$(MANSECT).gz man: configure @pod2man $(_podopt) $(COMP) >$(COMP).$(MANSECT) @gzip -f $(COMP).$(MANSECT) #################################################################### clean:: @echo cleaning $(COMP) files ... @rm -f $(COMP) $(COMP).$(MANSECT)* @rm -rf TEST