* [gentoo-catalyst] timezone during stage4
@ 2013-02-25 22:07 Peter Stuge
2013-02-25 22:17 ` W. Trevor King
0 siblings, 1 reply; 9+ messages in thread
From: Peter Stuge @ 2013-02-25 22:07 UTC (permalink / raw
To: gentoo-catalyst
A program in a stage4 that I have says this on startup:
(built Mon Dec 10 2012 10:06:39 Local time zone must be set--see zic manual page)
It's ugly and stupid. catalyst should probably copy the host
localtime into the chroot, and either remove it or replace it with a
tzfile explicitly set in the spec file.
I copy a file in the fsscript, but that of course happens *after* the
above `date` output has already been compiled in.
What to do?
//Peter
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-catalyst] timezone during stage4
2013-02-25 22:07 [gentoo-catalyst] timezone during stage4 Peter Stuge
@ 2013-02-25 22:17 ` W. Trevor King
2013-02-25 22:55 ` Peter Stuge
0 siblings, 1 reply; 9+ messages in thread
From: W. Trevor King @ 2013-02-25 22:17 UTC (permalink / raw
To: gentoo-catalyst
[-- Attachment #1: Type: text/plain, Size: 553 bytes --]
On Mon, Feb 25, 2013 at 11:07:46PM +0100, Peter Stuge wrote:
> catalyst should probably copy the host localtime into the chroot,
> and either remove it or replace it with a tzfile explicitly set in
> the spec file.
>
> I copy a file in the fsscript, but that of course happens *after* the
> above `date` output has already been compiled in.
>
> What to do?
Use stage4/root_overlay?
--
This email may be signed or encrypted with GnuPG (http://www.gnupg.org).
For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-catalyst] timezone during stage4
2013-02-25 22:17 ` W. Trevor King
@ 2013-02-25 22:55 ` Peter Stuge
2013-02-25 23:08 ` W. Trevor King
0 siblings, 1 reply; 9+ messages in thread
From: Peter Stuge @ 2013-02-25 22:55 UTC (permalink / raw
To: gentoo-catalyst
[-- Attachment #1: Type: text/plain, Size: 804 bytes --]
W. Trevor King wrote:
> > catalyst should probably copy the host localtime into the chroot,
probably in chroot_setup, as long as *before* build_packages
> > and either remove it or replace it with a tzfile explicitly set in
> > the spec file.
probably in clean
> > I copy a file in the fsscript, but that of course happens *after* the
> > above `date` output has already been compiled in.
> >
> > What to do?
>
> Use stage4/root_overlay?
root_overlay comes just before fsscript so it doesn't really solve
the problem.
My above idea of copying /etc/localtime into the chroot during
chroot_setup and either just removing it or replacing it with a
file from an optional to-be-added spec file parameter seems like it
would work - how do people feel about that?
//Peter
[-- Attachment #2: Type: application/pgp-signature, Size: 190 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-catalyst] timezone during stage4
2013-02-25 22:55 ` Peter Stuge
@ 2013-02-25 23:08 ` W. Trevor King
2013-02-25 23:16 ` W. Trevor King
2013-02-25 23:18 ` Peter Stuge
0 siblings, 2 replies; 9+ messages in thread
From: W. Trevor King @ 2013-02-25 23:08 UTC (permalink / raw
To: gentoo-catalyst
[-- Attachment #1: Type: text/plain, Size: 1556 bytes --]
On Mon, Feb 25, 2013 at 11:55:47PM +0100, Peter Stuge wrote:
> W. Trevor King wrote:
> > > I copy a file in the fsscript, but that of course happens *after* the
> > > above `date` output has already been compiled in.
> > >
> > > What to do?
> >
> > Use stage4/root_overlay?
>
> root_overlay comes just before fsscript so it doesn't really solve
> the problem.
Ah, sorry. I was unable to find documentation for command invocation
order, but `<target>/root_overlay` is advertised as being suitable for
config files. It would make sense to me if this was dropped in before
emerging packages (for cases like this), but it would also make sense
if this was dropped in after emerging packages (e.g. to override
config files clobbered by the new packages). I suppose it's currently
the latter.
> My above idea of copying /etc/localtime into the chroot during
> chroot_setup and either just removing it or replacing it with a
> file from an optional to-be-added spec file parameter seems like it
> would work - how do people feel about that?
FWIW, I'd prefer an early-acting root_overlay analog. Also a single
new spec file parameter, but you get the added flexibility of handling
any additional pre-emerge setup you need. I don't know what
additional setup you might need, but if we've missed timezones, we're
probably missing something else ;).
Cheers,
Trevor
--
This email may be signed or encrypted with GnuPG (http://www.gnupg.org).
For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-catalyst] timezone during stage4
2013-02-25 23:08 ` W. Trevor King
@ 2013-02-25 23:16 ` W. Trevor King
2013-02-25 23:18 ` Peter Stuge
1 sibling, 0 replies; 9+ messages in thread
From: W. Trevor King @ 2013-02-25 23:16 UTC (permalink / raw
To: gentoo-catalyst
[-- Attachment #1: Type: text/plain, Size: 398 bytes --]
On Mon, Feb 25, 2013 at 06:08:00PM -0500, W. Trevor King wrote:
> I was unable to find documentation for command invocation order,
For future reference, it looks like it's defined on a per-target basis
by target.set_action_sequence().
--
This email may be signed or encrypted with GnuPG (http://www.gnupg.org).
For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-catalyst] timezone during stage4
2013-02-25 23:08 ` W. Trevor King
2013-02-25 23:16 ` W. Trevor King
@ 2013-02-25 23:18 ` Peter Stuge
2013-02-25 23:24 ` W. Trevor King
1 sibling, 1 reply; 9+ messages in thread
From: Peter Stuge @ 2013-02-25 23:18 UTC (permalink / raw
To: gentoo-catalyst
[-- Attachment #1: Type: text/plain, Size: 721 bytes --]
W. Trevor King wrote:
> it would also make sense if this was dropped in after emerging packages
> I suppose it's currently the latter.
I believe it always was.
> > My above idea of copying /etc/localtime into the chroot during
> > chroot_setup and either just removing it or replacing it with a
> > file from an optional to-be-added spec file parameter seems like it
> > would work - how do people feel about that?
>
> FWIW, I'd prefer an early-acting root_overlay analog.
..
> if we've missed timezones, we're probably missing something else ;)
It's not a bad idea, but OTOH copying /etc/localtime and just
removing it again needs no new parameter and would be quite a
simple patch.
//Peter
[-- Attachment #2: Type: application/pgp-signature, Size: 190 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-catalyst] timezone during stage4
2013-02-25 23:18 ` Peter Stuge
@ 2013-02-25 23:24 ` W. Trevor King
2013-02-25 23:38 ` Peter Stuge
0 siblings, 1 reply; 9+ messages in thread
From: W. Trevor King @ 2013-02-25 23:24 UTC (permalink / raw
To: gentoo-catalyst
[-- Attachment #1: Type: text/plain, Size: 1114 bytes --]
On Tue, Feb 26, 2013 at 12:18:15AM +0100, Peter Stuge wrote:
> W. Trevor King wrote:
> > > My above idea of copying /etc/localtime into the chroot during
> > > chroot_setup and either just removing it or replacing it with a
> > > file from an optional to-be-added spec file parameter seems like it
> > > would work - how do people feel about that?
> >
> > FWIW, I'd prefer an early-acting root_overlay analog.
> ..
> > if we've missed timezones, we're probably missing something else ;)
>
> It's not a bad idea, but OTOH copying /etc/localtime and just
> removing it again needs no new parameter and would be quite a
> simple patch.
But then why not just copy over the portage tree too, instead of going
through the snapshot procedure? I think the point of catalyst is to
isolate the final tarballs/ISOs from the host system used to build
them. Otherwise we could skip stages and catalyst, building the
tarballs in a simple chroot.
--
This email may be signed or encrypted with GnuPG (http://www.gnupg.org).
For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-catalyst] timezone during stage4
2013-02-25 23:24 ` W. Trevor King
@ 2013-02-25 23:38 ` Peter Stuge
2013-02-25 23:57 ` W. Trevor King
0 siblings, 1 reply; 9+ messages in thread
From: Peter Stuge @ 2013-02-25 23:38 UTC (permalink / raw
To: gentoo-catalyst
[-- Attachment #1: Type: text/plain, Size: 637 bytes --]
W. Trevor King wrote:
> > It's not a bad idea, but OTOH copying /etc/localtime and just
> > removing it again needs no new parameter and would be quite a
> > simple patch.
>
> But then why not just copy over the portage tree too, instead of
> going through the snapshot procedure?
As it happens, I have a patch which implements that.
> I think the point of catalyst is to isolate the final tarballs/ISOs
> from the host system used to build them. Otherwise we could skip
> stages and catalyst, building the tarballs in a simple chroot.
Yes and no. For timezone and resolv.conf that doesn't make sense.
//Peter
[-- Attachment #2: Type: application/pgp-signature, Size: 190 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [gentoo-catalyst] timezone during stage4
2013-02-25 23:38 ` Peter Stuge
@ 2013-02-25 23:57 ` W. Trevor King
0 siblings, 0 replies; 9+ messages in thread
From: W. Trevor King @ 2013-02-25 23:57 UTC (permalink / raw
To: gentoo-catalyst
[-- Attachment #1: Type: text/plain, Size: 1442 bytes --]
On Tue, Feb 26, 2013 at 12:38:29AM +0100, Peter Stuge wrote:
> W. Trevor King wrote:
> > > It's not a bad idea, but OTOH copying /etc/localtime and just
> > > removing it again needs no new parameter and would be quite a
> > > simple patch.
> >
> > But then why not just copy over the portage tree too, instead of
> > going through the snapshot procedure?
>
> As it happens, I have a patch which implements that.
Hmm, that weakens my argument ;).
> > I think the point of catalyst is to isolate the final tarballs/ISOs
> > from the host system used to build them. Otherwise we could skip
> > stages and catalyst, building the tarballs in a simple chroot.
>
> Yes and no. For timezone and resolv.conf that doesn't make sense.
Agreed for resolv.conf, the presense of which always struck me as odd.
It would be nice if resolv.conf only overrode DNS information that was
stored in the kernel or something (like /etc/conf.d/hostname).
If the builds are not affected by the particular timezone selected,
why not just hard-code it to UTC? Folks with their hwclock set to a
non-UTC timezone might get an artificial offset, but generated
tarballs are more host-agnostic, and an offset of a few hours seems
harmless.
Not a big deal either way, though ;).
--
This email may be signed or encrypted with GnuPG (http://www.gnupg.org).
For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2013-02-25 23:58 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-25 22:07 [gentoo-catalyst] timezone during stage4 Peter Stuge
2013-02-25 22:17 ` W. Trevor King
2013-02-25 22:55 ` Peter Stuge
2013-02-25 23:08 ` W. Trevor King
2013-02-25 23:16 ` W. Trevor King
2013-02-25 23:18 ` Peter Stuge
2013-02-25 23:24 ` W. Trevor King
2013-02-25 23:38 ` Peter Stuge
2013-02-25 23:57 ` W. Trevor King
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox