Skip to contentSkip to conversation

New: tzdata fails to install with empty "default local time"

Buildroot bugzilla at busybox.net 1 participant 6 messages Nov 15, 2019 – Nov 27, 2019

lore
Share & tools
lore
#0 lore raw

https://bugs.busybox.net/show_bug.cgi?id=12316

Bug ID: 12316
Target: aarch64 on Nvidia TX2
Summary: tzdata fails to install with empty "default local
time"
Product: buildroot
Version: 2019.02.2
Hardware: All
OS: Linux
Status: NEW
Severity: normal
Priority: P5
Component: Other
Assignee: unassigned at buildroot.uclibc.org
Reporter: andrew.trapani at ontera.bio
CC: buildroot at uclibc.org
Target Milestone: ---

Option #1:

Under menuconfig
System configuration --->
-*- Install timezone info
(default) timezone list
() default local time

My understanding after doing internet searches was that an empty "default local time" field would be set to Etc/UTC.

However, the build failed here:

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

host-tzdata 2018e Installing to host directory
tzdata 2018e Extracting
tzdata 2018e Patching
tzdata 2018e Configuring
tzdata 2018e Building
tzdata 2018e Installing to target

Error: '' is not a valid timezone, check your BR2_TARGET_LOCALTIME setting package/pkg-generic.mk:331: recipe for target '/build/output/tx2_basecamp/build/tzdata-2018e/.stamp_target_installed' failed make[1]: *** [/build/output/tx2_basecamp/build/tzdata-2018e/.stamp_target_installed] Error 1 Makefile:23: recipe for target '_all' failed
make: *** [_all] Error 2
Could not create rootfs... not building image
Makefile:89: recipe for target 'docker_build_image' failed

Option #2:
Then Under menuconfig

-*- Install timezone info
(default) timezone list
(Etc/UTC) default local time

Then tzdata works and the build continues.

Do a symsearch for TZDATA to find out what is required:
Symbol: BR2_PACKAGE_TZDATA [=y]
Type : bool
Defined at package/tzdata/Config.in:4
Selected by [y]:
- BR2_TARGET_TZ_INFO [=y] && BR2_TOOLCHAIN_USES_GLIBC [=y] Selected by [n]:
- BR2_TARGET_TZ_INFO [=y] && BR2_TOOLCHAIN_USES_MUSL [=n]

The config is attached, but please be warned that it references local paths to local things and won't build for you.

It also has Etc/UTC set as the "default local time". This is how I got tzdata to complete.

Signature · 2 lines
You are receiving this mail because:
You are on the CC list for the bug.
#1 lore raw

[Buildroot] [Bug 12316] tzdata fails to install with empty "default local time"

https://bugs.busybox.net/show_bug.cgi?id=12316

--- Comment #1 from Andrew Trapani <[email protected]> --- Created attachment 8281
--> https://bugs.busybox.net/attachment.cgi?id=8281&action=edit
Config with Etc/UTC installed (tzdata completes)

.config file saved from menuconfig with default local time set to Etc/UTC

Warning: This config references local paths and to local things, and won't build for you.

Signature · 2 lines
You are receiving this mail because:
You are on the CC list for the bug.
#2 lore raw

[Buildroot] [Bug 12316] tzdata fails to install with empty "default local time"

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=12316

Yann E. MORIN <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

           Assignee|unassigned at buildroot.uclibc |yann.morin.1998 at free.fr
                   |.org                        |
             Status|NEW                         |ASSIGNED
                 CC|                            |yann.morin.1998 at free.fr

--- Comment #2 from Yann E. MORIN <[email protected]> --- Andrew,
Thanks for the report.

I just sent a patch that I believe handles this case:

    https://patchwork.ozlabs.org/patch/1196072/

Care to test that, and report, please?

Regards,
Yann E. MORIN.

Signature · 2 lines
You are receiving this mail because:
You are on the CC list for the bug.
#4 lore raw

[Buildroot] [Bug 12316] tzdata fails to install with empty "default local time"

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=12316

--- Comment #4 from Andrew Trapani <[email protected]> --- I replied to the email, but it didn't respond here. Inconvenient....

Thank Yann,

(This is my first time with a patch)

How to make sure it re-builds tzdata? Or maybe it worked?

Looks like the "mbox" button gives me a .patch file on the webpage. Excellent

I could add it to "br2-patches" and it gets used when I go to menuconfig:
Applying patch:
system-allow-not-setting-a-default-system-wide-time-zone.patch... patching file package/tz/tz.mk
patching file package/tzdata/tzdata.mk
Hunk #1 succeeded at 25 (offset -1 lines).
Hunk #2 succeeded at 47 (offset -1 lines).
patching file system/Config.in
Hunk #1 succeeded at 481 (offset -13 lines).
Removing intermediate container e9bde13f6ee5
---> 8bc39f5e0e49

1. Copy ".patch" file into br2-patches
2. Go to menuconfig.
3. Note the patch is actually applied
4. Go to System Configuration
5. Modify "default local time"
6. Change from "Etc/UTC" to empty.
7. F6 to save and F9 to exit
8. Note: No errors on save and exit
9. Start the build and save all output to a file (stdout and stderr)
10. Wasn't able to find "tzdata" in the output

Signature · 2 lines
You are receiving this mail because:
You are on the CC list for the bug.
#5 lore raw

[Buildroot] [Bug 12316] tzdata fails to install with empty "default local time"

In reply to bugzilla at busybox.net

https://bugs.busybox.net/show_bug.cgi?id=12316

Thomas Petazzoni <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

         Resolution|---                         |FIXED
             Status|ASSIGNED                    |RESOLVED

--- Comment #5 from Thomas Petazzoni <[email protected]> --- Fixed by
https://git.buildroot.org/buildroot/commit/?id=0fb87516a49629901f5fe280cd08c9fdcf0eea24.
Thanks!

Signature · 2 lines
You are receiving this mail because:
You are on the CC list for the bug.