为了账号安全,请及时绑定邮箱和手机立即绑定

无法在Ubuntu 18中安装Laravel望远镜

无法在Ubuntu 18中安装Laravel望远镜

PHP
慕丝7291255 2021-05-08 14:09:44
我正在Laravel 5.8中创建一个新项目,我也想安装Telescope,但是当我在项目中执行命令时:composer require laravel/telescope输出:./composer.json has been updated Loading composer repositories with package information Updating dependencies (including require-dev) Your requirements could not be resolved to an installable set of packages.  Problem 1    - laravel/telescope 2.0.x-dev requires moontoast/math ^1.1 -> satisfiable by moontoast/math[1.1.0, 1.1.1, 1.1.2].    - laravel/telescope v2.0 requires moontoast/math ^1.1 -> satisfiable by moontoast/math[1.1.0, 1.1.1, 1.1.2].    - laravel/telescope v2.0.1 requires moontoast/math ^1.1 -> satisfiable by moontoast/math[1.1.0, 1.1.1, 1.1.2].    - laravel/telescope v2.0.2 requires moontoast/math ^1.1 -> satisfiable by moontoast/math[1.1.0, 1.1.1, 1.1.2].    - laravel/telescope v2.0.3 requires moontoast/math ^1.1 -> satisfiable by moontoast/math[1.1.0, 1.1.1, 1.1.2].    - laravel/telescope v2.0.4 requires moontoast/math ^1.1 -> satisfiable by moontoast/math[1.1.0, 1.1.1, 1.1.2].    - moontoast/math 1.1.2 requires ext-bcmath * -> the requested PHP extension bcmath is missing from your system.    - moontoast/math 1.1.1 requires ext-bcmath * -> the requested PHP extension bcmath is missing from your system.    - moontoast/math 1.1.0 requires ext-bcmath * -> the requested PHP extension bcmath is missing from your system.    - Installation request for laravel/telescope ^2.0 -> satisfiable by laravel/telescope[2.0.x-dev, v2.0, v2.0.1, v2.0.2, v2.0.3, v2.0.4].  To enable extensions, verify that they are enabled in your .ini files:如何安装缺少的依赖项?我正在使用PHP 7.2和ubuntu 18.04.2。
查看完整描述

1 回答

?
达令说

TA贡献1821条经验 获得超6个赞

您将必须安装bcmath扩展程序。在您的情况下,可以通过运行

sudo apt-get install php7.2-bcmath

sudo apt-get install php7.1-bcmath 如果您有PHP 7.1

然后再次运行require命令。


查看完整回答
反对 回复 2021-05-14
  • 1 回答
  • 0 关注
  • 167 浏览

添加回答

举报

0/150
提交
取消
意见反馈 帮助中心 APP下载
官方微信