From: Christian Hergert Date: Fri, 28 Jul 2023 00:09:02 +0000 (-0700) Subject: demo: use --set-section-alignment when using objcopy X-Git-Tag: archive/raspbian/4.12.3+ds-1+rpi1~1^2^2^2~22^2~1^2~34^2 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=7cc29ce2362cd6ebc52e142b33423b3fee6a7a90;p=gtk4.git demo: use --set-section-alignment when using objcopy If we don't set the alignment then there is a chance that it ends up commonly on a 4-byte boundary and GResources will have to malloc/memcpy the static data. With --set-section-alignment (which takes a byte offset not ^2) available in objcopy >= 2.33 we ensure that expectation is met. --- diff --git a/demos/gtk-demo/meson.build b/demos/gtk-demo/meson.build index a464e6e0a8..f586a07714 100644 --- a/demos/gtk-demo/meson.build +++ b/demos/gtk-demo/meson.build @@ -206,6 +206,7 @@ if can_use_objcopy_for_resources output : 'gtkdemo_resources2.o', command : [objcopy, '--strip-all', + '--set-section-alignment', '.data=8', '--add-symbol','_g_binary_gtkdemo_resource_data=.data:0', '@INPUT@', '@OUTPUT@'])