3

I want to install a bundle which has the following dependencies:

 "require": {
    "symfony/symfony": ">=2.4",
    "simplesamlphp/simplesamlphp": "dev-master"
},

When I try to do do the composer require hslavich/simplesamlphp-bundle dev-master I get the following:

Your requirements could not be resolved to an installable set of packages.  
Problem 1
    - simplesamlphp/simplesamlphp v1.13.2 requires openid/php-openid dev-master#ee669c6a9d4d95b58ecd9b6945627276807694fb as 2.2.2 -> no matching package found.
    - simplesamlphp/simplesamlphp v1.13.1 requires openid/php-openid dev-master#ee669c6a9d4d95b58ecd9b6945627276807694fb as 2.2.2 -> no matching package found.
    - simplesamlphp/simplesamlphp v1.13.0 requires openid/php-openid dev-master#ee669c6a9d4d95b58ecd9b6945627276807694fb as 2.2.2 -> no matching package found.
    - simplesamlphp/simplesamlphp v1.12.0 requires openid/php-openid dev-master#ee669c6a9d4d95b58ecd9b6945627276807694fb as 2.2.2 -> no matching package found.
    - hslavich/simplesamlphp-bundle dev-master requires simplesamlphp/simplesamlphp dev-master -> no matching package found.
    - hslavich/simplesamlphp-bundle dev-master requires simplesamlphp/simplesamlphp * -> satisfiable by simplesamlphp/simplesamlphp[v1.12.0, v1.13.0, v1.13.1, v1.13.2].
    - Installation request for hslavich/simplesamlphp-bundle dev-master -> satisfiable by hslavich/simplesamlphp-bundle[dev-master].

But if I first do composer require simplesamlphp/simplesamlphp dev-master and then composer require hslavich/simplesamlphp-bundle dev-master everything is ok.

How should the bundles composer.json file modified so that I would not need separate require for simplesamlphp dev-master?

andrius.k
  • 799
  • 1
  • 10
  • 26
  • 1
    Your minimum stability is probably set to `stable` which means that you need to specify any `dev` packages. If that is the case you could either do what you have done or change your minimum stability. – qooplmao Oct 30 '15 at 10:01

2 Answers2

1

hslavich/simplesamlphp-bundle v1.13 requires simplesamlphp/simplesamlphp 1.13

But simplesamlphp/simplesamlphp v1.13.2 requires openid/php-openid: dev-master#ee669c6a9d4d95b58ecd9b6945627276807694fb as 2.2.2

Add in your composer.json:

"hslavich/simplesamlphp-bundle": "1.*",
"openid/php-openid": "dev-master#ee669c6a9d4d95b58ecd9b6945627276807694fb"

The last line is required because openid/php-openid dev-master is not stable.

For your information, gmp PHP extension is required by penid/php-openid.

1

If you require another package, that requires another unstable (dev-master) package, you need to mention it in your composer.json:

"require": {
    "hslavich/simplesamlphp-bundle": "~1.13",
    "simplesamlphp/simplesamlphp": "dev-master"
}

Then run:

composer update
Tomas Votruba
  • 23,240
  • 9
  • 79
  • 115