make, scripts: Preserve modification time on installation

Implemented -p switch on pkg.sh log-install and used it on standard
installation rules.

Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
Jan Lindemann 2017-08-31 19:40:39 +00:00
commit 92040c66e7
12 changed files with 34 additions and 28 deletions

View file

@ -28,10 +28,10 @@ install-reg.done: install-dirs.done $(PY_INSTALLED_REG)
python -c "import py_compile; py_compile.compile(\"$<\")"
$(PY_INSTALL_DIR)/%.py: %.py
$(INSTALL) -m $(PYMODMODE) -o $(PYMODOWNER) -g $(PYMODGROUP) $< $@
$(INSTALL) -p -m $(PYMODMODE) -o $(PYMODOWNER) -g $(PYMODGROUP) $< $@
$(PY_INSTALL_DIR)/%.pyc: %.pyc
$(INSTALL) -m $(PYMODMODE) -o $(PYMODOWNER) -g $(PYMODGROUP) $< $@
$(INSTALL) -p -m $(PYMODMODE) -o $(PYMODOWNER) -g $(PYMODGROUP) $< $@
__init__.py: $(PY_INIT_TMPL) $(filter-out __init__.py,$(PY_SRC_PY))
if [ "$(PY_INIT_TMPL)" ]; then cat "$(PY_INIT_TMPL)" > $@.tmp; else > $@.tmp; fi