2011-04-05 14:59:32

by Michal Marek

[permalink] [raw]
Subject: [PATCH 01/34] kconfig: Do not record timestamp in auto.conf and autoconf.h

Timestamps in file data are useless and there is already one in .config

Signed-off-by: Michal Marek <[email protected]>
---
scripts/kconfig/confdata.c | 8 ++------
1 files changed, 2 insertions(+), 6 deletions(-)

diff --git a/scripts/kconfig/confdata.c b/scripts/kconfig/confdata.c
index 61c35bf..834eecb 100644
--- a/scripts/kconfig/confdata.c
+++ b/scripts/kconfig/confdata.c
@@ -784,7 +784,6 @@ int conf_write_autoconf(void)
const char *str;
const char *name;
FILE *out, *tristate, *out_h;
- time_t now;
int i;

sym_clear_all_valid();
@@ -811,22 +810,19 @@ int conf_write_autoconf(void)
return 1;
}

- time(&now);
fprintf(out, "#\n"
"# Automatically generated make config: don't edit\n"
"# %s\n"
- "# %s"
"#\n",
- rootmenu.prompt->text, ctime(&now));
+ rootmenu.prompt->text);
fprintf(tristate, "#\n"
"# Automatically generated - do not edit\n"
"\n");
fprintf(out_h, "/*\n"
" * Automatically generated C config: don't edit\n"
" * %s\n"
- " * %s"
" */\n",
- rootmenu.prompt->text, ctime(&now));
+ rootmenu.prompt->text);

