Laravel : Your requirements could not be resolved

2020-07-14 09:10发布

I am trying to install Laravel in local system and i am getting error.

OS : ubuntu 12.04 LTS

Webserver : Nginx

PHP : PHP 5.3.10

step 1 :

$ git clone https://github.com/laravel/laravel.git my_project

step2 :

my_project$ composer install

I am getting following error.

Loading composer repositories with package information
Installing dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - laravel/framework v4.2.1 requires php >=5.4.0 -> no matching package found.
    - laravel/framework v4.2.0 requires php >=5.4.0 -> no matching package found.
    - Installation request for laravel/framework 4.2.* -> satisfiable by laravel/framework[v4.2.0, v4.2.1].

Potential causes:
 - A typo in the package name
 - The package is not available in a stable-enough version according to your minimum-stability setting
   see <https://groups.google.com/d/topic/composer-dev/_g3ASeIFlrc/discussion> for more details.

Read <http://getcomposer.org/doc/articles/troubleshooting.md> for further common problems.

标签: php laravel-4
3条回答
Juvenile、少年°
2楼-- · 2020-07-14 09:51

You can also solve this by upgrading your php to version 5.4.* or 5.5.* :)

查看更多
爷、活的狠高调
3楼-- · 2020-07-14 10:03

Tip for those starting out with Laravel. I solved the problem above by upgrading my PHP. Laravel requires PHP >= 5.4 http://laravel.com/docs/4.2/installation#server-requirements

查看更多
家丑人穷心不美
4楼-- · 2020-07-14 10:08

Open your composer.json file and change framework version to the following:

"laravel/framework": "4.0.*"

instead of

"laravel/framework": "4.2.*"
查看更多
登录 后发表回答