annotate world/Makefile @ 2828:85fedaea180a default tip

Fix Aelena opening date.
author Matti Hamalainen <ccr@tnsp.org>
date Wed, 15 May 2024 13:51:54 +0300
parents 38516eb9a5b3
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2506
de2e01e4343b Large refactoring and cleanup of the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 2505
diff changeset
1 ###
de2e01e4343b Large refactoring and cleanup of the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 2505
diff changeset
2 ### Includes and settings
1547
2768b2b396a5 Cosmetics and comments.
Matti Hamalainen <ccr@tnsp.org>
parents: 1536
diff changeset
3 ###
2506
de2e01e4343b Large refactoring and cleanup of the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 2505
diff changeset
4 include ../config.mak
de2e01e4343b Large refactoring and cleanup of the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 2505
diff changeset
5 include ../Makefile.maps
de2e01e4343b Large refactoring and cleanup of the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 2505
diff changeset
6 include ../Makefile.paths
de2e01e4343b Large refactoring and cleanup of the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 2505
diff changeset
7
de2e01e4343b Large refactoring and cleanup of the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 2505
diff changeset
8 BINPATH=../bin/
de2e01e4343b Large refactoring and cleanup of the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 2505
diff changeset
9 EXEEXT=
de2e01e4343b Large refactoring and cleanup of the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 2505
diff changeset
10
2388
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
11
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
12 ifeq ($(HAVE_CURL),yes)
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
13 HTTPGET ?= curl -o
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
14 else
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
15 ifeq ($(HAVE_WGET),yes)
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
16 HTTPGET ?= wget -O
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
17 else
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
18 ifeq ($(HTTPGET),)
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
19 $(error Required utility 'curl' or 'wget' not found in PATH. You can configure HTTPGET variable in config.mak.)
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
20 endif
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
21 endif
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
22 endif
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
23
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
24
e845f54be995 Autodetect curl or wget.
Matti Hamalainen <ccr@tnsp.org>
parents: 2387
diff changeset
25 ###
1547
2768b2b396a5 Cosmetics and comments.
Matti Hamalainen <ccr@tnsp.org>
parents: 1536
diff changeset
26 ### Main targets
2768b2b396a5 Cosmetics and comments.
Matti Hamalainen <ccr@tnsp.org>
parents: 1536
diff changeset
27 ###
2397
b76c25ad1b99 Change how batclient.xml is uploaded. Some improvements to the build rules.
Matti Hamalainen <ccr@tnsp.org>
parents: 2395
diff changeset
28 TARGETS = \
2520
d2918bedeb19 Add EXTRA_WORLD_MAPS variable.
Matti Hamalainen <ccr@tnsp.org>
parents: 2517
diff changeset
29 $(addsuffix .html,$(WORLD_MAPS) $(EXTRA_WORLD_MAPS)) \
1708
9a124fdb6dab Rename various Makefile variables and improve + modularize hcbat-related things better.
Matti Hamalainen <ccr@tnsp.org>
parents: 1707
diff changeset
30 $(addsuffix .ansi,$(WORLD_MAPS)) \
9a124fdb6dab Rename various Makefile variables and improve + modularize hcbat-related things better.
Matti Hamalainen <ccr@tnsp.org>
parents: 1707
diff changeset
31 $(addsuffix .png,$(WORLD_MAPS)) \
2520
d2918bedeb19 Add EXTRA_WORLD_MAPS variable.
Matti Hamalainen <ccr@tnsp.org>
parents: 2517
diff changeset
32 $(addsuffix .htm,$(WORLD_MAPS) $(EXTRA_WORLD_MAPS)) \
2575
9d147f7d809c Rename util.js to worldmap.js to better reflect its functionality.
Matti Hamalainen <ccr@tnsp.org>
parents: 2545
diff changeset
33 worldmap.js changelog.txt
2397
b76c25ad1b99 Change how batclient.xml is uploaded. Some improvements to the build rules.
Matti Hamalainen <ccr@tnsp.org>
parents: 2395
diff changeset
34
2520
d2918bedeb19 Add EXTRA_WORLD_MAPS variable.
Matti Hamalainen <ccr@tnsp.org>
parents: 2517
diff changeset
35 LOCFILES = $(addsuffix .loc,$(WORLD_MAPS) $(EXTRA_WORLD_MAPS)) special.loc limbo.loc
2526
3433e50fd516 Upload .map files when needed.
Matti Hamalainen <ccr@tnsp.org>
parents: 2524
diff changeset
36 EXTRA_MAP_UPLOAD += $(addsuffix .map,$(WORLD_MAPS) $(EXTRA_WORLD_MAPS))
2397
b76c25ad1b99 Change how batclient.xml is uploaded. Some improvements to the build rules.
Matti Hamalainen <ccr@tnsp.org>
parents: 2395
diff changeset
37
b76c25ad1b99 Change how batclient.xml is uploaded. Some improvements to the build rules.
Matti Hamalainen <ccr@tnsp.org>
parents: 2395
diff changeset
38 ifeq ($(HAVE_PHP),yes)
2408
f2e639d72f6f Rename batclient.xml to markers.xml
Matti Hamalainen <ccr@tnsp.org>
parents: 2397
diff changeset
39 TARGETS += markers.xml
2526
3433e50fd516 Upload .map files when needed.
Matti Hamalainen <ccr@tnsp.org>
parents: 2524
diff changeset
40 EXTRA_LOC_UPLOAD += markers.xml
2397
b76c25ad1b99 Change how batclient.xml is uploaded. Some improvements to the build rules.
Matti Hamalainen <ccr@tnsp.org>
parents: 2395
diff changeset
41 endif
1536
796cf56a9b0a Disable plain HTML (non-javascript enhanced) versions.
Matti Hamalainen <ccr@tnsp.org>
parents: 1515
diff changeset
42
796cf56a9b0a Disable plain HTML (non-javascript enhanced) versions.
Matti Hamalainen <ccr@tnsp.org>
parents: 1515
diff changeset
43
1547
2768b2b396a5 Cosmetics and comments.
Matti Hamalainen <ccr@tnsp.org>
parents: 1536
diff changeset
44 ###
2768b2b396a5 Cosmetics and comments.
Matti Hamalainen <ccr@tnsp.org>
parents: 1536
diff changeset
45 ### If no target specified, show some help
2768b2b396a5 Cosmetics and comments.
Matti Hamalainen <ccr@tnsp.org>
parents: 1536
diff changeset
46 ###
842
f5dda74e6e07 Print help if no target is given. Remove generation of worldmap.
Matti Hamalainen <ccr@tnsp.org>
parents: 807
diff changeset
47 all:
2067
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
48 @echo "Usage: make <target>"
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
49 @echo "Available targets are as follows:"
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
50 @echo
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
51 @echo "maps : Build HTML, HTML+JS, PNG image and ANSI format maps."
2514
ec4294c93585 Adjust help.
Matti Hamalainen <ccr@tnsp.org>
parents: 2510
diff changeset
52 @echo
2067
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
53 @echo "fetch : Fetch latest raw ASCII map data from bat.org."
842
f5dda74e6e07 Print help if no target is given. Remove generation of worldmap.
Matti Hamalainen <ccr@tnsp.org>
parents: 807
diff changeset
54 @echo
2067
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
55 @echo "diff : Do special diff operation between new data (gotten via 'fetch')"
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
56 @echo " and update .loc files for each continent with new locations."
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
57 @echo " A diff -u of new and old location files is outputted."
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
58 @echo
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
59 @echo "upload : Uploads map and loc-files via SCP to server specified in"
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
60 @echo " ../config.mak"
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
61 @echo
97e4361d9ac9 Clean up 'make help'.
Matti Hamalainen <ccr@tnsp.org>
parents: 2047
diff changeset
62 @echo "clean : Delete all the generated files."
1512
031708e1dcb9 Update help.
Matti Hamalainen <ccr@tnsp.org>
parents: 1237
diff changeset
63 @echo
842
f5dda74e6e07 Print help if no target is given. Remove generation of worldmap.
Matti Hamalainen <ccr@tnsp.org>
parents: 807
diff changeset
64
f5dda74e6e07 Print help if no target is given. Remove generation of worldmap.
Matti Hamalainen <ccr@tnsp.org>
parents: 807
diff changeset
65
1547
2768b2b396a5 Cosmetics and comments.
Matti Hamalainen <ccr@tnsp.org>
parents: 1536
diff changeset
66 ###
2506
de2e01e4343b Large refactoring and cleanup of the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 2505
diff changeset
67 ### Targets
1547
2768b2b396a5 Cosmetics and comments.
Matti Hamalainen <ccr@tnsp.org>
parents: 1536
diff changeset
68 ###
1708
9a124fdb6dab Rename various Makefile variables and improve + modularize hcbat-related things better.
Matti Hamalainen <ccr@tnsp.org>
parents: 1707
diff changeset
69 maps: $(addsuffix .ppm,$(WORLD_MAPS)) $(TARGETS)
39
fa68caaf3c94 New maps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
70
346
721bfe123726 Minor refactoring of the build files.
Matti Hamalainen <ccr@tnsp.org>
parents: 338
diff changeset
71
2510
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
72 %.script: %.map %.loc title.png $(WORLDMAP_FONT_FILE) $(MKLOC_BIN)
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
73 @echo "MKLOC $@"
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
74 @$(MKLOC_BIN) $(MKLOC_OPTS) -S -m $< -l $(patsubst %.map,%.loc,$<) -f $(WORLDMAP_FONT_SCALE) -u $(WORLDMAP_UNIT_SIZE) -s $(WORLDMAP_SCALE) | \
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
75 sed -e "s/@OPTS_START@/-font $(WORLDMAP_FONT_FILE) -pointsize 14 -type TruecolorMatte/g" \
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
76 -e "s/@OPTS_END@/\t-geometry +0+0 title.png -composite -compose screen \\\\\n\t-pointsize 20 -fill white -box none -draw \"text 5,50 \'@PAF@\n\n\n/g" | \
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
77 sed -e "/@PAF@/r $(patsubst %.map,%.desc,$<)" -e "s/@PAF@//g" > $@
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
78
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
79 %.ppm: %.map
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
80 @echo "MAP2PPM $@"
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
81 @$(MAP2PPM_BIN) $(MAP2PPM_OPTS) -s $(WORLDMAP_SCALE) $(COLORMAP_EXTRA) $< -o $@
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
82
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
83 ifeq ($(HAVE_GIMP_CONSOLE),yes)
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
84 %_rgb.png: %.ppm %.script %.desc
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
85 @echo "PNG $@"
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
86 @/bin/sh $(patsubst %.ppm,%.script,$<) $< $@
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
87
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
88 %.png: %_rgb.png
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
89 @echo "GIMP $@"
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
90 @gimp-console -c -d -i -b \
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
91 "(let* ( \
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
92 (img (car (file-png-load RUN-NONINTERACTIVE \"$<\" \"$<\"))) \
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
93 (drawable (car (gimp-image-active-drawable img)))) \
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
94 (gimp-convert-indexed img NO-DITHER MAKE-PALETTE 64 FALSE FALSE \"\") \
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
95 (file-png-save2 RUN-NONINTERACTIVE img drawable \"$@\" \"$@\" 0 9 0 0 0 0 0 0 0))" \
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
96 -b '(gimp-quit 0)'
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
97 else
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
98 %.png: %.ppm %.script %.desc
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
99 @echo "PNG $@"
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
100 @/bin/sh $(patsubst %.ppm,%.script,$<) $< $@
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
101 endif
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
102
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
103
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
104 # Fetch raw ASCII maps from bat.org to *.new
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
105 fetch:
2517
6e8e797c751f Fix BATMAP_URL reference.
Matti Hamalainen <ccr@tnsp.org>
parents: 2514
diff changeset
106 @for AMAP in $(CONT_MAPS); do echo "Fetching $${AMAP}.new"; $(HTTPGET) "$${AMAP}.new" "$(BATMAP_URL)$${AMAP}.txt"; done
2510
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
107
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
108
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
109 # Remove all temporary .diff files
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
110 cleardiff:
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
111 $(RM) *.diff
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
112
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
113 # Diff target - run diff for each .map and .new (fetched via 'fetch' target).
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
114 # Finally do 'hg diff' to show changes.
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
115 diff: cleardiff $(addsuffix .diff,$(CONT_MAPS))
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
116 @hg diff .
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
117
2621
9ef91b0032f3 Refactor some of the 'make diff' code to Makefile.maps and add 'diff' target to old/Makefile too.
Matti Hamalainen <ccr@tnsp.org>
parents: 2610
diff changeset
118
2510
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
119 %.js:: ../src/%.js
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
120 @ln -s $< $@
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
121
83967e0447f7 Move pieces around in build system for some more clarity.
Matti Hamalainen <ccr@tnsp.org>
parents: 2509
diff changeset
122
2317
f90303eec665 Include misc maps in generated changelog as well.
Matti Hamalainen <ccr@tnsp.org>
parents: 2315
diff changeset
123 changelog.txt: $(addsuffix .map,$(WORLD_MAPS)) \
2438
f90494b8efa7 Possibly fix the changelog.txt not updating properly -issue.
Matti Hamalainen <ccr@tnsp.org>
parents: 2421
diff changeset
124 $(addsuffix .loc,$(WORLD_MAPS)) \
2317
f90303eec665 Include misc maps in generated changelog as well.
Matti Hamalainen <ccr@tnsp.org>
parents: 2315
diff changeset
125 $(addprefix ../$(MISC_MAPS_PATH),$(addsuffix .map,$(MISC_MAPS))) \
2643
7fb4ae35d948 Add hcbat entries to changelog, too.
Matti Hamalainen <ccr@tnsp.org>
parents: 2621
diff changeset
126 $(addprefix ../$(MISC_MAPS_PATH),$(addsuffix .loc,$(MISC_MAPS))) \
7fb4ae35d948 Add hcbat entries to changelog, too.
Matti Hamalainen <ccr@tnsp.org>
parents: 2621
diff changeset
127 ../old/hcbat.loc ../old/hcbat.ref ../old/hcbat.map
2463
7a33f1beaf71 Adjust changelog generation rule: hg up && ... instead of hg up ; ...
Matti Hamalainen <ccr@tnsp.org>
parents: 2438
diff changeset
128 @hg up && ( echo '<?xml version="1.0"?>' && echo '<log>' && \
2069
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
129 hg log $+ -M -v -f --template \
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
130 '<logentry revision="{rev}"><author>{author|escape}</author><date>{date|isodate}</date><paths><path>{files}</path></paths><msg>{desc|escape}</msg></logentry>\n' && \
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
131 echo '</log>' ) | \
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
132 iconv -f "iso-8859-1" -t "utf-8" | \
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
133 xsltproc --stringparam strip-prefix "" \
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
134 --stringparam linelen 80 \
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
135 --stringparam groupbyday yes \
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
136 --stringparam include-rev no \
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
137 "svn2cl.xsl" - | \
2823
38516eb9a5b3 Cleanup regexp.
Matti Hamalainen <ccr@tnsp.org>
parents: 2643
diff changeset
138 sed 's@world/@@g;s@maps/@@g;s@Matti .*@Ggr@g;s@Jarkko .*@Jeskko@g' \
2069
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
139 > $@
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
140
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
141
2408
f2e639d72f6f Rename batclient.xml to markers.xml
Matti Hamalainen <ccr@tnsp.org>
parents: 2397
diff changeset
142 # Build Batclient markers.xml
f2e639d72f6f Rename batclient.xml to markers.xml
Matti Hamalainen <ccr@tnsp.org>
parents: 2397
diff changeset
143 markers.xml: $(addsuffix .loc,$(WORLD_MAPS)) $(MKLOC_BIN) ../www/world.inc.php
2395
42ee2079a69d Rename generate_batclient_xml.php to genbcxml.php
Matti Hamalainen <ccr@tnsp.org>
parents: 2388
diff changeset
144 php ../src/genbcxml.php $(MKLOC_BIN) ./ ../www/world.inc.php $@
2387
53c34aaf4515 Add PHP kludge for generating batclient.xml and necessary Makefile rules for
Matti Hamalainen <ccr@tnsp.org>
parents: 2369
diff changeset
145
2069
d0e00cd7b2a5 Add make target for building changelog.txt, that contains cleaned up
Matti Hamalainen <ccr@tnsp.org>
parents: 2067
diff changeset
146
950
72e53a705775 Add comments.
Matti Hamalainen <ccr@tnsp.org>
parents: 937
diff changeset
147 # Upload changed files to site
2526
3433e50fd516 Upload .map files when needed.
Matti Hamalainen <ccr@tnsp.org>
parents: 2524
diff changeset
148 upload: $(TARGETS) $(LOCFILES) $(EXTRA_LOC_UPLOAD) $(EXTRA_MAP_UPLOAD)
2524
73f3062d717c Rename two Makefile variables.
Matti Hamalainen <ccr@tnsp.org>
parents: 2520
diff changeset
149 $(RSCP_COMMAND) $? $(RSCP_UPLOAD_URL)
1623
032cdfc4f017 Various build fixes.
Matti Hamalainen <ccr@tnsp.org>
parents: 1622
diff changeset
150 @touch $@
95
0d2b25e342df Also make PNG images from maps
Matti Hamalainen <ccr@tnsp.org>
parents: 90
diff changeset
151
950
72e53a705775 Add comments.
Matti Hamalainen <ccr@tnsp.org>
parents: 937
diff changeset
152 # Upload only *.loc files
2526
3433e50fd516 Upload .map files when needed.
Matti Hamalainen <ccr@tnsp.org>
parents: 2524
diff changeset
153 uploc: $(LOCFILES) $(EXTRA_LOC_UPLOAD)
2524
73f3062d717c Rename two Makefile variables.
Matti Hamalainen <ccr@tnsp.org>
parents: 2520
diff changeset
154 $(RSCP_COMMAND) $+ $(RSCP_UPLOAD_URL)
291
b78d089a0cf4 Upload target for location files only.
Matti Hamalainen <ccr@tnsp.org>
parents: 255
diff changeset
155
950
72e53a705775 Add comments.
Matti Hamalainen <ccr@tnsp.org>
parents: 937
diff changeset
156 # Clean temporary and generated targets
39
fa68caaf3c94 New maps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
157 clean:
937
9342d636bc21 Remove *.script files on clean target.
Matti Hamalainen <ccr@tnsp.org>
parents: 911
diff changeset
158 $(RM) $(TARGETS) *.diff *.ppm *.o *.script
39
fa68caaf3c94 New maps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
159
fa68caaf3c94 New maps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
160 srcclean: clean
299
ed5dfa77511f Removed '-f' option.
Matti Hamalainen <ccr@tnsp.org>
parents: 297
diff changeset
161 $(RM) *~