php

解决composer更新依赖php版本冲突

2023-09-13

composer install报错

Your requirements could not be resolved to an installable set of packages.

Problem 1
   - Installation request for league/flysystem 1.0.49 -> satisfiable by league/flysystem[1.0.49].
   - league/flysystem 1.0.49 requires ext-fileinfo * -> the requested PHP extension fileinfo is missing from your system.
 Problem 2
   - league/flysystem 1.0.49 requires ext-fileinfo * -> the requested PHP extension fileinfo is missing from your system.
   - laravel/framework v5.7.22 requires league/flysystem ^1.0.8 -> satisfiable by league/flysystem[1.0.49].
   - Installation request for laravel/framework v5.7.22 -> satisfiable by laravel/framework[v5.7.22].

To enable extensions, verify that they are enabled in your .ini files:
   - /usr/local/php/etc/php.ini
 You can also run php --ini inside terminal to see which files are used by PHP in CLI mode

解决方法:

composer install --ignore-platform-reqs 或者 composer update --ignore-platform-reqs