Key updates: - README: comprehensive distro comparison table (spaetzle vs dumpling-wayland) - Recommend dumpling-wayland (glibc) for Qt/GUI applications - spaetzle (musl) explicitly blocks Qt: SKIP_RECIPE[tq-image-qt6] - Both distros are 2038-safe (glibc 2.39 and musl 1.2+ both use 64-bit time_t) - Updated 2038 analysis to cover both C library options - Updated license tables with both glibc and musl entries - Fixed remaining config references (imx → mainline) - Added image availability matrix per distro - Corrected package versions to match Scarthgap 5.0.11
3.5 KiB
3.5 KiB
2038 Compliance Analysis – TQMa6UL
Overview
The Year 2038 problem (Y2K38) occurs when a signed 32-bit integer used for
Unix timestamps overflows on 2038-01-19 03:14:07 UTC. This affects all
32-bit ARM systems using traditional 32-bit time_t.
Architecture
┌─────────────────────────────────────┐
│ Application Layer │
│ (all userspace uses 64-bit t) │
├─────────────────────────────────────┤
│ C Library │
│ glibc 2.39: 64-bit time_t (Y2038) │
│ musl 1.2+: 64-bit time_t (Y2038) │
├─────────────────────────────────────┤
│ Linux Kernel (Mainline 6.x) │
│ 64-bit time syscalls on ARM32 │
├─────────────────────────────────────┤
│ i.MX6 UltraLite (Cortex-A7) │
└─────────────────────────────────────┘
C Library Options
Option 1: glibc (recommended for Qt/GUI)
Distro: dumpling-wayland
Target triplet: arm-tq-linux-gnueabi
glibc provides 64-bit time_t on 32-bit ARM since version 2.34, when built
with _TIME_BITS=64 (which Yocto Scarthgap enables by default). The BSP
includes glibc 2.39.
Advantages:
- Full compatibility with third-party software
- Qt5/Qt6 support
- Broader library ecosystem
Option 2: musl (for minimal/headless)
Distro: spaetzle
Target triplet: arm-tq-linux-musleabi
musl has provided 64-bit time_t unconditionally on all 32-bit architectures
since version 1.2.0 (February 2020).
Advantages:
- Smaller footprint
- Simpler, no locale overhead
Limitations:
- Qt is blocked (
SKIP_RECIPE) - Some third-party software may not build
Kernel Support
The mainline kernel (6.x) provides:
- 64-bit time variants of all relevant syscalls (
clock_gettime64,futex_time64, etc.) CONFIG_COMPAT_32BIT_TIME=yfor backwards compatibility- ext4 timestamps beyond 2038
Compliance Matrix
| Component | glibc (dumpling) | musl (spaetzle) | 2038-safe? |
|---|---|---|---|
| Kernel | Mainline 6.x | Mainline 6.x | ✅ |
| C Library | glibc 2.39 | musl 1.2+ | ✅ |
| Userspace | 64-bit time_t | 64-bit time_t | ✅ |
| U-Boot | Mainline | Mainline | ✅ |
| Qt6 | ✅ supported | ❌ blocked | ✅ (glibc) |
Verification
After building, verify on the target:
# Check time_t size (should print 8)
cat << 'C' > /tmp/check_time.c
#include <stdio.h>
#include <time.h>
int main() { printf("sizeof(time_t) = %zu\n", sizeof(time_t)); return 0; }
C
$CC /tmp/check_time.c -o /tmp/check_time && /tmp/check_time
Risk Assessment
| Risk | Severity | Status |
|---|---|---|
| time_t overflow | Critical | ✅ Mitigated (both libc options) |
| Filesystem timestamps | Medium | ✅ ext4 supports >2038 |
| Network protocols (NTP) | Low | ✅ 64-bit aware |
| Third-party binaries | Medium | ⚠️ Must verify pre-built binaries |
| Qt5 compatibility | Medium | ⚠️ meta-qt5 not included, add manually |