aboutsummaryrefslogtreecommitdiff
path: root/makefile
blob: 31a21eee2ab8ad56f9f805d4784db9e22035a12a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
pkg=arabluatex

sty: clean
	lualatex $(pkg).ins

doc: clean sty
	lualatex $(pkg).dtx
	makeindex -s gind.ist -o $(pkg).ind $(pkg).idx
	makeindex -s gglo.ist -o $(pkg).gls $(pkg).glo
	biber arabluatex
	lualatex $(pkg).dtx
	lualatex $(pkg).dtx

all: clean sty doc

local: clean sty
	cp $(pkg)*.{sty,lua} ~/texmf/tex/lualatex/arabluatex

package: clean all
	mkdir arabluatex
	cp *.lua *.ins *.dtx *.bib arabluatex/
	mkdir -p tex/lualatex/arabluatex/
	cp *.lua *.sty tex/lualatex/arabluatex/
	mkdir -p doc/lualatex/arabluatex/
	cp *.pdf doc/lualatex/arabluatex/
	mkdir -p source/lualatex/arabluatex/
	cp *.lua *.ins *.dtx source/lualatex/arabluatex/
	zip -r arabluatex.tds.zip tex doc source
	mv arabluatex.tds.zip arabluatex
	tar czf arabluatex.tar.gz arabluatex

clean:
	rm -rf tex/ doc/ source/
	rm -rf arabluatex/
	rm -rf saved/
	mkdir saved
	cp *.{lua,ins,dtx,bib} makefile saved
	rm *.*
	cp saved/* .
	rm -rf saved/