yarn install --no-bin-links 后一直显示waiting...

错误现象:

Laravel入门教程中有一个语句:

>yarn install --no-bin-links

运行后显示如下信息:

vagrant@homestead:~/Code/sample$ yarn install --no-bin-links

yarn install v0.27.5

info No lockfile found.

[1/4] Resolving packages...

warning laravel-mix > img-loader > imagemin-gifsicle > gifsicle > bin-build > do wnload > gulp-decompress > [email protected]: gulp-util is deprecated - replace it , following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5

[2/4] Fetching packages...

warning [email protected]: The platform "linux" is incompatible with this module.

info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.

[3/4] Linking dependencies...

[4/4] Building fresh packages...

[-/6] ⠂ waiting...

[-/6] ⠄ waiting...

[3/6] ⠄ mozjpeg: ℹ compiling from source

[-/6] ⠄ waiting...

[-/6] ⠄ waiting...

解决办法:

安装libpng16-dev

由于我的系统是CentOS,采用以下方法安装:

>wget http://prdownloads.sourceforge.net/libpng/libpng-1.5.4.tar.gz?download

>tar xzf libpng-1.5.4.tar.gz

>cd libpng-1.5.4

>./configure --prefix=/usr/local/libpng

>make

>make install

然后再按照教程中的步骤进行安装

>yarn install --no-bin-links

>yarn add cross-env

你可能感兴趣的:(Laravel笔记)