comparison buildhtml.mk @ 155:5a882b5773c9

initial website.
author Emanuel Schuetze <emanuel@intevation.de>
date Wed, 30 Mar 2011 15:51:06 +0200
parents
children 67d395ac5509
comparison
equal deleted inserted replaced
-1:000000000000 155:5a882b5773c9
1 # Build html from m4 macrofiles
2 # $Id$
3 #
4 # (c)2005,2006 by Intevation GmbH
5 # Author(s): Sascha Wilde
6 #
7 # This is Free Software licensed under the GPL
8
9 # Preprocessor configuration
10 PP = m4
11 PPFLAGS = --prefix-builtins
12
13 # Build configuration
14 TARGETS = $(patsubst %.htm4,%.html,$(wildcard *.htm4)) change-history.html change-history-de.html
15 SUBDIRS =
16
17 # Installation configuration
18 INSTALL_DIR = /tmp/mapwoc-www
19 ADD_INST_TYPES = *.css *.php *.png
20 ADD_INST_DIRS = img
21
22 #USER=$(shell grep "svn+ssh://" .svn/entries | sed -e "s/.*svn+ssh:\/\///g" | sed -e "s/@.*//g" | head -1)
23
24 CURDIR=$(shell pwd)
25
26 .SUFFIXES: .html .htm4
27
28 .htm4.html:
29 $(PP) -DNO_LINK_FOR=$@ $(PPFLAGS) $< > $@
30
31 all: $(TARGETS) subdirs
32
33 $(TARGETS): template.m4 template_header.m4 \
34 header.m4 style.css
35
36 subdirs: $(SUBDIRS)
37 @for dir in $^ ; do \
38 $(MAKE) -C $$dir SUBDIRS="" ; \
39 done
40
41 online: all
42 echo "Going to put current contents online for www.mapwocp.org ..."
43 rsync -urvP --exclude='.svn' $(ADD_INST_TYPES) $(TARGETS) $(ADD_INST_DIRS) \
44 $(USER)@wald.intevation.org:/mapwoc/htdocs/
45
46 install: all
47 mkdir -p $(INSTALL_DIR) ;\
48 cp -uf $(TARGETS) $(INSTALL_DIR) ;\
49 cp -uf $(ADD_INST_TYPES) $(INSTALL_DIR)
50 cp -urf *$(ADD_INST_DIRS) $(INSTALL_DIR)
51 find $(INSTALL_DIR) -name ".svn" | xargs rm -rf
52
53 tar: install
54 echo $(CURDIR)
55 ( cd $(INSTALL_DIR) ; tar -czv -f $(CURDIR)/www.mapwoc.org.tar.gz . )
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)