kexec-tools/kdump-anaconda-addon/Makefile
Arthur Zou 5669f6bbe0 Add a anaconda addon to configurate kdump in the system installation process
Currently this work is done by firstboot. Now we move to anaconda addon
to configurate in the system installation process.

Signed-off-by: Arthur Zou <zzou@redhat.com>
Acked-by: Dave Young <dyoung@redhat.com>
2014-05-20 16:05:54 +08:00

82 lines
1.7 KiB
Makefile

NAME = kdump-anaconda-addon
VERSION = 0.1
ADDON = com_redhat_kdump
TESTS = test
FILES = $(ADDON) \
po \
Makefile \
README
EXCLUDES = \
*~ \
*.pyc
all:
@echo "usage: make dist"
@echo " make test"
@echo " make install"
@echo " make uninstall"
DISTNAME = $(NAME)-$(VERSION)
ADDONDIR = /usr/share/anaconda/addons/
DISTBALL = $(DISTNAME).tar.gz
NUM_PROCS = $$(getconf _NPROCESSORS_ONLN)
install:
mkdir -p $(DESTDIR)$(ADDONDIR)
cp -rv $(ADDON) $(DESTDIR)$(ADDONDIR)
make install-po-files
uninstall:
rm -rfv $(DESTDIR)$(ADDONDIR)
dist:
rm -rf $(DISTNAME)
mkdir -p $(DISTNAME)
@if test -d ".git"; \
then \
echo Creating ChangeLog && \
( cd "$(top_srcdir)" && \
echo '# Generate automatically. Do not edit.'; echo; \
git log --stat --date=short ) > ChangeLog.tmp \
&& mv -f ChangeLog.tmp $(DISTNAME)/ChangeLog \
|| ( rm -f ChangeLog.tmp ; \
echo Failed to generate ChangeLog >&2 ); \
else \
echo A git clone is required to generate a ChangeLog >&2; \
fi
for file in $(FILES); do \
cp -rpv $$file $(DISTNAME)/$$file; \
done
for excl in $(EXCLUDES); do \
find $(DISTNAME) -name "$$excl" -delete; \
done
tar -czvf ../$(DISTBALL) $(DISTNAME)
rm -rf $(DISTNAME)
potfile:
$(MAKE) DESTDIR=$(DESTDIR) -C po potfile
po-pull:
tx pull -a --disable-overwrite
install-po-files:
$(MAKE) -C po install
test:
@echo "***Running pylint checks***"
@find . -name '*.py' -print|xargs -n1 --max-procs=$(NUM_PROCS) pylint -E 2> /dev/null
@echo "[ OK ]"
@echo "***Running unittests checks***"
@PYTHONPATH=. nosetests --processes=-1 -vw tests/
runpylint:
@find . -name '*.py' -print|xargs -n1 --max-procs=$(NUM_PROCS) pylint -E 2> /dev/null
@echo "[ OK ]"
unittest:
PYTHONPATH=. nosetests --processes=-1 -vw tests/