Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] Makefile: Update mtime of $(TARGET_DIR)/usr
@ 2018-04-16 15:33 Chris Lesiak
  2018-04-16 20:18 ` Yann E. MORIN
  2018-04-30 17:14 ` [Buildroot] [PATCH v2] Makefile: Update mtime of $(TARGET_DIR)/usr in target-finalize Chris Lesiak
  0 siblings, 2 replies; 9+ messages in thread
From: Chris Lesiak @ 2018-04-16 15:33 UTC (permalink / raw)
  To: buildroot

For the systemd-update-done.service to function, updates to /usr
must be followed by an update of the modification time of /usr.
If updates were always created with a clean build, the mtime of
/usr would automatically be newer than in the old build; but
especially during development, that may not always be the case.
So touch $(TARGET_DIR)/usr as the last step of target-finalize.

For more details, see:
http://0pointer.de/public/systemd-man/systemd-update-done.service.html

Signed-off-by: Chris Lesiak <chris.lesiak@licor.com>
---
 Makefile | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Makefile b/Makefile
index 957ba6634a..12a53840c0 100644
--- a/Makefile
+++ b/Makefile
@@ -761,6 +761,8 @@ endif
 		$(call MESSAGE,"Executing post-build script $(s)"); \
 		$(EXTRA_ENV) $(s) $(TARGET_DIR) $(call qstrip,$(BR2_ROOTFS_POST_SCRIPT_ARGS))$(sep))
 
+	touch $(TARGET_DIR)/usr
+
 .PHONY: target-post-image
 target-post-image: $(TARGETS_ROOTFS) target-finalize
 	@$(foreach s, $(call qstrip,$(BR2_ROOTFS_POST_IMAGE_SCRIPT)), \
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2018-05-03 21:26 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-04-16 15:33 [Buildroot] [PATCH] Makefile: Update mtime of $(TARGET_DIR)/usr Chris Lesiak
2018-04-16 20:18 ` Yann E. MORIN
2018-04-16 21:27   ` Chris Lesiak
2018-04-22 21:37     ` Yann E. MORIN
2018-04-24 18:56       ` Chris Lesiak
2018-04-28 20:00         ` Yann E. MORIN
2018-04-30 17:14 ` [Buildroot] [PATCH v2] Makefile: Update mtime of $(TARGET_DIR)/usr in target-finalize Chris Lesiak
2018-05-03 20:13   ` Thomas Petazzoni
2018-05-03 21:26   ` Peter Korsgaard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox