All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gary Thomas <gary@mlbassoc.com>
To: openembedded-core@lists.openembedded.org
Subject: Re: [PATCH] initscripts: Properly handle new timestamp format
Date: Thu, 01 Mar 2012 08:27:14 -0700	[thread overview]
Message-ID: <4F4F9552.8040107@mlbassoc.com> (raw)
In-Reply-To: <4F4F918B.4010404@mlbassoc.com>

On 2012-03-01 08:11, Gary Thomas wrote:
> On 2012-03-01 07:59, Richard Purdie wrote:
>> On Thu, 2012-03-01 at 07:43 -0700, Gary Thomas wrote:
>>> Recent changes have attempted to make consistant use of /etc/timestamp
>>> In particular
>>> 5aab665 initscripts: Make /etc/timestamp consistent again.
>>> 173a48f image.bbclass: Ensure timestamp matches format used in initscripts after recent changes
>>>
>>> This new format can cause problems as the value is too large for
>>> most [32 bit] machines. Work around this by only comparing the
>>> YYYYMMDD portion (which does fit in 32 bits). Also, the new format
>>> is not directly compatible with the 'date' command line, so it
>>> must be reformatted for use.
>>>
>>> Signed-off-by: Gary Thomas<gary@mlbassoc.com>
>>> ---
>>> .../initscripts/initscripts-1.0/bootmisc.sh | 4 ++--
>>> 1 files changed, 2 insertions(+), 2 deletions(-)
>>
>> I merged the changes to busybox in relation to this. Is this patch still
>> needed?
>
> Let me check - I didn't see the related busybox change.
>

I missed the busybox change because there was no PR bump :-(

The problem with the change turning off CONFIG_FEATURE_DATE_COMPAT is that
now 'date' from busybox works one way and 'date' from coreutils works another.

Using coreutils:

root@cobra8148p81:~# date 201203011520
date: invalid date `201203011520'
root@cobra8148p81:~# date 030115202012
Thu Mar  1 15:20:00 UTC 2012
root@cobra8148p81:~# ls -l /bin/date
lrwxrwxrwx 1 root root 14 Mar  1 15:14 /bin/date -> date.coreutils

Using busybox:

root@cobra8148p81:~# ln -s /bin/busybox /tmp/date
root@cobra8148p81:~# /tmp/date 201203011520
Thu Mar  1 15:20:00 UTC 2012

I think the best thing would be to turn CONFIG_FEATURE_DATE_COMPAT back
on along with my reformatting change.

I can make an updated patch if you agree.

-- 
------------------------------------------------------------
Gary Thomas                 |  Consulting for the
MLB Associates              |    Embedded world
------------------------------------------------------------



  reply	other threads:[~2012-03-01 15:35 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-01 14:43 [PATCH] initscripts: Properly handle new timestamp format Gary Thomas
2012-03-01 14:59 ` Richard Purdie
2012-03-01 15:11   ` Gary Thomas
2012-03-01 15:27     ` Gary Thomas [this message]
2012-03-01 15:44       ` Richard Purdie
2012-03-01 15:52         ` Gary Thomas
2012-03-01 16:04           ` Otavio Salvador
2012-03-01 16:06             ` Gary Thomas
2012-03-02  6:15               ` Lauri Hintsala
2012-03-01 16:01       ` Otavio Salvador

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F4F9552.8040107@mlbassoc.com \
    --to=gary@mlbassoc.com \
    --cc=openembedded-core@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.