Missing then keyword.
[genkernel.git] / Makefile
1 PACKAGE_VERSION = `/bin/fgrep GK_V= genkernel | sed "s/.*GK_V='\([^']\+\)'/\1/"`
2 distdir = genkernel-$(PACKAGE_VERSION)
3
4 # Add off-Git/generated files here that need to be shipped with releases
5 EXTRA_DIST = genkernel.8
6
7 genkernel.8: doc/genkernel.8.txt doc/asciidoc.conf Makefile genkernel
8         a2x --conf-file=doc/asciidoc.conf --attribute="genkernelversion=$(PACKAGE_VERSION)" \
9                  --format=manpage -D . "$<"
10
11 clean:
12         rm -f genkernel.8
13
14 check-git-repository:
15         git diff --quiet || { echo 'STOP, you have uncommitted changes in the working directory' ; false ; }
16         git diff --cached --quiet || { echo 'STOP, you have uncommitted changes in the index' ; false ; }
17
18 dist: check-git-repository genkernel.8
19         rm -Rf "$(distdir)" "$(distdir)".tar "$(distdir)".tar.bz2
20         mkdir "$(distdir)"
21         git ls-files -z | xargs -0 cp --no-dereference --parents --target-directory="$(distdir)" \
22                 $(EXTRA_DIST)
23         tar cf "$(distdir)".tar "$(distdir)"
24         bzip2 -9v "$(distdir)".tar
25         rm -Rf "$(distdir)"
26
27 .PHONY: clean check-git-repository dist