* timestamp overkill?
@ 2010-11-04 11:44 Gary Thomas
2010-11-10 13:44 ` Richard Purdie
0 siblings, 1 reply; 3+ messages in thread
From: Gary Thomas @ 2010-11-04 11:44 UTC (permalink / raw)
To: Poky
I just noticed that there are two identical functions in image.bbclass
to set/update the image timestamp. Why? Left over from a previous era?
$ find meta* -name "*.bb*" -or -name "*.inc" | xargs grep create_etc_timestamp
meta/classes/image.bbclass:create_etc_timestamp() {
meta/classes/image.bbclass:# export the zap_root_password, create_etc_timestamp and remote_init_link
meta/classes/image.bbclass:EXPORT_FUNCTIONS zap_root_password create_etc_timestamp remove_init_link do_rootfs make_zimage_symlink_relative set_image_autologin
rootfs_update_timestamp rootfs_no_x_startup
Notice that 'create_etc_timestamp' does not seem to be used by
any recipe. Perhaps it should be removed?
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: timestamp overkill?
2010-11-04 11:44 timestamp overkill? Gary Thomas
@ 2010-11-10 13:44 ` Richard Purdie
2010-11-10 14:09 ` Gary Thomas
0 siblings, 1 reply; 3+ messages in thread
From: Richard Purdie @ 2010-11-10 13:44 UTC (permalink / raw)
To: Gary Thomas; +Cc: Poky
On Thu, 2010-11-04 at 05:44 -0600, Gary Thomas wrote:
> I just noticed that there are two identical functions in image.bbclass
> to set/update the image timestamp. Why? Left over from a previous era?
>
> $ find meta* -name "*.bb*" -or -name "*.inc" | xargs grep create_etc_timestamp
> meta/classes/image.bbclass:create_etc_timestamp() {
> meta/classes/image.bbclass:# export the zap_root_password, create_etc_timestamp and remote_init_link
> meta/classes/image.bbclass:EXPORT_FUNCTIONS zap_root_password create_etc_timestamp remove_init_link do_rootfs make_zimage_symlink_relative set_image_autologin
> rootfs_update_timestamp rootfs_no_x_startup
>
> Notice that 'create_etc_timestamp' does not seem to be used by
> any recipe. Perhaps it should be removed?
The one that is unused should probably be removed. Please file a bug
and/or submit a patch!
Cheers,
Richard
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: timestamp overkill?
2010-11-10 13:44 ` Richard Purdie
@ 2010-11-10 14:09 ` Gary Thomas
0 siblings, 0 replies; 3+ messages in thread
From: Gary Thomas @ 2010-11-10 14:09 UTC (permalink / raw)
To: Richard Purdie; +Cc: Poky
[-- Attachment #1: Type: text/plain, Size: 1178 bytes --]
On 11/10/2010 06:44 AM, Richard Purdie wrote:
> On Thu, 2010-11-04 at 05:44 -0600, Gary Thomas wrote:
>> I just noticed that there are two identical functions in image.bbclass
>> to set/update the image timestamp. Why? Left over from a previous era?
>>
>> $ find meta* -name "*.bb*" -or -name "*.inc" | xargs grep create_etc_timestamp
>> meta/classes/image.bbclass:create_etc_timestamp() {
>> meta/classes/image.bbclass:# export the zap_root_password, create_etc_timestamp and remote_init_link
>> meta/classes/image.bbclass:EXPORT_FUNCTIONS zap_root_password create_etc_timestamp remove_init_link do_rootfs make_zimage_symlink_relative set_image_autologin
>> rootfs_update_timestamp rootfs_no_x_startup
>>
>> Notice that 'create_etc_timestamp' does not seem to be used by
>> any recipe. Perhaps it should be removed?
>
> The one that is unused should probably be removed. Please file a bug
> and/or submit a patch!
Attached.
--
------------------------------------------------------------
Gary Thomas | Consulting for the
MLB Associates | Embedded world
------------------------------------------------------------
[-- Attachment #2: 0001-Remove-superfluous-create_etc_timestamp-function.patch --]
[-- Type: text/plain, Size: 913 bytes --]
From 78b0d6c5a12d53afb13a20e51e1653bd572c52c6 Mon Sep 17 00:00:00 2001
From: Gary Thomas <gary@mlbassoc.com>
Date: Wed, 10 Nov 2010 07:08:48 -0700
Subject: [PATCH] Remove superfluous 'create_etc_timestamp()' function - seems to be a duplicate of 'rootfs_update_timestamp()'
Signed-off-by: Gary Thomas <gary@mlbassoc.com>
---
meta/classes/image.bbclass | 4 ----
1 files changed, 0 insertions(+), 4 deletions(-)
diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
index 4be5103..0222ba6 100644
--- a/meta/classes/image.bbclass
+++ b/meta/classes/image.bbclass
@@ -182,10 +182,6 @@ zap_root_password () {
mv ${IMAGE_ROOTFS}/etc/passwd.new ${IMAGE_ROOTFS}/etc/passwd
}
-create_etc_timestamp() {
- date -u +%2m%2d%2H%2M%4Y >${IMAGE_ROOTFS}/etc/timestamp
-}
-
# Turn any symbolic /sbin/init link into a file
remove_init_link () {
if [ -h ${IMAGE_ROOTFS}/sbin/init ]; then
--
1.6.2.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-11-10 14:09 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-11-04 11:44 timestamp overkill? Gary Thomas
2010-11-10 13:44 ` Richard Purdie
2010-11-10 14:09 ` Gary Thomas
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.