-+ /* Android does not have /etc/localtime but uses a system property for the
-+ the current timezone. There are no files under /usr/share/zoneinfo,
-+ instead a single /system/usr/share/zoneinfo/tzdata which are all zoneinfo
-+ files compiled together with the following tool:
-+ https://android.googlesource.com/platform/external/icu/+/master/tools/ZoneCompactor.java */
-+ struct tzdata_header {
-+ char version[12];
-+ uint32_t index_offset, data_offset, zonetab_offset;
-+ } __attribute__((packed)) header;
++/* Android uses a 'persist.sys.timezone' system property for the
++ * current timezone instead of a /etc/localtime file:
++ * https://android.googlesource.com/platform/ndk/+/android-2.2_r1/docs/system/libc/OVERVIEW.TXT#67
++ *
++ * There are no files under /usr/share/zoneinfo - instead a single
++ * /system/usr/share/zoneinfo/tzdata file is used which contains all
++ * files compiled together with the following tool:
++ * https://android.googlesource.com/platform/system/timezone/+/master/zone_compactor/main/java/ZoneCompactor.java
++ */
++static GBytes *
++zone_info_android (const gchar *identifier)
++{
++ char sys_timezone[PROP_VALUE_MAX];
++ GMappedFile *file;
++ gchar *tzdata;
++ gsize tzdata_length;
++ const gsize index_entry_size = 52;
++ gint32 header_index_offset, header_data_offset;
++ gint32 entry_count, current_index;
++ char* entry_name;
++ gint32 entry_offset, entry_length;
++ GBytes *zoneinfo;