question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Npm build fails in CentOS 5.11 while compiling optipng

See original GitHub issue

I am trying to install grunt-contrib-imagemin 0.9.1. I am getting the following error:

> node lib/install.js


     warn : The `optipng` binary doesn't seem to work correctly
     warn : optipng pre-build test failed
     info : compiling from source
    error : Error: Command failed: 
    at ChildProcess.exithandler (child_process.js:637:15)
    at ChildProcess.EventEmitter.emit (events.js:98:17)
    at maybeClose (child_process.js:743:16)
    at Process.ChildProcess._handle.onexit (child_process.js:810:5)

The following are the enviroment details:

OS: CentOS 5.11
node version: v0.10.26
npm version: 2.1.7

Previously I had tried with some older version of the grunt package, and it failed in installing gifsicle too. But after updating to 0.9.1 those issues got solved.

Please show me a way out, I am stuck with this. Thanks a lot in advance.

Issue Analytics

  • State:closed
  • Created 9 years ago
  • Comments:13 (5 by maintainers)

github_iconTop GitHub Comments

5reactions
uniquelaucommented, Jan 6, 2017

On Alpine Linux I’m having to do:

apk add --no-cache zlib zlib-dev libpng libpng-dev libwebp libwebp-dev libjpeg-turbo libjpeg-turbo-dev nasm build-base automake autoconf file && npm install

2reactions
rmldskycommented, Feb 25, 2015

To people facing this problem, check if you have libpng-dev (or libpng-devel depending on Linux distro) installed on your system.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Gradle deploy fails while running imagemin:dist
Hi I am trying to install Openspecimen on CentOS 5.8. While issuing the command deploy, it exits with following error: Done, without errors....
Read more >
"Unknown system error -86" error when installing imagemin ...
1. Use a supported imagemin package. The following imagemin packages will install on Apple Silicon: PNG: imagemin-oxipng · imagemin-zopfli.
Read more >
Fix "Error: pngquant failed to build, make sure that libpng-dev ...
I kept getting an error message “Error: pngquant failed to build, make sure that libpng-dev is installed” while trying to build a Nodejs ......
Read more >
npm not installing dependencies recursively, npm run dev ...
The `/home/vagrant/tatts/node_modules/mozjpeg/vendor/cjpeg` binary doesn't seem to work correctly ? mozjpeg pre-build test failed ? compiling from source ?
Read more >
Considerations in adopting RHEL 8 Red Hat Enterprise Linux 8
The compile-time support for wireless extensions in wpa_supplicant is disabled ... When a zone containing a higher TTL is loaded, the load fails....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found