【问题标题】:Trying to do composer install on project but comes up with requirements error message尝试在项目上进行 composer install 但出现需求错误消息
【发布时间】:2018-10-29 10:37:58
【问题描述】:

按照此链接的说明安装了composer:https://www.digitalocean.com/community/tutorials/how-to-install-and-use-composer-on-ubuntu-16-04

进入项目回购运行composer install,但它提出了

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

Problem 1
    - Installation request for phpunit/php-code-coverage 4.0.8 -> satisfiable by phpunit/php-code-coverage[4.0.8].
    - phpunit/php-code-coverage 4.0.8 requires ext-dom * -> the requested PHP extension dom is missing from your system.
  Problem 2
    - Installation request for phpunit/phpunit 5.7.20 -> satisfiable by phpunit/phpunit[5.7.20].
    - phpunit/phpunit 5.7.20 requires ext-dom * -> the requested PHP extension dom is missing from your system.

  To enable extensions, verify that they are enabled in your .ini files:
- /etc/php/7.2/cli/php.ini
- /etc/php/7.2/cli/conf.d/10-mysqlnd.ini
- /etc/php/7.2/cli/conf.d/10-opcache.ini
- /etc/php/7.2/cli/conf.d/10-pdo.ini
- /etc/php/7.2/cli/conf.d/20-calendar.ini
- /etc/php/7.2/cli/conf.d/20-ctype.ini
- /etc/php/7.2/cli/conf.d/20-exif.ini
- /etc/php/7.2/cli/conf.d/20-fileinfo.ini
- /etc/php/7.2/cli/conf.d/20-ftp.ini
- /etc/php/7.2/cli/conf.d/20-gettext.ini
- /etc/php/7.2/cli/conf.d/20-iconv.ini
- /etc/php/7.2/cli/conf.d/20-json.ini
- /etc/php/7.2/cli/conf.d/20-mbstring.ini
- /etc/php/7.2/cli/conf.d/20-mysqli.ini
- /etc/php/7.2/cli/conf.d/20-pdo_mysql.ini
- /etc/php/7.2/cli/conf.d/20-phar.ini
- /etc/php/7.2/cli/conf.d/20-posix.ini
- /etc/php/7.2/cli/conf.d/20-readline.ini
- /etc/php/7.2/cli/conf.d/20-shmop.ini
- /etc/php/7.2/cli/conf.d/20-sockets.ini
- /etc/php/7.2/cli/conf.d/20-sysvmsg.ini
- /etc/php/7.2/cli/conf.d/20-sysvsem.ini
- /etc/php/7.2/cli/conf.d/20-sysvshm.ini
- /etc/php/7.2/cli/conf.d/20-tokenizer.ini
  You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.

我是 Ubuntu 的新手,之前在 Windows 中没有遇到过这种情况。 这是通过 Ubuntu 安装作曲家的常见步骤吗? 我该如何解决?

【问题讨论】:

标签: php ubuntu composer-php


【解决方案1】:

如果您使用 digitalocean 作为您的主机,那么我的建议是与他们联系。我认为他们也有现场支持。

这是因为您使用的计划可能有一些限制或需要权限。

如果您要在 PC 中安装,请参阅一些用于教程的博客/网站,而不是针对任何特定设置。

【讨论】:

    猜你喜欢
    • 2015-10-09
    • 2020-12-11
    • 2021-08-15
    • 2021-06-17
    • 1970-01-01
    • 1970-01-01
    • 2021-07-23
    • 2018-09-06
    • 2015-09-06
    相关资源
    最近更新 更多