Drush is failing to install: Your requirements could not be resolved to an installable set of packages - drush

I've got Composer installed globally according to the instructions given on https://getcomposer.org/doc/00-intro.md#globally and then tried to install drush. Unfortunately, drush is failing to install giving the following error:
composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for symfony/console v3.0.1 -> satisfiable by symfony/console[v3.0.1].
- symfony/console v3.0.1 requires php >=5.5.9 -> your PHP version (5.4.16) or value of "config.platform.php" in composer.json does not satisfy that requirement.
Problem 2
- symfony/console v3.0.1 requires php >=5.5.9 -> your PHP version (5.4.16) or value of "config.platform.php" in composer.json does not satisfy that requirement.
- psy/psysh v0.6.1 requires symfony/console ~2.3.10|^2.4.2|~3.0 -> satisfiable by symfony/console[v3.0.1].
- Installation request for psy/psysh v0.6.1 -> satisfiable by psy/psysh[v0.6.1].
even though the http://docs.drush.org/en/master/install lists:
Drush 8 master PHP 5.4.5+
My environment is:
CentOS Linux release 7.2.1511 (Core)
php -v
PHP 5.4.16 (cli) (built: Jun 23 2015 21:17:27)
Copyright (c) 1997-2013 The PHP Group
Zend Engine v2.4.0, Copyright (c) 1998-2013 Zend Technologies
and unfortunately I can not upgrade PHP because I need to strictly follow RHEL/CentOS official versions.
Then I decided to give a try to Drush 7.x branch and unfortunately it is also giving:
composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for symfony/console v3.0.1 -> satisfiable by symfony/console[v3.0.1].
- symfony/console v3.0.1 requires php >=5.5.9 -> your PHP version (5.4.16) or value of "config.platform.php" in composer.json does not satisfy that requirement.
Problem 2
- symfony/console v3.0.1 requires php >=5.5.9 -> your PHP version (5.4.16) or value of "config.platform.php" in composer.json does not satisfy that requirement.
- psy/psysh v0.6.1 requires symfony/console ~2.3.10|^2.4.2|~3.0 -> satisfiable by symfony/console[v3.0.1].
- Installation request for psy/psysh v0.6.1 -> satisfiable by psy/psysh[v0.6.1].
What should I do in this situation?

Have you tried it like this? Do this for the latest HEAD version:
composer global require drush/drush:dev-master
Do this if you want a specific version, for example the latest release of version 7:
composer global require drush/drush:7.*

Related

Failed dependencies error during installation of neo4j on Centos7

I'm trying to install community version of neo4j server.
My server is running Centos7
$ hostnamectl
Operating System: CentOS Linux 7 (Core)
CPE OS Name: cpe:/o:centos:centos:7
Kernel: Linux 3.10.0-1160.80.1.el7.x86_64
Architecture: x86-64
I have jdk-17_linux-x64_bin.rpm installed.
When I run
rpm -ivh neo4j-5.3.0-1.noarch.rpm
I get the following error message:
error: Failed dependencies:
cypher-shell >= 5.0 is needed by neo4j-5.3.0-1.noarch
cypher-shell < 6.0 is needed by neo4j-5.3.0-1.noarch
Searching for "cypher-shell >= 5.0 " online returns 0 results.
What am I missing?
Thank you
As reported at the link neo4j.com/docs/operations-manual/current/installation/linux/rpm "It is important to note that using this method will mean that the offline machine will not receive the dependencies that are normally downloaded and installed automatically when using yum for installing Neo4j; Neo4j Cypher Shell and Java". So you have to download cypher-shell RPM at the link neo4j.com/download-center/#cypher-shell and install it before neo4j

OAuth issue on HostGator

