Mercurial > hg > batmud > maputils
annotate maps/Makefile @ 338:5df69bb02c9e
Updates.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Wed, 11 Jul 2007 18:36:40 +0000 |
parents | b20f940aa9fd |
children | 721bfe123726 |
rev | line source |
---|---|
228 | 1 include ../Makefile.inc |
155 | 2 include Makefile.inc |
39 | 3 |
4 # | |
99 | 5 # Target rules |
39 | 6 # |
103
58a07f7c50b7
Updated locations; Makefile improvements.
Matti Hamalainen <ccr@tnsp.org>
parents:
99
diff
changeset
|
7 all: $(patsubst %.map,%.ppm,$(MAPLIST)) $(TARGETS) |
39 | 8 |
307 | 9 #laenor.map: |
10 # cat ~/mapping.log | grep -v "^$$" > tmp | |
11 # $(MKSPECIAL_BIN) -v -o $@ -r 100 -R 65 -m 40 tmp -a -d -I $(patsubst %.map,%.initial,$@) | |
215 | 12 |
103
58a07f7c50b7
Updated locations; Makefile improvements.
Matti Hamalainen <ccr@tnsp.org>
parents:
99
diff
changeset
|
13 %.tmp: %.map %.loc $(MKLOC_BIN) |
67 | 14 $(MKLOC_BIN) -v -o $@ -m $< -l $(patsubst %.map,%.loc,$<) |
39 | 15 |
307 | 16 %.tmp2: %.map %.loc $(MKLOC_BIN) |
17 $(MKLOC_BIN) -vN -o $@ -m $< -l $(patsubst %.map,%.loc,$<) | |
18 | |
19 %.kakka: %.loc $(MKLOC_BIN) | |
20 $(MKLOC_BIN) -vM -l $< -o $@ | |
21 | |
22 %.html: %.tmp %.desc $(COLORMAP_BIN) | |
23 $(COLORMAP_BIN) -t "`cat $(patsubst %.tmp,%.desc,$<)`" -vaC -f xhtml -o $@ $< | |
24 | |
25 %.htm: %.tmp2 %.desc %.kakka $(COLORMAP_BIN) | |
26 $(COLORMAP_BIN) -t "`cat $(patsubst %.tmp2,%.desc,$<)`" -vaCP -f xhtml $< | \ | |
27 sed -e "/@LOCATIONS@/r $(patsubst %.tmp2,%.kakka,$<)" -e "s/@LOCATIONS@//g" > $@ | |
28 | |
29 | |
331 | 30 %.ansi: %.tmp %.desc $(COLORMAP_BIN) |
88 | 31 $(COLORMAP_BIN) -t "`cat $(patsubst %.tmp,%.desc,$<)`" -vaC -f ansi -o $@ $< |
95
0d2b25e342df
Also make PNG images from maps
Matti Hamalainen <ccr@tnsp.org>
parents:
90
diff
changeset
|
32 |
99 | 33 %.script: %.map %.loc $(MKLOC_BIN) |
338 | 34 $(MKLOC_BIN) -vS -m $< -l $(patsubst %.map,%.loc,$<) -f $(FONTSCALE) -u $(UNITSIZE) -s $(MAPSCALE) | \ |
255
be481e1dca9e
Updated and improved generation of image-format maps.
Matti Hamalainen <ccr@tnsp.org>
parents:
237
diff
changeset
|
35 sed -e "s/@OPTS_START@/-font MonospaceBold.ttf -pointsize 14 -type TruecolorMatte/g" \ |
338 | 36 -e "s/@OPTS_END@/\t-geometry +0+5 title.png -composite -compose screen \\\\\n\t-pointsize 20 -fill white -box none -draw \"text 10,35 \'@PAF@\n\n\n/g" | \ |
255
be481e1dca9e
Updated and improved generation of image-format maps.
Matti Hamalainen <ccr@tnsp.org>
parents:
237
diff
changeset
|
37 sed -e "/@PAF@/r $(patsubst %.map,%.desc,$<)" -e "s/@PAF@//g" > $@ |
99 | 38 |
39 %.ppm: %.map $(MAP2PPM_BIN) | |
134
9c3d01078ae0
Use pnmscale instead of pamscale
Matti Hamalainen <ccr@tnsp.org>
parents:
122
diff
changeset
|
40 $(MAP2PPM_BIN) -v $< | pnmscale $(MAPSCALE) -nomix > $@ |
99 | 41 |
107 | 42 %.png: %.ppm %.script %.desc |
255
be481e1dca9e
Updated and improved generation of image-format maps.
Matti Hamalainen <ccr@tnsp.org>
parents:
237
diff
changeset
|
43 /bin/sh $(patsubst %.ppm,%.script,$<) $< $@ |
103
58a07f7c50b7
Updated locations; Makefile improvements.
Matti Hamalainen <ccr@tnsp.org>
parents:
99
diff
changeset
|
44 |
107 | 45 %.jpg: %.ppm %.script %.desc |
255
be481e1dca9e
Updated and improved generation of image-format maps.
Matti Hamalainen <ccr@tnsp.org>
parents:
237
diff
changeset
|
46 /bin/sh $(patsubst %.ppm,%.script,$<) $< $@ |
99 | 47 |
48 world.map: $(MAPLIST) $(COMBINE_BIN) | |
49 $(COMBINE_BIN) -v -f "~" $(MAPLISTOFFS) -o $@ | |
50 | |
51 world.loc: $(patsubst %.map,%.loc,$(MAPLIST)) | |
52 for i in $(MAPLISTOFFS); do $(MKLOC_BIN) -v -L -l `echo "$$i"|sed "s/^\([^\.]*\).map:.*/\1.loc/"` -m `echo "$$i"|sed "s/^\([^:]*\):\([0-9]*\):\([0-9]*\)/\1 -x \2 -y \3/"`; done > $@ | |
53 | |
103
58a07f7c50b7
Updated locations; Makefile improvements.
Matti Hamalainen <ccr@tnsp.org>
parents:
99
diff
changeset
|
54 world.ppm: world.map $(MAP2PPM_BIN) |
58a07f7c50b7
Updated locations; Makefile improvements.
Matti Hamalainen <ccr@tnsp.org>
parents:
99
diff
changeset
|
55 $(MAP2PPM_BIN) -v $< | pnmscale $(WORLDMAPSCALE) -verbose > $@ |
99 | 56 |
103
58a07f7c50b7
Updated locations; Makefile improvements.
Matti Hamalainen <ccr@tnsp.org>
parents:
99
diff
changeset
|
57 world.script: world.map world.loc $(MKLOC_BIN) |
338 | 58 $(MKLOC_BIN) -vnS -m $< -l $(patsubst %.map,%.loc,$<) -u $(WORLDUNITSIZE) -s $(WORLDMAPSCALE) | \ |
255
be481e1dca9e
Updated and improved generation of image-format maps.
Matti Hamalainen <ccr@tnsp.org>
parents:
237
diff
changeset
|
59 sed -e "s/@OPTS_START@/-font Bandal.ttf -pointsize 10 -type TruecolorMatte/g" \ |
338 | 60 -e "s/@OPTS_END@/\t-geometry +220+15 title.png -composite -compose screen \\\\\n\t-pointsize 30 -fill white -box none -draw \"text 10,30 \'\n@PAF@\n\n/g" | \ |
255
be481e1dca9e
Updated and improved generation of image-format maps.
Matti Hamalainen <ccr@tnsp.org>
parents:
237
diff
changeset
|
61 sed -e "/@PAF@/r $(patsubst %.map,%.desc,$<)" -e "s/@PAF@//g" > $@ |
39 | 62 |
63 # | |
64 # Special targets | |
65 # | |
317 | 66 upload: $(TARGETS) *.loc world.jpg util.js |
103
58a07f7c50b7
Updated locations; Makefile improvements.
Matti Hamalainen <ccr@tnsp.org>
parents:
99
diff
changeset
|
67 scp $? $(UPURL) |
107 | 68 scp $? $(UPURL2) |
141 | 69 touch $@ |
95
0d2b25e342df
Also make PNG images from maps
Matti Hamalainen <ccr@tnsp.org>
parents:
90
diff
changeset
|
70 |
317 | 71 uploc: *.loc |
291
b78d089a0cf4
Upload target for location files only.
Matti Hamalainen <ccr@tnsp.org>
parents:
255
diff
changeset
|
72 scp $+ $(UPURL) |
b78d089a0cf4
Upload target for location files only.
Matti Hamalainen <ccr@tnsp.org>
parents:
255
diff
changeset
|
73 scp $+ $(UPURL2) |
b78d089a0cf4
Upload target for location files only.
Matti Hamalainen <ccr@tnsp.org>
parents:
255
diff
changeset
|
74 |
39 | 75 clean: |
299 | 76 $(RM) $(TARGETS) *.o |
39 | 77 |
78 srcclean: clean | |
299 | 79 $(RM) *~ |
39 | 80 |
297
5482736f3913
ChangeLog generation target added.
Matti Hamalainen <ccr@tnsp.org>
parents:
291
diff
changeset
|
81 update: |
5482736f3913
ChangeLog generation target added.
Matti Hamalainen <ccr@tnsp.org>
parents:
291
diff
changeset
|
82 @echo "* Updating from SVN ..." |
5482736f3913
ChangeLog generation target added.
Matti Hamalainen <ccr@tnsp.org>
parents:
291
diff
changeset
|
83 @svn update |
5482736f3913
ChangeLog generation target added.
Matti Hamalainen <ccr@tnsp.org>
parents:
291
diff
changeset
|
84 |
5482736f3913
ChangeLog generation target added.
Matti Hamalainen <ccr@tnsp.org>
parents:
291
diff
changeset
|
85 .changelog: update |
5482736f3913
ChangeLog generation target added.
Matti Hamalainen <ccr@tnsp.org>
parents:
291
diff
changeset
|
86 @echo "* Making ChangeLog ..." |
5482736f3913
ChangeLog generation target added.
Matti Hamalainen <ccr@tnsp.org>
parents:
291
diff
changeset
|
87 @svn2cl --strip-prefix "maputils/trunk/maps/" --group-by-day --include-rev |
5482736f3913
ChangeLog generation target added.
Matti Hamalainen <ccr@tnsp.org>
parents:
291
diff
changeset
|
88 @touch $@ |
5482736f3913
ChangeLog generation target added.
Matti Hamalainen <ccr@tnsp.org>
parents:
291
diff
changeset
|
89 |
5482736f3913
ChangeLog generation target added.
Matti Hamalainen <ccr@tnsp.org>
parents:
291
diff
changeset
|
90 ChangeLog: .changelog |
5482736f3913
ChangeLog generation target added.
Matti Hamalainen <ccr@tnsp.org>
parents:
291
diff
changeset
|
91 |