for_all_symbols(i, sym) {
sym_calc_value(sym);
--
1.7.4.1


2011-04-05 18:57:50

by Arnaud Lacombe

[permalink] [raw]
Subject: Re: [PATCH 01/34] kconfig: Do not record timestamp in auto.conf and autoconf.h

Hi,

On Tue, Apr 5, 2011 at 10:58 AM, Michal Marek <[email protected]> wrote:
> Timestamps in file data are useless and there is already one in .config
>
hum, shouldn't this be tunable via KCONFIG_NOTIMESTAMP ? This might be
useful to know when the file was generated, independently of the
.config, as conf_write() and conf_write_autoconf() are independent
from one another.

- Arnaud

> Signed-off-by: Michal Marek <[email protected]>
> ---
> ?scripts/kconfig/confdata.c | ? ?8 ++------
> ?1 files changed, 2 insertions(+), 6 deletions(-)
>
> diff --git a/scripts/kconfig/confdata.c b/scripts/kconfig/confdata.c
> index 61c35bf..834eecb 100644
> --- a/scripts/kconfig/confdata.c
> +++ b/scripts/kconfig/confdata.c
> @@ -784,7 +784,6 @@ int conf_write_autoconf(void)
> ? ? ? ?const char *str;
> ? ? ? ?const char *name;
> ? ? ? ?FILE *out, *tristate, *out_h;
> - ? ? ? time_t now;
> ? ? ? ?int i;
>
> ? ? ? ?sym_clear_all_valid();
> @@ -811,22 +810,19 @@ int conf_write_autoconf(void)
> ? ? ? ? ? ? ? ?return 1;
> ? ? ? ?}
>
> - ? ? ? time(&now);
> ? ? ? ?fprintf(out, "#\n"
> ? ? ? ? ? ? ? ? ? ? "# Automatically generated make config: don't edit\n"
> ? ? ? ? ? ? ? ? ? ? "# %s\n"
> - ? ? ? ? ? ? ? ? ? ?"# %s"
> ? ? ? ? ? ? ? ? ? ? "#\n",
> - ? ? ? ? ? ? ? ? ? ?rootmenu.prompt->text, ctime(&now));
> + ? ? ? ? ? ? ? ? ? ?rootmenu.prompt->text);
> ? ? ? ?fprintf(tristate, "#\n"
> ? ? ? ? ? ? ? ? ? ? ? ? ?"# Automatically generated - do not edit\n"
> ? ? ? ? ? ? ? ? ? ? ? ? ?"\n");
> ? ? ? ?fprintf(out_h, "/*\n"
> ? ? ? ? ? ? ? ? ? ? ? " * Automatically generated C config: don't edit\n"
> ? ? ? ? ? ? ? ? ? ? ? " * %s\n"
> - ? ? ? ? ? ? ? ? ? ? ?" * %s"
> ? ? ? ? ? ? ? ? ? ? ? " */\n",
> - ? ? ? ? ? ? ? ? ? ? ?rootmenu.prompt->text, ctime(&now));
> + ? ? ? ? ? ? ? ? ? ? ?rootmenu.prompt->text);
>
> ? ? ? ?for_all_symbols(i, sym) {
> ? ? ? ? ? ? ? ?sym_calc_value(sym);
> --
> 1.7.4.1
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in
> the body of a message to [email protected]
> More majordomo info at ?http://vger.kernel.org/majordomo-info.html
>

2011-04-06 07:37:43

by Michal Marek

[permalink] [raw]
Subject: Re: [PATCH 01/34] kconfig: Do not record timestamp in auto.conf and autoconf.h

On 5.4.2011 20:57, Arnaud Lacombe wrote:
> Hi,
>
> On Tue, Apr 5, 2011 at 10:58 AM, Michal Marek <[email protected]> wrote:
>> Timestamps in file data are useless and there is already one in .config
>>
> hum, shouldn't this be tunable via KCONFIG_NOTIMESTAMP ? This might be
> useful to know when the file was generated, independently of the
> .config, as conf_write() and conf_write_autoconf() are independent
> from one another.

Yeah, but ls -l include/generated/autoconf.h will tell you the same,
won't it?

Michal

2011-04-06 16:25:38

by Arnaud Lacombe

[permalink] [raw]
Subject: Re: [PATCH 01/34] kconfig: Do not record timestamp in auto.conf and autoconf.h

Hi,

On Wed, Apr 6, 2011 at 3:37 AM, Michal Marek <[email protected]> wrote:
> On 5.4.2011 20:57, Arnaud Lacombe wrote:
>> Hi,
>>
>> On Tue, Apr 5, 2011 at 10:58 AM, Michal Marek <[email protected]> wrote:
>>> Timestamps in file data are useless and there is already one in .config
>>>
>> hum, shouldn't this be tunable via KCONFIG_NOTIMESTAMP ? This might be
>> useful to know when the file was generated, independently of the
>> .config, as conf_write() and conf_write_autoconf() are independent
>> from one another.
>
> Yeah, but ls -l include/generated/autoconf.h will tell you the same,
> won't it?
>
Not if the file is spread to other machine/fs. Not that I care much
though, but for consistency, either KCONFIG_NOTIMESTAMP is honored in
every places where timestamps are used, or it should be killed
altogether.

- Arnaud

2011-04-06 20:39:15

by Michal Marek

[permalink] [raw]
Subject: Re: [PATCH 01/34] kconfig: Do not record timestamp in auto.conf and autoconf.h

On 6.4.2011 18:25, Arnaud Lacombe wrote:
> Hi,
>
> On Wed, Apr 6, 2011 at 3:37 AM, Michal Marek <[email protected]> wrote:
>> On 5.4.2011 20:57, Arnaud Lacombe wrote:
>>> Hi,
>>>
>>> On Tue, Apr 5, 2011 at 10:58 AM, Michal Marek <[email protected]> wrote:
>>>> Timestamps in file data are useless and there is already one in .config
>>>>
>>> hum, shouldn't this be tunable via KCONFIG_NOTIMESTAMP ? This might be
>>> useful to know when the file was generated, independently of the
>>> .config, as conf_write() and conf_write_autoconf() are independent
>>> from one another.
>>
>> Yeah, but ls -l include/generated/autoconf.h will tell you the same,
>> won't it?
>>
> Not if the file is spread to other machine/fs. Not that I care much
> though, but for consistency, either KCONFIG_NOTIMESTAMP is honored in
> every places where timestamps are used, or it should be killed
> altogether.

Or we kill the timestamps in the other places :). auto.conf and
autoconf.h are "internal" files, .config is the file supplied and edited
by the user and I can see that some might find the embedded timestamp
useful. But I doubt that anyone needs the timestamp in auto.conf and
autoconf.h.

Michal

2011-04-18 13:04:17

by Michal Marek

[permalink] [raw]
Subject: Re: [PATCH 01/34] kconfig: Do not record timestamp in auto.conf and autoconf.h

On Tue, Apr 05, 2011 at 04:58:48PM +0200, Michal Marek wrote:
> Timestamps in file data are useless and there is already one in .config
>
> Signed-off-by: Michal Marek <[email protected]>
> ---
> scripts/kconfig/confdata.c | 8 ++------
> 1 files changed, 2 insertions(+), 6 deletions(-)

I pushed this to kbuild-2.6.git#kconfig.

Michal