+ PACKAGES += $(subst ${comma_},${space_},${packages})
+endif
+
+export DEBCONF RPICONFIG
+
+define DEBCONF :=
+${DEBCONF}
+
+keyboard-configuration keyboard-configuration/model select Generic 105-key (Intl) PC
+keyboard-configuration keyboard-configuration/variant select English (US) - English (Macintosh)
+endef
+
+define RPICONFIG :=
+${RPICONFIG}
+
+dtoverlay=vc4-fkms-v3d,cma-256
+endef
+
+.PHONY: _debconf_selections _raspberry_config _keyboard
+_install: _debconf_selections
+_debconf_selections: ${SYSROOT}
+ printf '%s\n' "$${DEBCONF}" |chroot "$${SYSROOT}" debconf-set-selections
+
+ifdef keyboard
+ _config: _keyboard
+endif
+_keyboard: ${CFGROOT}
+ -sed -Ei 's;^XKBLAYOUT=.*$$;XKBLAYOUT="${keyboard}";;' "$${CFGROOT}/etc/default/keyboard"
+
+ifdef raspi
+ _config: _raspberry_config
+endif
+_raspberry_config: ${CFGROOT}
+ printf '%s\n' "$${RPICONFIG}" >>"$${CFGROOT}/boot/config.txt"
+
+.PHONY: _timezone _locales
+
+ifdef timezone
+ export timezone
+ PACKAGES += tzdata
+ _config: _timezone
+endif
+
+ifdef locales
+ PACKAGES += locales
+ _config: _locales