summaryrefslogtreecommitdiff
path: root/pic_pdf_compatible.mk
diff options
context:
space:
mode:
authorEugeniy Mikhailov <evgmik@gmail.com>2015-04-17 16:33:37 -0400
committerEugeniy Mikhailov <evgmik@gmail.com>2015-04-17 16:34:06 -0400
commita4d24e574d078dac6b2e3e9046406e24935019f0 (patch)
tree6117f91774b4ac83b6ead73e286dc8b8738269f0 /pic_pdf_compatible.mk
parent2637742612ebe1870032e9e15c9f317cbbdb13cf (diff)
downloadmakefile_templates-a4d24e574d078dac6b2e3e9046406e24935019f0.tar.gz
makefile_templates-a4d24e574d078dac6b2e3e9046406e24935019f0.zip
improved destination handling
Diffstat (limited to 'pic_pdf_compatible.mk')
-rw-r--r--pic_pdf_compatible.mk11
1 files changed, 6 insertions, 5 deletions
diff --git a/pic_pdf_compatible.mk b/pic_pdf_compatible.mk
index 259b567..6bd29ff 100644
--- a/pic_pdf_compatible.mk
+++ b/pic_pdf_compatible.mk
@@ -3,6 +3,8 @@
CLEAN_TARGETS += clean_pdf_compatible
REAL_CLEAN_TARGETS += real_clean_pdf_compatible
+destination_dirs += $(pics_destdir)
+
pdf_compatible_files = \
$(wildcard *.pdf) \
$(wildcard *.png) \
@@ -10,9 +12,11 @@ pdf_compatible_files = \
copied_pdf_compatible_files = $(pdf_compatible_files:%=$(pics_destdir)/%)
-copy_pdf_compatible_files: dest_dir_pdf_compatible $(copied_pdf_compatible_files)
+.PHONY: clean_pdf_compatible real_clean_pdf_compatible
+
+copy_pdf_compatible_files: $(copied_pdf_compatible_files)
-$(copied_pdf_compatible_files): $(pics_destdir)/% : %
+$(copied_pdf_compatible_files): $(pics_destdir)/% : % | $(pics_destdir)
$(INSTALL) -m 0644 $< $@
clean_pdf_compatible:
@@ -22,6 +26,3 @@ ifneq ($(strip $(copied_pdf_compatible_files)),)
rm -f $(copied_pdf_compatible_files)
endif
-dest_dir_pdf_compatible:
- $(INSTALL) -d -m 0755 $(pics_destdir)
-