feat: generate cp437/sentences with glsl-glyphs
This commit is contained in:
@@ -26,6 +26,17 @@ MAKEPKG ?= makepkg
|
||||
|
||||
INSTALL_DIR ?= $(HOME)/.local/bin
|
||||
|
||||
ifeq (,$(shell which uv))
|
||||
ifeq (,$(shell python3 -m uv --help||python3 -m pip install --user uv)) # detect uv install
|
||||
UV ?= false
|
||||
endif
|
||||
UV ?= python3 -m uv
|
||||
endif
|
||||
|
||||
UV ?= uv
|
||||
GLSL_GLYPHS_DIR ?= glsl-glyphs
|
||||
GLSL_GLYPHS ?= $(UV) run --directory $(GLSL_GLYPHS_DIR) glsl-glyphs
|
||||
|
||||
# DOCS
|
||||
|
||||
.PHONY: help
|
||||
@@ -48,6 +59,12 @@ $(BUILD_DIR)/$(TARGET):
|
||||
mkdir -p $(BUILD_DIR)
|
||||
$(CC) $(SOURCES) $(CFLAGS) $(EXTRA_CFLAGS) $(LDLIBS) -o $(BUILD_DIR)/$(TARGET)
|
||||
|
||||
default/inc_cp437.glsl:
|
||||
$(MAKE) glsl-glyphs
|
||||
|
||||
default/inc_sentences.glsl: default/sentences.txt
|
||||
$(MAKE) glsl-glyphs
|
||||
|
||||
# ACTIONS
|
||||
|
||||
.PHONY: init
|
||||
@@ -175,3 +192,17 @@ makepkg: ## makepkg
|
||||
mkdir -p $(BUILD_DIR)
|
||||
cp PKGBUILD $(BUILD_DIR)
|
||||
cd $(BUILD_DIR) && $(MAKEPKG)
|
||||
|
||||
.PHONY: glsl-glyphs
|
||||
glsl-glyphs: ## glsl-glyphs
|
||||
$(GLSL_GLYPHS) \
|
||||
--name cp437 \
|
||||
--functions \
|
||||
--includes \
|
||||
--add-all \
|
||||
--input sample/cp437_8x8.png \
|
||||
--glyph-names sample/cp437_names.txt \
|
||||
--sets sample/cp437_sets.csv \
|
||||
--output ../default/inc_cp437.glsl \
|
||||
--sentences-input ../default/sentences.txt \
|
||||
--sentences-output ../default/inc_sentences.glsl
|
||||
|
||||
Reference in New Issue
Block a user