Deprecated: Function get_magic_quotes_gpc() is deprecated in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 99

Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 619

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1169

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176
8000 Flutter's Android tools ignore NDK symlinks and copy files instead, leading to huge disk usage · Issue #177286 · flutter/flutter · GitHub
Nothing Special   »   [go: up one dir, main page]

Skip to content

Flutter's Android tools ignore NDK symlinks and copy files instead, leading to huge disk usage #177286

@bc-lee

Description

@bc-lee

While investigating disk space shortages, I discovered that Flutter’s Android tools package includes a large NDK copy where all symlinks have been resolved into actual files.

Normal NDK from the official Android site:

[/path/to/ndk/28.2.13676358/toolchains/llvm/prebuilt/linux-x86_64/bin]$ ls -al | grep ^l
lrwxrwxrwx.  1 user user         8 Jul 27 07:59 clang -> clang-19
lrwxrwxrwx.  1 user user         5 Jul 27 07:59 clang++ -> clang
lrwxrwxrwx.  1 user user         6 Jul 27 07:59 ld -> ld.lld
lrwxrwxrwx.  1 user user         3 Jul 27 07:59 ld64.lld -> lld
lrwxrwxrwx.  1 user user         3 Jul 27 07:59 ld.lld -> lld
lrwxrwxrwx.  1 user user         3 Jul 27 07:59 lld-link -> lld
lrwxrwxrwx.  1 user user        15 Jul 27 07:59 llvm-addr2line -> llvm-symbolizer
lrwxrwxrwx.  1 user user         7 Jul 27 07:59 llvm-dlltool -> llvm-ar
lrwxrwxrwx.  1 user user         7 Jul 27 07:59 llvm-lib -> llvm-ar
lrwxrwxrwx.  1 user user         7 Jul 27 07:59 llvm-ranlib -> llvm-ar
lrwxrwxrwx.  1 user user        12 Jul 27 07:59 llvm-readelf -> llvm-readobj
lrwxrwxrwx.  1 user user        12 Jul 27 07:59 llvm-strip -> llvm-objcopy
lrwxrwxrwx.  1 user user         7 Jul 27 07:59 llvm-windres -> llvm-rc
lrwxrwxrwx.  1 user user         3 Jul 27 07:59 wasm-ld -> lld

NDK bundled with Flutter’s Android tools:

[/path/to/flutter/engine/src/flutter/third_party/android_tools/ndk/toolchains/llvm/prebuilt/linux-x86_64/bin]$ ls -al | grep ^l
[/path/to/flutter/engine/src/flutter/third_party/android_tools/ndk/toolchains/llvm/prebuilt/linux-x86_64/bin]$ ls -al clang*
-r-xr-xr-x. 1 user user 135276024 Oct  2 04:29 clang
-r-xr-xr-x. 1 user user 135276024 Oct  2 04:29 clang++
-r-xr-xr-x. 1 user user 135276024 Oct  2 04:29 clang-19
-r-xr-xr-x. 1 user user  75759408 Oct  2 04:29 clang-check
-r-xr-xr-x. 1 user user  44910272 Oct  2 04:29 clangd
-r-xr-xr-x. 1 user user   3817168 Oct  2 04:29 clang-format
-r-xr-xr-x. 1 user user  75664920 Oct  2 04:29 clang-scan-deps
-r-xr-xr-x. 1 user user  53089504 Oct  2 04:29 clang-tidy

As shown above, clang, clang++, and clang-19 are all separate files of ~135 MB each.
In the official NDK, they are symlinks to the same file.

This means Flutter’s Android tools are effectively duplicating large binaries, inflating the NDK’s size by hundreds (if not thousands) of megabytes.

Expected behavior

NDK binaries in Flutter’s Android tools should preserve symlinks instead of copying file contents.
This would significantly reduce disk usage and improve developer experience.

Environment

Metadata

Metadata

Assignees

No one assigned

    Labels

    in triagePresently being triaged by the triage teamwaiting for customer responseThe Flutter team cannot make further progress on this issue until the original reporter responds

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0