-
Notifications
You must be signed in to change notification settings - Fork 63
Description
Invalid ELF path when running release build on Debian 12 (libapp.so not valid ELF, but debug build runs fine)
π₯ Environment
- Host OS: Debian 12
- Kernel: 6.1.118
- Target device: RK3568 (aarch64)
- Flutter-elinux version:
Flutter 3.29.3 β’ channel [user-branch] β’ Engine cf56914b32 Tools β’ Dart 3.7.2 β’ DevTools 2.42.3
π§ Build commands used
# build (fails to run)
flutter-elinux build elinux --release
flutter-elinux build elinux --debug
flutter-elinux run -d elinux-waylandβ Description of the Problem
When building a Flutter eLinux project on Debian 12,
the release build fails to start on the same device (RK3568, aarch64)
with the following runtime error:
[ERROR:flutter/shell/platform/embedder/embedder_engine.cc(226)] FlutterEngineCreateAOTData return kInvalidArguments
Invalid ELF path specified
However, the release run (flutter-elinux run -d elinux-wayland --release)
runs perfectly fine on the same system.
This indicates that the runtime environment and engine itself are functional,
but the generated release AOT binary (libapp.so) is corrupted or invalid.
π What I Observed
The generated file build/elinux/arm64/release/bundle/lib/libapp.so
does not appear to be a valid ELF shared object.
Checking it with readelf gives no valid headers or section data:
$ readelf -d lib/libapp.so
Dynamic section at offset 0x330000 contains 6 entries:
Tag Type Name/Value
0x0000000000000004 (HASH) 0x300
0x0000000000000005 (STRTAB) 0x1e8
0x000000000000000a (STRSZ) 133 (bytes)
0x0000000000000006 (SYMTAB) 0x270
0x000000000000000b (SYMENT) 24 (bytes)
0x0000000000000000 (NULL) 0x0No ELF class or architecture information is detected,
suggesting the AOT compilation or linking failed silently.
π Comparison with Debian 11
On Debian 11 using the same source code and build commands:
β
flutter-elinux build elinux --release produces a valid libapp.so
β
The release binary runs normally
β The issue only appears on Debian 12
β Expected Behavior
flutter-elinux build elinux --releaseshould generate a valid ELFlibapp.so- The release bundle should start without
Invalid ELF path specified
π« Actual Behavior
lib/libapp.sogenerated on Debian 12 is not a valid ELF file- Running the release bundle fails immediately with:
FlutterEngineCreateAOTData return kInvalidArguments Invalid ELF path specified - Debug builds run normally
π§© Steps to Reproduce
-
On Debian 12:
git clone https://github.com/sony/flutter-elinux.git cd flutter-elinux/flutter ./bin/flutter doctor -
Build release version:
flutter-elinux build elinux --release
-
Run the binary:
../sample --bundle=/flutter/bundle/