@@ -1918,11 +1918,7 @@ exec "$@"
19181918 }
19191919
19201920 // Log final configure command for debugging
1921- // Add --host flag on macOS to force cross-compilation and skip problematic runtime tests
1922- if ( config . platform === 'darwin' ) {
1923- const hostArch = config . arch === 'arm64' ? 'aarch64' : 'x86_64'
1924- configureArgs . push ( `--host=${ hostArch } -apple-darwin` )
1925- }
1921+ // Note: Removed --host flag that was causing cross-compilation issues and corrupted binaries
19261922
19271923 log ( `🔧 Final configure args: ${ configureArgs . join ( ' ' ) } ` )
19281924
@@ -2028,10 +2024,8 @@ export ac_cv_func_iconv_broken=no
20282024export php_cv_func_iconv_works=yes
20292025export ac_cv_iconv_supports_errno=yes
20302026export php_cv_iconv_errno_support=yes
2031- # Ensure the configure script thinks it's in cross-compilation mode
2032- export cross_compiling=yes
2033- export host_alias=\${host_alias:-\$(uname -m)-apple-darwin}
2034- export build_alias=\${build_alias:-\$(uname -m)-apple-darwin}
2027+ # Note: Removed cross-compilation variables to allow native compilation
2028+ # This prevents the "cannot run C compiled programs" configure error
20352029
20362030# iconv is required for Laravel/Composer - must not be disabled
20372031# Force the configure script to completely skip the errno runtime test
@@ -2191,10 +2185,8 @@ export ac_cv_func_iconv_broken=no
21912185export php_cv_func_iconv_works=yes
21922186export ac_cv_iconv_supports_errno=yes
21932187export php_cv_iconv_errno_support=yes
2194- # Ensure the configure script thinks it's in cross-compilation mode
2195- export cross_compiling=yes
2196- export host_alias=\${host_alias:-\$(uname -m)-apple-darwin}
2197- export build_alias=\${build_alias:-\$(uname -m)-apple-darwin}
2188+ # Note: Removed cross-compilation variables to allow native compilation
2189+ # This prevents the "cannot run C compiled programs" configure error
21982190
21992191# iconv is required for Laravel/Composer - must not be disabled
22002192# Force the configure script to completely skip the errno runtime test
0 commit comments