Gmp required gmp php extension

Как установить GMP на PHP7 и Ubuntu

Я получаю следующую ошибку при попытке запустить composer update на проекте SimpleSAML.

- openid/php-openid dev-master requires ext-gmp * -> the requested PHP extension gmp is missing from your system. 

Бег sudo apt-get install php5-gmp не работал и не сделал sudo apt-get install php7-gmp

Решение

Чтобы установить GMP на PHP7 в Ubuntu:

Бежать: sudo apt-get install php7.0-gmp

И добавьте следующее в php.ini:

Другие решения

sudo apt-get install php7.2-gmp 

Новый способ установки расширений в PHP 7 — написать «php-EXTENSION». В этом случае это так просто:

sudo apt-get install php-gmp 

Лучше искать с помощью package или же dependency manager установлено в машине.
За yum , вы можете искать, используя yum search gmp а затем установить.

Это даст эти результаты поиска

Loaded pluginss: extras_suggestions, langpacks, priorities, update-motd 170 packages excluded due to repository priority protections ========================================================= N/S matched: gmp ========================================================== perl-Math-BigInt-GMP.x86_64 : Math::BigInt::GMP Perl module python-gmpy2.x86_64 : Python 2 interface to GMP, MPFR, and MPC gmp.x86_64 : A GNU arbitrary precision library gmp.i686 : A GNU arbitrary precision library gmp-devel.x86_64 : Development tools for the GNU MP arbitrary precision library gmp-static.x86_64 : Development tools for the GNU MP arbitrary precision library mingw32-gmp.noarch : Cross-compiled GNU arbitrary precision library mingw64-gmp.noarch : Cross-compiled GNU arbitrary precision library perl-Math-GMP.x86_64 : High speed arbitrary size integer math php-gmp.x86_64 : A module for PHP applications for using the GNU MP library 

Теперь установите расширение с:
yum install php-gmp.x86_64

Если вы используете php 7.2 и выше, то

sudo apt-get install php7.2-gmp

или вы можете также установить bcmath расширение с помощью

sudo apt-get install php7.2-bcmath

Я рекомендую вам установить их оба, после полной установки перезагрузите apache

sudo service apache2 reload

sudo service apache2 restart

для Centos работал на меня

Источник

Saved searches

Use saved searches to filter your results more quickly

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ext-gmp is missing #1026

ext-gmp is missing #1026

Comments

Trying to install invoice ninja in Laravel Homestead (PHP 7) box and I get this error when I composer install.

«barracudanetworks/archivestream-php 1.0.3 requires ext-gmp * -> the requested PHP extension gmp is missing from your system.».

The text was updated successfully, but these errors were encountered:

@hillelcoren Is he maybe referring to the point that the guide doesn’t point out that gmp should be installed?

In their «Install Dependencies» section the installation of php5-gmp is missing. gmp probably came in as requirement at a later stage after the tutorial has been written.

I think you’re right, I’ve emailed the blog asking them to update the post.

Hi @hillelcoren, I’m facing the same problem. How can I resolve it now?

You should just need to enable ext-gmp.

I’m hitting this issue on shared hosting (yes I know, don’t use shared). Host is Dreamhost, seems gmp is enabled but still hitting this error. I can bypass it using composer’s option ignore-platform-reqs but that still doesn’t solve the issue.

On Wed., 19 Jul. 2017, 11:49 Braunson Yager, ***@***.***> wrote: I’m hitting this issue on shared hosting (yes I know, don’t use shared). Host is Dreamhost, seems gmp is enabled but still hitting this error. — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub , or mute the thread .

On Wed., 19 Jul. 2017, 12:56 Braunson Yager, ***@***.***> wrote: Yes — You are receiving this because you commented. Reply to this email directly, view it on GitHub , or mute the thread .

Just to clarify. you’ve created a phpinfo() page which shows that the gmp module is enabled but composer says it isn’t? I’m not sure what could explain that.

during composer install getting error
[RuntimeException]
Failed to clone https://github.com/gatepay/FedACHdir.git, git was not found, check that it is installed and in your PATH env.
‘git’ is not recognized as an internal or external command,
operable program or batch file.

From the error it looks like Git isn’t installed.

Note: if you use our self host zip you don’t need to use composer or git.

i have downloaded the folder and its working fine on localhost i have created user and uploaded it on server with database but when i run its loading to setup page . it should load login page . i have changed .env file but still not working . if i change manually add login to url it gives this error «Whoops, looks like something went wrong.»

Are there details about the error in storage/logs/laravel-error.log

hi, sorry for bringing this issue up. does anyone encounter this.

my php 7 in ubuntu 14.04 doesnt have gmp extension. can anyone help me?

@mohd-aidi You need to install the PHP GMP extension

Depending on what package manager you use.. sudo apt-get install php-gmp

@mohd-aidi You need to install the PHP GMP extension

Depending on what package manager you use.. sudo apt-get install php-gmp

as i mention no php-gmp or php7.1-gmp or any name associate with gmp.

apt-get install php-gmp
Reading package lists. Done
Building dependency tree
Reading state information. Done
E: Unable to locate package php-gmp

that is why i am confused.

