summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xMakefile22
-rwxr-xr-xdocs/Makefile7
-rwxr-xr-xfunc/Makefile19
3 files changed, 40 insertions, 8 deletions
diff --git a/Makefile b/Makefile
index 928adeb..2837eac 100755
--- a/Makefile
+++ b/Makefile
@@ -4,6 +4,9 @@ NEWRELEASE = $(shell echo $$(($(RELEASE) + 1)))
MESSAGESPOT=po/messages.pot
+DIRS = modules minion overlord func docs
+PYDIRS = modules minion overlord func
+
all: rpms
clean:
@@ -12,6 +15,7 @@ clean:
-rm -rf *~
-rm -rf rpm-build/
-rm -rf docs/*.gz
+ -for d in $(DIRS); do ($(MAKE) -C $$d clean ); done
clean_hard:
-rm -rf $(shell python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")/func
@@ -21,8 +25,7 @@ clean_harder:
-rm -rf /etc/func
-rm -rf /var/lib/func
-clean_hardest:
- -rpm -e func
+clean_hardest: clean_rpms
manpage:
pod2man --center="funcd" --release="" ./docs/funcd.pod | gzip -c > ./docs/funcd.1.gz
@@ -50,26 +53,29 @@ install_hard: clean_hard install
install_harder: clean_harder install
+install_hardest: clean_harder clean_rpms rpms install_rpm restart
+
+install_rpm:
+ -rpm -Uvh rpm-build/func-$(VERSION)-$(RELEASE)$(shell rpm -E "%{?dist}").noarch.rpm
+
restart:
-/etc/init.d/certmaster restart
-/etc/init.d/funcd restart
-
recombuild: install_harder restart
clean_rpms:
-rpm -e func
-install_rpm:
- -rpm -Uvh rpm-build/func-$(VERSION)-$(RELEASE)$(shell rpm -E "%{?dist}").noarch.rpm
-
-install_hardest: clean_harder clean_rpms rpms install_rpm restart
-
sdist: messages
python setup.py sdist
new-rpms: bumprelease rpms
+pychecker:
+ -for d in $(PYDIRS); do ($(MAKE) -C $$d pychecker ); done
+pyflakes:
+ -for d in $(PYDIRS); do ($(MAKE) -C $$d pyflakes ); done
rpms: build manpage sdist
mkdir -p rpm-build
diff --git a/docs/Makefile b/docs/Makefile
new file mode 100755
index 0000000..ede53b5
--- /dev/null
+++ b/docs/Makefile
@@ -0,0 +1,7 @@
+
+
+clean::
+ @rm -fv *.pyc *~ .*~ *.pyo
+ @find . -name .\#\* -exec rm -fv {} \;
+ @rm -fv *.rpm
+ @rm -fv *.gz
diff --git a/func/Makefile b/func/Makefile
new file mode 100755
index 0000000..86a3db8
--- /dev/null
+++ b/func/Makefile
@@ -0,0 +1,19 @@
+
+
+PYFILES = $(wildcard *.py)
+
+PYCHECKER = /usr/bin/pychecker
+PYFLAKES = /usr/bin/pyflakes
+
+clean::
+ @rm -fv *.pyc *~ .*~ *.pyo
+ @find . -name .\#\* -exec rm -fv {} \;
+ @rm -fv *.rpm
+
+
+pychecker::
+ @$(PYCHECKER) $(PYFILES) || exit 0
+
+pyflakes::
+ @$(PYFLAKES) $(PYFILES) || exit 0
+