diff options
author | Norbert Preining <norbert@preining.info> | 2021-10-12 03:00:58 +0000 |
---|---|---|
committer | Norbert Preining <norbert@preining.info> | 2021-10-12 03:00:58 +0000 |
commit | 20b79660fb560eb1dd8e80d44837e0d4c17ca03c (patch) | |
tree | a96f0dee853efcdecf8395053a4919908aeeb71a /macros/latex/contrib/phfqit/pkg.mk | |
parent | aac7fdc4c391b318efbdee17381ac83783b2fbbb (diff) |
CTAN sync 202110120300
Diffstat (limited to 'macros/latex/contrib/phfqit/pkg.mk')
-rw-r--r-- | macros/latex/contrib/phfqit/pkg.mk | 44 |
1 files changed, 32 insertions, 12 deletions
diff --git a/macros/latex/contrib/phfqit/pkg.mk b/macros/latex/contrib/phfqit/pkg.mk index aca9223514..328b5fc36d 100644 --- a/macros/latex/contrib/phfqit/pkg.mk +++ b/macros/latex/contrib/phfqit/pkg.mk @@ -4,7 +4,9 @@ # LATEX = latex -PDFLATEX = TEXINPUTS="$$TEXINPUTS:../phfnote" pdflatex +PDFLATEXNAME = pdflatex + +PDFLATEX = TEXINPUTS="$$TEXINPUTS:../phfnote" $(PDFLATEXNAME) PDFLATEXOPTS = -interaction=batchmode PDFLATEXOPTSLAST = -interaction=batchmode --synctex=1 @@ -29,29 +31,38 @@ PKGREADME = README.md # DIST_ADDITIONAL_FILES ?= +# +# Additional files automatically generated by the .ins file, such as .def files +# (by default empty) +# +ADDITIONAL_GENERATED_FILES ?= + + +# By default, the generated style file is a '.sty' latex package. If it's a +# '.cls' class file instead, the local Makefile will redefine this to 'cls'. +PKGSTYEXT ?= sty PKGDTX = $(PKG).dtx +PKGSTY = $(PKG).$(PKGSTYEXT) PKGINS = $(PKG).ins -PKGSTY = $(PKG).sty PKGPDF = $(PKG).pdf PKGTDSZIP = $(PKG).tds.zip PKGZIP = $(PKG).zip - -.PHONY: help sty pdf install install_sty install_doc tdszip dist clean cleanall cleansty cleanaux cleanpdf cleantdszip cleandist +.PHONY: help sty cls pdf install install_sty install_cls install_doc tdszip dist clean cleanall cleansty cleancls cleanaux cleanpdf cleantdszip cleandist help: @echo "Targets for $(PKG):" - @echo "make sty -- generate LaTeX package file $(PKG).sty" + @echo "make $(PKGSTYEXT) -- generate LaTeX package file $(PKG).$(PKGSTYEXT)" @echo "make pdf -- generate pdf documentation" - @echo "make install -- install style and documentation files to TEXMF tree" - @echo "make install PREFIX=[specify texmf directory]" - @echo "make $(PKG).tds.zip -- create TDS.ZIP to include in CTAN upload" + @echo "make install -- install style and documentation files to $(DEFAULT_PREFIX)" + @echo "make install PREFIX=[specify texmf directory destination]" + @echo "make $(PKG).tds.zip -- create TDS.ZIP package for distribution" @echo "make dist -- create distribution ZIP, ready for upload to CTAN" @echo "make clean -- remove LaTeX auxiliary files" - @echo "make cleansty -- remove generated style file" + @echo "make clean$(PKGSTYEXT) -- remove generated style file" @echo "make cleanpdf -- remove generated pdf documentation" @echo "make cleanall -- remove all generated files, incl. distribution zip" @@ -66,11 +77,17 @@ cleanall: cleansty cleanaux cleanpdf cleantdszip cleandist sty: $(PKGSTY) +# synonym of `sty` in case of LaTeX classes, we use same commands etc. +cls: $(PKGSTY) + $(PKGSTY): $(PKGINS) $(PKGDTX) $(LATEX) $< cleansty: - @rm -f $(PKGSTY) + @rm -f $(PKGSTY) $(ADDITIONAL_GENERATED_FILES) + +cleancls: cleansty + # ------------------------------------------------ # make pdf @@ -121,7 +138,9 @@ cleanpdf: install_sty: $(PKGSTY) mkdir -p $(DESTDIR)$(PREFIX)/tex/latex/$(PKG) - cp $(PKGSTY) $(DESTDIR)$(PREFIX)/tex/latex/$(PKG) + cp $(PKGSTY) $(ADDITIONAL_GENERATED_FILES) $(DESTDIR)$(PREFIX)/tex/latex/$(PKG) + +install_cls: install_sty install_doc: $(PKGPDF) mkdir -p $(DESTDIR)$(PREFIX)/doc/latex/$(PKG) @@ -161,7 +180,8 @@ $(PKGZIP): #$(PKGTDSZIP) mkdir -p $(DISTTMPDIR)/$(PKG) # cp $(PKGTDSZIP) $(DISTTMPDIR) cp $(PKGDTX) $(PKGINS) $(PKGPDF) $(PKGREADME) Makefile pkg.mk $(DIST_ADDITIONAL_FILES) $(DISTTMPDIR)/$(PKG) - cd $(DISTTMPDIR) && zip -r $(CURDIR)/$(PKGZIP) $(PKG) #$(PKGTDSZIP) +# cd $(DISTTMPDIR) && zip -r $(CURDIR)/$(PKGZIP) $(PKG) $(PKGTDSZIP) + cd $(DISTTMPDIR) && zip -r $(CURDIR)/$(PKGZIP) $(PKG) rm -rf $(DISTTMPDIR) cleandist: |