diff options
author | Eugeniy E. Mikhailov <evgmik@gmail.com> | 2023-09-25 10:20:30 -0400 |
---|---|---|
committer | Eugeniy E. Mikhailov <evgmik@gmail.com> | 2023-09-25 10:20:30 -0400 |
commit | 4044e9d747c531a998e8a8c4078c2f77d9b65e1f (patch) | |
tree | 6f19485358540ca88445d189137abfaa6bbc9694 | |
parent | f0e1837d769a9062043472729fa3c919d507da8e (diff) | |
parent | d1e4111eba8bc50f586afb38fee474853b62a588 (diff) | |
download | makefile_templates-4044e9d747c531a998e8a8c4078c2f77d9b65e1f.tar.gz makefile_templates-4044e9d747c531a998e8a8c4078c2f77d9b65e1f.zip |
-rw-r--r-- | subdir_makefile/Makefile | 1 | ||||
-rw-r--r-- | xournal.mk | 41 |
2 files changed, 42 insertions, 0 deletions
diff --git a/subdir_makefile/Makefile b/subdir_makefile/Makefile index ccf88c5..270b863 100644 --- a/subdir_makefile/Makefile +++ b/subdir_makefile/Makefile @@ -13,6 +13,7 @@ include $(MAKEINCLUDE_DIR)/beamer_lecture.mk include $(MAKEINCLUDE_DIR)/tex.mk include $(MAKEINCLUDE_DIR)/css.mk include $(MAKEINCLUDE_DIR)/raw.mk +include $(MAKEINCLUDE_DIR)/xournal.mk include $(MAKEINCLUDE_DIR)/subdirs.mk include $(MAKEINCLUDE_DIR)/dest_dirs.mk diff --git a/xournal.mk b/xournal.mk new file mode 100644 index 0000000..2ac2009 --- /dev/null +++ b/xournal.mk @@ -0,0 +1,41 @@ +# -*- make -*- +# Started in 2023 by Eugeniy Mikhailov, <evgmik@gmail.com> +# Processing of xournal files + +CLEAN_TARGETS += clean_xournal +REAL_CLEAN_TARGETS += real_clean_xournal + +dest_dir_xournal ?= $(dest_dir) +destination_dirs += $(dest_dir_xournal) + +xournal_files = $(wildcard *.xopp) +pdf_from_xournal = $(xournal_files:%.xopp=%.pdf) + +xournal_src_dest_targets = $(xournal_files:%=$(dest_dir_xournal)/%) +pdf_from_xournal_dest_targets = $(pdf_from_xournal:%=$(dest_dir_xournal)/%) + +XORNAL = xournalpp + +pdf_xournal: $(pdf_from_xournal) +$(pdf_from_xournal): %.pdf : %.xopp + $(XORNAL) $< --create-pdf=$@ + +install_xournal_src: $(xournal_src_dest_targets) +$(xournal_src_dest_targets): $(dest_dir_xournal)/% : % | $(dest_dir_xournal) +ifneq ($(strip $(xournal_files)),) + $(INSTALL) -m 0644 '$<' '$@' +endif + +install_pdf_xournal: $(pdf_from_xournal_dest_targets) +$(pdf_from_xournal_dest_targets): $(dest_dir_xournal)/% : % | $(dest_dir_xournal) +ifneq ($(strip $(pdf_from_xournal)),) + $(INSTALL) -m 0644 '$<' '$@' +endif + +clean_xournal: + +real_clean_xournal: +ifneq ($(strip $(pdf_from_xournal)),) + rm -f $(pdf_from_xournal) +endif + |