-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
executable file
·24 lines (18 loc) · 784 Bytes
/
Copy pathMakefile
File metadata and controls
executable file
·24 lines (18 loc) · 784 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
SHELL:=/bin/bash
PY_BUILD_CMD=python3 pyl3helper2/api.py
TEX_BUILD_CMD=latexmk -pdflatex -interaction=nonstopmode -shell-escape
INPUT_FILE=regexmath/regexmath.sty
PKG_NAME=regexmath
PKG_NAME_UPPER=ReM
OUTPUT_FILE=regexmath.sty
ROOT_DIR:=$(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))
TEST_CALL:=cd $(ROOT_DIR)/test && TEXINPUTS=$(ROOT_DIR)/build:$(TEXINPUTS) $(TEX_BUILD_CMD)
all: regexmath pkg_doc
prepare_build_directory:
mkdir -p build
regexmath: prepare_build_directory
PYTHONPATH=$(ROOT_DIR):$(PYTHONPATH) $(PY_BUILD_CMD) $(INPUT_FILE) -n $(PKG_NAME) -N $(PKG_NAME_UPPER) -o build/$(OUTPUT_FILE)
pkg_doc: regexmath
cd $(ROOT_DIR)/doc && TEXINPUTS=$(ROOT_DIR)/build:$(TEXINPUTS) $(TEX_BUILD_CMD) regexmath.tex
test-regexmath: regexmath
$(TEST_CALL) test.tex