Fix group description processing
[banana.git] / Makefile
CommitLineData
4cc7f778 1# definitions
2
3VERSION=$(shell grep VERSION Changelog | head -1 | sed -e "s/VERSION //;s/\t.*//")
4PKG_DIST = banana-$(VERSION)
5
6PKG_FILES = AUTHORS Changelog COPYING README Makefile TODO
7
2a09fb07 8PKG_DIRS = banana po css examples img
4cc7f778 9
2a09fb07 10VCS_FILTER = ! -name .arch-ids ! -name .arch-inventory
4cc7f778 11
12# global targets
13
14build: pkg-build
15
16dist: clean pkg-dist
17
18clean:
19 rm -rf locale banana/include/banana.inc.php
40114245 20 make -C po clean
4cc7f778 21
22%: %.in Makefile
664e4b2b 23 sed -e 's,@VERSION@,$(VERSION) The Bearded Release,g' $< > $@
4cc7f778 24
25
26# banana package targets
27
605f785e 28pkg-build: banana/banana.inc.php
4cc7f778 29 make -C po
2a09fb07 30 make -C po clean
4cc7f778 31
32pkg-dist: pkg-build
33 rm -rf $(PKG_DIST) $(PKG_DIST).tar.gz
34 mkdir $(PKG_DIST)
35 cp -a $(PKG_FILES) $(PKG_DIST)
36 for dir in `find $(PKG_DIRS) -type d $(VCS_FILTER)`; \
37 do \
38 mkdir -p $(PKG_DIST)/$$dir; \
2a09fb07 39 find $$dir -type f $(VCS_FILTER) -maxdepth 1 -exec cp {} $(PKG_DIST)/$$dir \; ; \
4cc7f778 40 done
41 tar czf $(PKG_DIST).tar.gz $(PKG_DIST)
42 rm -rf $(PKG_DIST)
43
44
45
46.PHONY: build dist clean pkg-build pkg-dist lib-build lib-dist
47