php5.6 have gmp ext but this system required php7 and above. :`D

@mohd-aidi You’ll need to add a repository that contains PHP 7 extensions. What’s your OS? If it’s CentOS, visit this article

On Debian Buster you’d install php7.3-gmp package.

Источник

Issue

Because of this error message the requested PHP extension gmp is missing from your system I want to add the gmp extension to php 7.4 using DDEV.

First I made a .ddev/php/ folder and created a 99-gmp.ini file. Second I added extension=php_gmp.so to 99-gmp.ini

I ssh login ddev ssh and run:

sudo apt-get install php-gmp

sudo apt-get install php7.4-gmp And tried a few variants but the package isn’t found

searching for apt search php-gmp results in:

Reading package lists. DoneBuilding dependency tree Reading state information. Done E: Unable to locate package php-gmp

apt search gmp results in 3 packages, all installed already:

libgmp10/now 2:6.1.2+dfsg-4 amd64 [installed,local] Multiprecision arithmetic library

libhogweed4/now 3.4.1-1 amd64 [installed,local] low level cryptographic library (public-key cryptos)

libnettle6/now 3.4.1-1 amd64 [installed,local] low level cryptographic library (symmetric and one-way cryptos)

Looking for php7.4 extentions: apt search php7.4 For some reason gmp isn’t found?

Sorting. Done Full Text Search. Done

libapache2-mod-php7.4/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] server-side, HTML-embedded scripting language (Apache 2 module)

php7.4-bcmath/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] Bcmath module for PHP

php7.4-bz2/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] bzip2 module for PHP

php7.4-cgi/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] server-side, HTML-embedded scripting language (CGI binary)

php7.4-cli/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] command-line interpreter for the PHP scripting language

php7.4-common/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] documentation, examples and common module for PHP

php7.4-curl/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] CURL module for PHP

php7.4-fpm/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] server-side, HTML-embedded scripting language (FPM-CGI binary)

php7.4-gd/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] GD module for PHP

php7.4-intl/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] Internationalisation module for PHP

php7.4-json/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] JSON module for PHP

php7.4-ldap/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] LDAP module for PHP

php7.4-mbstring/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] MBSTRING module for PHP

php7.4-mysql/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] MySQL module for PHP

php7.4-opcache/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] Zend OpCache module for PHP

php7.4-pgsql/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] PostgreSQL module for PHP

php7.4-phpdbg/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] server-side, HTML-embedded scripting language (PHPDBG binary)

php7.4-readline/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] readline module for PHP

php7.4-soap/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] SOAP module for PHP

php7.4-sqlite3/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] SQLite3 module for PHP

php7.4-xml/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] DOM, SimpleXML, XML, and XSL module for PHP

php7.4-xmlrpc/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] XMLRPC-EPI module for PHP

php7.4-zip/now 7.4.8-1+0~20200713.23+debian10~1.gbpb2c15c amd64 [installed,local] Zip module for PHP

Project Information

PHP version: 7.4 OS: Debian 10 NFS mount enabled: false Database type: mariadb MariaDB version: 10.3

Solution

Usually, you should add packages through adding webimage_extra_packages to your configuration (see the documentation):

webimage_extra_packages: [php7.4-gmp] 

On restarting the containers using ddev restart , this configuration is applied and the package gets installed. Have you tried this?

Using this way helps to keep this package tied to the container ddev uses. While adding it to a running container (as you did) is not explicitly wrong, this package will be removed again if you change the PHP version or upgrade ddev. Through using the configuration, you can ensure that this package is installed again if the container images change.

Источник

Как установить GMP на PHP7 и Ubuntu

Что значит «не работал»? Apt-get сообщил об ошибке (php7-gmp не существует) или он установился нормально, но не помог (php5-gmp не используется php7)? Команда apt search php gmp дает вам список соответствующих пакетов, она предлагает вам установить php-gmp, если вы используете текущую версию PHP по умолчанию, или php7.0-gmp, если вы очень хотите использовать PHP версия 7.0.

8 ответов

Чтобы установить GMP на PHP7 на Ubuntu:

Выполнить: sudo apt-get install php7.0-gmp

Добавьте в php.ini следующее:

@Ganesh K вам нужно установить ту же версию GMP, что и ваш PHP. Если у вас есть несколько установок PHP на вашем компьютере, вы можете установить GMP для каждого из них.

sudo apt-get install php7.2-gmp 

Новый способ установки расширений в PHP 7 — написать «php-EXTENSION». В этом случае это так просто:

sudo apt-get install php-gmp 

Лучше искать, используя package или dependency manager установленный на машине. Для yum вы можете yum search gmp используя yum search gmp а затем установить.

Это даст эти результаты поиска

Loaded pluginss: extras_suggestions, langpacks, priorities, update-motd 170 packages excluded due to repository priority protections ========================================================= N/S matched: gmp ========================================================== perl-Math-BigInt-GMP.x86_64 : Math::BigInt::GMP Perl module python-gmpy2.x86_64 : Python 2 interface to GMP, MPFR, and MPC gmp.x86_64 : A GNU arbitrary precision library gmp.i686 : A GNU arbitrary precision library gmp-devel.x86_64 : Development tools for the GNU MP arbitrary precision library gmp-static.x86_64 : Development tools for the GNU MP arbitrary precision library mingw32-gmp.noarch : Cross-compiled GNU arbitrary precision library mingw64-gmp.noarch : Cross-compiled GNU arbitrary precision library perl-Math-GMP.x86_64 : High speed arbitrary size integer math php-gmp.x86_64 : A module for PHP applications for using the GNU MP library 

Теперь установите расширение с помощью: yum install php-gmp.x86_64

Источник

Читайте также:  Код javascript нажатие кнопки
Оцените статью