]> de.git.xonotic.org Git - xonotic/mediasource.git/blob - fonts/xolonium/Makefile
Merge branch 'LegendaryGuard/decompile_weapons' into 'master'
[xonotic/mediasource.git] / fonts / xolonium / Makefile
1 # Release
2
3 version     := 4.2
4 weights     := Regular Bold
5 mainFormats := otf ttf
6 webFormats  := woff woff2
7
8
9 # Files
10
11 mainFonts    := $(foreach w,$(weights), $(foreach f,$(mainFormats), fonts/$(f)/Xolonium-$(w).$(f)))
12 webFonts     := $(foreach w,$(weights), $(foreach f,$(webFormats),  fonts/$(f)/Xolonium-$(w).$(f)))
13 xonoticFonts := xonotic/Xolonium-GPL-Regular.otf xonotic/Xolonium-GPL-Bold.otf
14
15
16 # Main rules
17
18 .PHONY: all
19 all: ${mainFonts}
20
21 .PHONY: web
22 web: ${webFonts}
23
24 .PHONY: xonotic
25 xonotic: ${xonoticFonts}
26
27 .PHONY: clean
28 clean:
29         @ rm -fr tmp fonts
30         @ rm -f ${xonoticFonts}
31
32
33 # Font files
34
35 fonts/otf/Xolonium-%.otf: \
36         tmp/otf/Xolonium-%.otf \
37         tmp/fea/Xolonium-%.fea
38                 @ mkdir -p $(@D)
39                 @ ./tools/clean-font.py $^ $@
40
41 fonts/ttf/Xolonium-%.ttf: \
42         tmp/ttf/Xolonium-%.ttf \
43         tmp/fea/Xolonium-%.fea
44                 @ mkdir -p $(@D)
45                 @ ./tools/clean-font.py $^ $@
46
47 fonts/woff/Xolonium-%.woff: \
48         fonts/ttf/Xolonium-%.ttf
49                 @ mkdir -p $(@D)
50                 @ ./tools/make-woff.py $^ $@
51
52 fonts/woff2/Xolonium-%.woff2: \
53         fonts/ttf/Xolonium-%.ttf
54                 @ mkdir -p $(@D)
55                 @ ./tools/make-woff.py $^ $@
56
57
58 # Temporary files
59
60 tmp/otf/Xolonium-%.otf: \
61         src/sfd/Xolonium-%.sfd \
62         src/sfd/Xolonium-Common.sfd \
63         tmp/fea/Xolonium-%.fea
64                 @ mkdir -p $(@D)
65                 @ ./tools/make-font.py $^ NONE ${version} $@
66
67 tmp/ttf/Xolonium-%.ttf: \
68         src/sfd/Xolonium-%.sfd \
69         src/sfd/Xolonium-Common.sfd \
70         tmp/fea/Xolonium-%.fea \
71         tmp/hti/Xolonium-%.hti
72                 @ mkdir -p $(@D)
73                 @ ./tools/make-font.py $^ ${version} $@
74
75 .PRECIOUS: tmp/fea/Xolonium-%.fea
76 tmp/fea/Xolonium-%.fea: \
77         src/fea/Xolonium-Common.fea \
78         src/fea/Xolonium-Common-Class-Latin.fea \
79         src/fea/Xolonium-Common-Class-Greek.fea \
80         src/fea/Xolonium-Common-Class-Cyrillic.fea \
81         src/fea/Xolonium-Common-Kern-All.fea \
82         src/fea/Xolonium-Common-Kern-Latin.fea \
83         src/fea/Xolonium-Common-Kern-Greek.fea \
84         src/fea/Xolonium-Common-Kern-Cyrillic.fea \
85         src/fea/Xolonium-Common-Kern.fea
86                 @ mkdir -p $(@D)
87                 @ sed -f tools/replace-names.sed $^ > $@
88
89 .PRECIOUS: tmp/hti/Xolonium-%.hti
90 tmp/hti/Xolonium-%.hti: \
91         src/hti/Xolonium-Common-meta.hti \
92         src/hti/Xolonium-%-cvt.hti \
93         src/hti/Xolonium-Common-fpgm.hti \
94         src/hti/Xolonium-%-prep.hti \
95         src/hti/Xolonium-Common-glyphs.hti \
96         src/hti/Xolonium-Common-composites.hti
97                 @ mkdir -p $(@D)
98                 @ cat $^ > $@
99
100
101 # Xonotic files
102
103 xonotic/Xolonium-GPL-%.otf: \
104         tmp/otf/Xolonium-GPL-%.otf \
105         tmp/fea/Xolonium-%.fea
106                 @ ./tools/clean-font.py $^ $@
107
108 tmp/otf/Xolonium-GPL-%.otf: \
109         tmp/sfd/Xolonium-GPL-%.sfd \
110         src/sfd/Xolonium-Common.sfd \
111         tmp/fea/Xolonium-%.fea
112                 @ ./tools/make-font.py $^ NONE ${version} $@
113
114 tmp/sfd/Xolonium-GPL-%.sfd: \
115         src/sfd/Xolonium-%.sfd
116                 @ mkdir -p $(@D)
117                 @ cp $^ $@
118                 @ sed -i 's|FontName: Xolonium|FontName: Xolonium-GPL|' $@
119                 @ sed -i 's|FullName: Xolonium|FullName: Xolonium GPL|' $@
120                 @ sed -i 's|FamilyName: Xolonium|FamilyName: Xolonium GPL|' $@
121                 @ sed -i 's|LangName:.*|LangName: 1033 "" "" "$*" "" "" "" "" "" "" "Severin Meyer" "" "https://gitlab.com/sev/xolonium" "" "This font is licensed under the GNU General Public License, either version 2 of the license, or any later version. This font is provided WITHOUT WARRANTY OF ANY KIND, either express or implied. See the GNU General Public License for more details.+AAoACgAA-As a special exception, if you create a document which uses this font, and embed this font or unaltered portions of this font into the document, this font does not by itself cause the resulting document to be covered by the GNU General Public License. This exception does not however invalidate any other reasons why the document might be covered by the GNU General Public License. If you modify this font, you may extend this exception to your version of the font, but you are not obligated to do so. If you do not wish to do so, delete this exception statement from your version." "https://www.gnu.org/licenses/gpl-2.0"|' $@