kohler / gifsicle

Create, manipulate, and optimize GIF images and animations
http://www.lcdf.org/gifsicle/
GNU General Public License v2.0
3.77k stars 239 forks source link

Script issue: `autoreconf: command not found` #177

Closed attornai closed 2 years ago

attornai commented 2 years ago

Having this issue when installing a package that uses gifsicle as a dependency. Error log below:

npm i vite-plugin-imagemin@latest                                                                                         9%   780 Mbps  ─╯
npm ERR! code 1
npm ERR! path /Users/yhafez/Documents/Web Projects/AAI/view/node_modules/gifsicle
npm ERR! command failed
npm ERR! command sh -c node lib/install.js
npm ERR! compiling from source
npm ERR! Response code 404 (Not Found)
npm ERR! gifsicle pre-build test failed
npm ERR! Error: Command failed: /bin/sh -c autoreconf -ivf
npm ERR! /bin/sh: autoreconf: command not found
npm ERR! 
npm ERR! 
npm ERR!     at /Users/yhafez/Documents/Web Projects/AAI/view/node_modules/bin-build/node_modules/execa/index.js:231:11
npm ERR!     at runMicrotasks (<anonymous>)
npm ERR!     at processTicksAndRejections (node:internal/process/task_queues:96:5)
npm ERR!     at async Promise.all (index 0)

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/yhafez/.npm/_logs/2021-11-24T17_33_44_785Z-debug.log

Looks like the issue is with autoreconf.

attornai commented 2 years ago

Resolved using this response: https://github.com/imagemin/imagemin-mozjpeg/issues/11#issuecomment-221399405

brew install automake autoconf libtool and try again.

Looks like autoreconf is a tool that needs to be installed on your local machine for the install to work. Keeping this issue available for reference for others getting this error.

awxiaoxian2020 commented 2 years ago

How about Windows?