[Buildroot] [PATCH v3 09/10] package/flutter-gallery: fix build options

Yann E. MORIN yann.morin.1998 at free.fr
Sat Jan 20 21:56:23 UTC 2024


ADam, All,

On 2024-01-17 15:50 -0700, Adam Duskett spake thusly:
> As the flutter-gallery package is a reference package for users wishing to use
> Flutter for their UX with Buildroot, this package must have the correct build
> options. Indeed, this package currently starts and runs, but only because of
> the 0001-remove-GetStorage.patch. Through testing, flutter-gallery fails to
> run during the following scenario:
>   - The xdg-user-dirs package is ported and present.
>   - flutter-gallery depends on xdg-user-dirs.
>   - The 0001-remove-GetStorage.patch file is removed.
> 
> After extensive testing and comparing the current build arguments against what
> the meta-flutter repository for Yocto passes to all of the applications that
> inherit flutter-app, it is clear that handling the dart_plugin_registrant.dart
> file is missing from the dart arguments in the flutter-gallery build step.
[--SNIP--]

Great commit log! This is exactly the kind of commit log that gives
confidence in the patch, as it demonstrates that the topic has been
researched, and the solution is explained, and the drawbacks identified
and justified.

I did not understand all the details of it, but the commit log really
helped me just apply the commit wihtout too much thought.

Thank you! 👍

> Signed-off-by: Adam Duskett <adam.duskett at amarulasolutions.com>
> ---
>  package/flutter-gallery/flutter-gallery.mk | 9 +++++++--
>  1 file changed, 7 insertions(+), 2 deletions(-)
> 
> diff --git a/package/flutter-gallery/flutter-gallery.mk b/package/flutter-gallery/flutter-gallery.mk
> index 50ddd9ffba..e23dc399da 100644
> --- a/package/flutter-gallery/flutter-gallery.mk
> +++ b/package/flutter-gallery/flutter-gallery.mk
> @@ -24,10 +24,15 @@ endef
>  
>  define FLUTTER_GALLERY_BUILD_CMDS
>  	cd $(@D) && \
> -		FLUTTER_RUNTIME_MODES=$(FLUTTER_ENGINE_RUNTIME_MODE) \

As we discusd on IRC, dropping FLUTTER_RUNTIME_MODES is unrelated to
this change, and although FLUTTER_RUNTIME_MODES is totally useless here,
dropping it should be part of another cleanup.

Applied to master with FLUTTER_RUNTIME_MODES restored, thanks.

Regards,
Yann E. MORIN.

> -		$(HOST_FLUTTER_SDK_BIN_DART_BIN) package:gallery/main.dart && \
> +		$(HOST_FLUTTER_SDK_BIN_DART_BIN) \
> +			-Dflutter.dart_plugin_registrant=file://$(@D)/.dart_tool/flutter_build/dart_plugin_registrant.dart \
> +			--source file://$(@D)/.dart_tool/flutter_build/dart_plugin_registrant.dart \
> +			--source package:flutter/src/dart_plugin_registrant.dart \
> +			--native-assets $(@D)/.dart_tool/flutter_build/*/native_assets.yaml \
> +			package:gallery/main.dart && \
>  		$(HOST_FLUTTER_SDK_BIN_ENV) $(FLUTTER_ENGINE_GEN_SNAPSHOT) \
>  			--deterministic \
> +			--obfuscate \
>  			--snapshot_kind=app-aot-elf \
>  			--elf=libapp.so \
>  			.dart_tool/flutter_build/*/app.dill
> -- 
> 2.43.0
> 
> _______________________________________________
> buildroot mailing list
> buildroot at buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'



More information about the buildroot mailing list