On Tue, Aug 17, 2021 at 08:49:27PM +0200, Edouard Klein wrote: > It does, thanks, but I'm in a bit of a pickle there because this > packagge needs, for reasons outside of my control, to be deployable on > a multitude of host (non-GuixSD) linux distributions, and as a docker > container. In those cases, I can't expect the timezone data to be up to > date or to be there at all. > > Even if I list tzdata as a dependency, the host system's TZDIR will not > point to it.
You wouldn't list tzdata as a dependency at all. It's the responsibility of the host operating system to provide the correct and current time zone database, and applications should look it up at run-time via TZDIR. If you are deploying to systems without a time zone database, then you could indeed consider "baking" the reference into your package while building, or consider if you need to care about having correct local time at all. > I understand that if I regularly guix pull and guix package -u, then the > tzdata package will be kept up to date. Is that correct ? Yes. But, installed packages should not need to be rebuilt to display the correct time. To elaborate, if you hardcode a store reference to tzdata in your package definitions, then old generations of installed packages will eventually display incorrect local time, because time zones are frequently changed by local governments. And that failure mode is not okay for packages included in GNU Guix. This is one of the rare cases in Guix packaging where dynamic lookup of dependencies is preferred.