I am having an issue with my website. I use HostGator and on 8/26/21 they updated
my .htaccess file and pointed to a different version of PHP than what I previously
had. This also happened back in January but I was able to revert to the version
of php I was previously using and resolved the issue myself. This time around that fix is
not working. Two major components of my website that are no longer working are:
OAuth
the following line in my php scripts (I can no longer send emails)
require_once "Mail.php";
OAuth issue
Back in 2015 when I originally started using OAUTH, I merely had to add the following line in my php.ini file
extension=oauth.so
OAuth is no listed as one of the php modules in HostGator but that has always been the case
https://www.hostgator.com/help/article/php-modules
When I load any webpage, I get the following error message in error_log even though I have reverted back to the previous version of PHP
PHP Startup: Unable to load dynamic library '/opt/cpanel/ea php56/root/usr/lib64/php/modules/oauth.so'/opt/cpanel/ea-php56/root/usr/lib64/php/modules/oauth.so:cannot open shared object file:
No such file or directory in Unknown on line 0
I tried using "PHP PEAR Packages" in cPanel to add OAuth. I used the following steps.
I searched for "oauth" in Find a “PHP Extensions and Applications Package”
I found "HTTP_OAuth (0.3.2)" PEAR implementation of the OAuth 1.0a specification
I clicked on "Install"
It failed. I got the following
WARNING: "pear/Console_Getopt" is deprecated in favor of "pear/Console_GetoptPlus"
pear/HTTP_OAuth can optionally use PHP extension "pecl_http" (version >= 1.6.0)
pear/PEAR requires PEAR Installer (version >= 1.10.1), installed version is 1.9.5
pear/PEAR dependency package "pear/Archive_Tar" installed version 1.4.14 is not the recommended version 1.4.4, but may be compatible, use --force to install
pear/HTTP_OAuth requires package "pear/PEAR" (version >= 1.4.0)
pear/HTTP_Request2 requires package "pear/PEAR" (version >= 1.9.2)
pear/Cache_Lite requires package "pear/PEAR" (version >= 1.10.1)
No valid packages found
install failed
I then tried to install PEAR (1.10.13) PEAR Base System. I used the following steps.
I searched for "PEAR" in Find a “PHP Extensions and Applications Package”
I found PEAR (1.10.13) PEAR Base System
I clicked on "Install"
It failed. I got the following
WARNING: "pear/Console_Getopt" is deprecated in favor of "pear/Console_GetoptPlus"
pear/PEAR requires PEAR Installer (version >= 1.10.1), installed version is 1.9.5
pear/PEAR dependency package "pear/Archive_Tar" installed version 1.4.14 is not the recommended version 1.4.4, but may be compatible, use --force to install
No valid packages found
install failed
I then did some research. I was going to attempt to install this locally in my php folder in my home directory. I used the following steps.
I downloaded "oauth-1.0.0.tgz" from http://pecl.php.net/package/oauth
I uploaded "oauth-1.0.0.tgz" to my php folder in my home directory (I confirmed this by checking the Installed PHP Extension(s) and Application(s)in the directory)
I then input "oauth-1.0.0.tgz" (without quotes) in the Install a PHP Extensions and Applications Package in PHP PEAR Packages and clicked "Install Now"
It failed. I got the following:
No releases available for package "pear.php.net/oauth" - package pecl/oauth can be installed with "pecl install oauth"
install failed
At this point I am stuck. This is beyond my current skill set.
Mail issue
the following line in my php scripts (I can no longer send emails)
require_once "Mail.php";
I get the following message in my error log
PHP Fatal error: require_once(): Failed opening required 'Mail.php' (include_path='.:/opt/cpanel/ea-php56/root/usr/share/pear')
Whatever fixes the OAuth issue should be similar to this fix as it is also a PEAR module.
oauth is a pecl package, and your pear web interface probably only supports pear packages, but not pecl packages - this is why you get " No releases available for pear.php.net/oauth". Nothing you can do there on your own.
HTTP_OAuth is a pear package, but it requires Cache_Lite, which requires PEAR 1.10.0+, and your web server only has pear 1.9.5.
Upgrading the pear base system does not work, because the pear installer on that web server is also stuck on an older version.
You're lost there. The administrator would need to upgrade pear to 1.10.0+, then you could install http_oauth.

Cypher shell not installable (Ubuntu 16.04)

On Ubuntu 16.04, I've added the package repo for Neo4j (http://debian.neo4j.org/), but when I try to do sudo apt-get upgrade neo4j I get:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
neo4j : Depends: cypher-shell but it is not installable
E: Broken packages
I've tried to find the package repo where cypher-shell resides, but to no avail. Where is it?
Thanks for reporting this. We have now released cypher-shell to the repo and Neo4j 3.1.4 installs successfully.

How to install an older 1.3 version of Symfony framework using Composer or PEAR tools?

How to install an older 1.3 version of Symfony framework using Composer or PEAR tools?
The same problem with older Zend and other frameworks. I need an old Symfony framework for running codes from books and tutorials.
Symfony 1 via Pear
required: PHP with PEAR installed
Add Symfony's PEAR archive: pear channel-discover pear.symfony-project.com
To find out the version number
browse http://pear.symfony-project.com/
please note that the version links allow manual downloads, e.g. http://pear.symfony-project.com//get/symfony-1.3.0.tgz
or pear remote-list -c symfony
Install
pear install symfony/symfony
or to install a specific version, like you requested: pear install symfony/symfony-1.3.0
Symfony 1 via Composer
The Composer repo for Symfony1 is https://packagist.org/packages/symfony/symfony1
In order to install v1.3.19 add the following line to your composer.json's require section:
"symfony/symfony1": "1.3.19"
or for latest v1 "symfony/symfony1": "1.*"
Zend Framework 1 via Composer
The Composer repo for ZF1 is https://packagist.org/packages/zendframework/zendframework1
In order to install v1.12.0 add the following line to your composer.json's require section:
"zendframework/zendframework1": "1.12.0"
or latest v1 "zendframework/zendframework1": "1.*"

Grails on Ubuntu 12.10

I am installing Grails on Ubuntu 12.10, using the instructions here, but an getting an error on the 3rd step, as outlines below.
sudo add-apt-repository ppa:groovy-dev/grails
sudo apt-get update
sudo apt-get install grails-ppa
The error I get is shown below. I have the Sun JDK installed, and JAVA_HOME is set, and JAVA_HOME/bin is on the path.
Can someone suggest things to try to resolve this?
/home/edgecase> $ sudo apt-get install grails-ppa
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
default-jre-headless:i386 : Depends: openjdk-7-jre-headless:i386 (>= 7~u3-2.1) but it is not going to be installed
openjdk-7-jre:i386 : Depends: openjdk-7-jre-headless:i386 (= 7u7-2.3.2a-1ubuntu1) but it is not going to be installed
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.
/home/edgecase> $ java -version
java version "1.6.0_39"
Java(TM) SE Runtime Environment (build 1.6.0_39-b04)
Java HotSpot(TM) 64-Bit Server VM (build 20.14-b01, mixed mode)
We need to remove those instructions from the site since the PPA isn't being maintained. Use http://gvmtool.net/ instead.
YES please remove the PPA instructions with GVM, I wasted a lot of time before I found this

Resources