1 |
khruskowski |
2 |
# 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/gpg4kde-www |
19 |
|
|
ADD_INST_TYPES = *.css *.ico *.php |
20 |
|
|
ADD_INST_DIRS = pix |
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) $(PPFLAGS) $< > $@ |
30 |
|
|
|
31 |
|
|
all: $(TARGETS) subdirs |
32 |
|
|
|
33 |
|
|
$(TARGETS): template.m4 template_header.m4 \ |
34 |
|
|
template_link_boxes_de.m4 template_link_boxes_en.m4 \ |
35 |
|
|
gpg4kde.css |
36 |
|
|
|
37 |
|
|
subdirs: $(SUBDIRS) |
38 |
|
|
@for dir in $^ ; do \ |
39 |
|
|
$(MAKE) -C $$dir SUBDIRS="" ; \ |
40 |
|
|
done |
41 |
|
|
|
42 |
|
|
change-history.htm4: build-history.awk NEWS.last |
43 |
|
|
awk -f build-history.awk < NEWS.last > $@ |
44 |
|
|
|
45 |
|
|
change-history-de.htm4: build-history.awk NEWS.last |
46 |
|
|
awk -f build-history.awk -v lang=de < NEWS.last > $@ |
47 |
|
|
|
48 |
|
|
online: all |
49 |
|
|
echo "Going to put current contents online for www.gpg4kde.org ..." |
50 |
|
|
rsync -urvP --exclude='.svn' $(ADD_INST_TYPES) $(TARGETS) $(ADD_INST_DIRS) \ |
51 |
|
|
$(USER)@wald.intevation.org:/gpg4kde/htdocs/ |
52 |
|
|
|
53 |
|
|
install: all |
54 |
|
|
mkdir -p $(INSTALL_DIR) ;\ |
55 |
|
|
cp -uf $(TARGETS) $(INSTALL_DIR) ;\ |
56 |
|
|
cp -uf $(ADD_INST_TYPES) $(INSTALL_DIR) |
57 |
|
|
cp -urf *$(ADD_INST_DIRS) $(INSTALL_DIR) |
58 |
|
|
find $(INSTALL_DIR) -name ".svn" | xargs rm -rf |
59 |
|
|
|
60 |
|
|
tar: install |
61 |
|
|
echo $(CURDIR) |
62 |
|
|
( cd $(INSTALL_DIR) ; tar -czv -f $(CURDIR)/www.gpg4kde.org.tar.gz . ) |