<div class="gmail_quote">On Mon, Oct 31, 2011 at 1:44 AM, Ni Qingliang <span dir="ltr">&lt;<a href="mailto:niqingliang@insigma.com.cn">niqingliang@insigma.com.cn</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
I&#39;d like the &#39;system level configuration&#39; solution.<br>
<br>
the /etc/localtime/ link can be done when packaging rootfs (using the<br>
system level configuration).<br>
<div><div></div><div class="h5"><br>
On Fri, 2011-10-28 at 22:43 +0800, Mark Hatle wrote:<br>
&gt; Setting the default TZ for the image is something that should be done in a post<br>
&gt; install script for the tzdata package or something similar.<br>
&gt;<br>
&gt; Since the /etc/localtime is usually a copy/hardlink or symlink to the timezone<br>
&gt; data we don&#39;t want to package it up.  Instead we want to perform the actions<br>
&gt; that a program running on the target system itself would use to change the timezone.<br>
&gt;<br>
&gt; So I think the easiest approach is to add a system level configuration variable<br>
&gt; (set the default).<br>
&gt;<br>
&gt; Then use this variable to populate the configuration file that specifies the<br>
&gt; system timezone... and then use the post install process to check the contents<br>
&gt; of a text file.<br>
&gt;<br>
&gt; Alternatively do this via an initscript -- but for folks w/ read-only<br>
&gt; filesystems I&#39;m not sure that will work.<br>
&gt;<br>
&gt; --Mark<br></div></div></blockquote><div class="h5">&lt;cut&gt;<br><br>Maybe I misunderstand &quot;system level configuration&quot; but in the meta-oe recipe we have<br><br>DEFAULT_TIMEZONE ?= &quot;Europe/London&quot;<br>
<br>Maybe UTC would be better?<br>Note how the variable is weak thus can be overridden in local.conf.   <br> <br>Secondly, why do it as post-install or at image do_rootfs stage when we have set the variable and are therefore able to provide sane defaults in do_install?<br>
<br>Other points before starting to write a patch:<br>-why is the recipe in oe-core doing   chown -R root:root ${D}   ?<br><br>-the logic around   # libc is removing zoneinfo files from package<br>  Is it only eglibc?<br>
<br><br>Regards<br><br>Andrea<br><br><code><br></code></div></div>