From 7812ee6b6cc08a94fbde10f15a41925efa18be25 Mon Sep 17 00:00:00 2001 From: Bernd Kuhls Date: Fri, 28 Jul 2023 19:20:26 +0200 Subject: [PATCH] package/php: force arm mode instead of Thumb mode Fix the following build failure: /tmp/ccqcLrVb.s:4053: Error: selected processor does not support `umlal r2,r1,r0,r3' in Thumb mode /tmp/ccqcLrVb.s:4076: Error: selected processor does not support `umlal r0,r3,r1,r2' in Thumb mode /tmp/ccqcLrVb.s:8644: Error: selected processor does not support `umlal r0,r3,r2,r4' in Thumb mode Fixes: http://autobuild.buildroot.net/results/1d09a0a58cbc1712416de746d57d4532df580673/ Signed-off-by: Bernd Kuhls Signed-off-by: Thomas Petazzoni (cherry picked from commit 73ddf7bf509813a1a9008fa61c8706e200340fe9) Signed-off-by: Peter Korsgaard --- package/php/php.mk | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/package/php/php.mk b/package/php/php.mk index 6a2a6ae71b..68aeceb33e 100644 --- a/package/php/php.mk +++ b/package/php/php.mk @@ -84,6 +84,13 @@ else PHP_CONF_ENV += ac_cv_func_dlopen=no ac_cv_lib_dl_dlopen=no endif +# php has some assembly function that is not present in Thumb mode: +# Error: selected processor does not support `umlal r2,r1,r0,r3' in Thumb mode +# so, we desactivate Thumb mode +ifeq ($(BR2_ARM_INSTRUCTIONS_THUMB),y) +PHP_CFLAGS += -marm +endif + PHP_CONF_OPTS += $(if $(BR2_PACKAGE_PHP_SAPI_CLI),--enable-cli,--disable-cli) PHP_CONF_OPTS += $(if $(BR2_PACKAGE_PHP_SAPI_CGI),--enable-cgi,--disable-cgi) PHP_CONF_OPTS += $(if $(BR2_PACKAGE_PHP_SAPI_FPM),--enable-fpm,--disable-fpm)