简体   繁体   English

如何修复 PHP 警告:PHP 启动:无法加载动态库“xxx/xxx/yaf.so”?

[英]How to fix PHP Warning: PHP Startup: Unable to load dynamic library 'xxx/xxx/yaf.so'?

[26-Nov-2021 21:49:17 Asia/Shanghai] PHP Warning: PHP Startup: Unable to load dynamic library '/Applications/MAMP/bin/php/php5.6.40/lib/php/extensions/no-debug-non-zts-20131226/yaf.so' - dlopen(/Applications/MAMP/bin/php/php5.6.40/lib/php/extensions/no-debug-non-zts-20131226/yaf.so, 0x0009): tried: '/Applications/MAMP/bin/php/php5.6.40/lib/php/extensions/no-debug-non-zts-20131226/yaf.so' (mach-o file, but is an incompatible architecture (have 'arm64', need 'x86_64')), '/usr/lib/yaf.so' (no such file) in Unknown on line 0 [26-Nov-2021 21:49:17 Asia/Shanghai] PHP 警告:PHP 启动:无法加载动态库'/Applications/MAMP/bin/php/php5.6.40/lib/php/extensions/no非zts-20131226/yaf.so'-dlopen(/Applications/MAMP/bin/php/php5.6.40/lib/php/extensions/no-debug-non-zts-20131226/yaf.so,0x0009):尝试: '/Applications/MAMP/bin/php/php5.6.40/lib/php/extensions/no-debug-non-zts-20131226/yaf.so' (mach-o 文件,但架构不兼容(有 'arm64 ', 需要 'x86_64')), '/usr/lib/yaf.so' (没有这样的文件) 在第 0 行的 Unknown

You are loading the incorrect version for your PHP Version.您正在为 PHP 版本加载不正确的版本。 if this is Yet Another Framework You can only use this on the version of PHP is created for.如果这是另一个框架,您只能在创建 PHP 的版本上使用它。 for example if your PHP Version is 5.3 You would need a yaf.so to match PHP 5.3例如,如果您的 PHP 版本是 5.3,您将需要 yaf.so 来匹配 PHP 5.3

Looking on there GIT this is a 5.2 build, so your PHP Version needs to match this.在那里看 GIT 这是一个 5.2 版本,所以你的 PHP 版本需要匹配这个。

Personally i would ditch the 5.3 you are running and install 7.0.就我个人而言,我会放弃您正在运行的 5.3 并安装 7.0。 5.3 is very dated, pointless developing anything based on this. 5.3 非常过时,基于此开发任何东西毫无意义。

When you have the right version, Place this inside your ext folder in PHP.当您拥有正确的版本时,将其放在 PHP 的 ext 文件夹中。 Edit your PHP.ini file add in:编辑您的 PHP.ini 文件添加:

extension=yaf.so

Ensure your extension_dir is configured correctly too:确保您的 extension_dir 也配置正确:

extension_dir = "ext"

your yaf should be in the same folder as the extension dir, just ensure extension is built for the PHP version you are using, they are not cross compatible你的 yaf 应该和扩展目录在同一个文件夹中,只要确保扩展是为你正在使用的 PHP 版本构建的,它们不是交叉兼容的

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 警告:PHP启动:无法加载动态库apc.so - Warning: PHP Startup: Unable to load dynamic library apc.so 如何修复 PHP 警告:PHP 启动:无法加载动态库 'ext\\\\php_curl.dll'? - How to fix PHP Warning: PHP Startup: Unable to load dynamic library 'ext\\php_curl.dll'? 如何解决PHP警告:PHP启动:无法加载动态库'php_ffmpeg.dll' - How to fix PHP warning: PHP Startup: Unable to load dynamic library 'php_ffmpeg.dll' 如何修复“PHP 警告:PHP 启动:无法加载动态库‘mongodb’” - How do I fix "PHP Warning: PHP Startup: Unable to load dynamic library 'mongodb' " 警告:PHP 启动:无法加载动态库 - Warning: PHP Startup: Unable to load dynamic library PHP警告:PHP启动:无法加载动态库'/usr/lib/php/20151012/mysql.so' - PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/20151012/mysql.so' PHP警告:PHP启动:无法加载动态库'/usr/lib/php/20151012/gd.so' - PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/20151012/gd.so' PHP 警告:PHP 启动:无法加载动态库 '/usr/lib/php/20151012/msqli.so' - PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/20151012/msqli.so' 如何修复 PHP 启动:无法加载动态库? - How to fix PHP Startup: Unable to load dynamic library? PHP警告:PHP启动:无法加载动态库imagic.so - PHP Warning: PHP Startup: Unable to load dynamic library imagic.so
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM