Debian Codegraph @

Makefile

raw symbols ◀ ▶ SCIP
2 Debian patches touch this file
1 FONT_NAME = 0xProto
2 FAMILIES = Regular Italic Bold
3 SOURCE_DIR = sources
4 ROMAN_GLYPHS_FILE = $(SOURCE_DIR)/$(FONT_NAME).glyphspackage
5 ITALIC_GLYPHS_FILE = $(SOURCE_DIR)/$(FONT_NAME)-Italic.glyphspackage
6 OUTPUT_DIR = fonts
7 SCRIPTS_DIR = scripts
8
•9 .PHONY: setup
10 setup:
•11 @echo "For Debian SID, install: python3-fontmake python3-fonttools"
12 @echo "Optional dependencies: python3-glyphslib (for Glyphs support)"
13 @echo "Alternatively, for all dependencies: pip install -r requirements.txt"
14
15 .PHONY: build
16 build:
17 $(MAKE) clean
18 $(MAKE) compile-all
•19 python3 $(SCRIPTS_DIR)/add_stat.py $(OUTPUT_DIR)/$(FONT_NAME)-Regular.ttf $(OUTPUT_DIR)/$(FONT_NAME)-Bold.ttf $(OUTPUT_DIR)/$(FONT_NAME)-Italic.ttf
20 python3 $(SCRIPTS_DIR)/remove_calt.py $(OUTPUT_DIR) -o $(OUTPUT_DIR)/No-Ligatures
21 python3 $(SCRIPTS_DIR)/build_zx_fonts.py
22
23 compile-roman: $(ROMAN_GLYPHS_FILE)
•24 fontmake -a -g $(ROMAN_GLYPHS_FILE) -i --output-dir $(OUTPUT_DIR)
25
26 compile-italic: $(ITALIC_GLYPHS_FILE)
•27 fontmake -a -g $(ITALIC_GLYPHS_FILE) --output-dir $(OUTPUT_DIR)
28
•29 compile-all: compile-roman compile-italic
30
31 .PHONY: clean
32 clean:
33 if [ -e $(OUTPUT_DIR) ]; then rm -rf $(OUTPUT_DIR); fi
34
35 install-otf: $(OUTPUT_DIR)
36 @for family in $(FAMILIES); do \
37 cp $(OUTPUT_DIR)/$(FONT_NAME)-$$family.otf $(HOME)/Library/Fonts; \
38 done
39
40 .PHONY: install
41 install:
42 $(MAKE) build && $(MAKE) install-otf
43
44 .PHONY: test
45 test:
•46 python3 $(SCRIPTS_DIR)/validate_fonts.py $(OUTPUT_DIR)/$(FONT_NAME)-*.ttf $(OUTPUT_DIR)/No-Ligatures $(OUTPUT_DIR)/ZxProto