imagemin / imagemin-gifsicle

Imagemin plugin for Gifsicle
MIT License
116 stars 54 forks source link

7.0.0 fails to install on linux #40

Closed fierysolid closed 2 years ago

fierysolid commented 4 years ago

The following error occurs when trying to install the latest dep of gifsicle on Linux. 6.0.1 works fine

error ./node_modules/gifsicle: Command failed.
Exit code: 1
Command: node lib/install.js
Arguments:
Directory: ./node_modules/gifsicle
Output:
⚠ Response code 404 (Not Found)
  ⚠ gifsicle pre-build test failed
  ℹ compiling from source
  ✖ Error: Command failed: /bin/sh -c autoreconf -ivf
/bin/sh: 1: autoreconf: not found
danez commented 4 years ago

I have the same.

wouterds commented 4 years ago

Can confirm, downgrading to 6.0.1 "works".

clse commented 4 years ago

Having the same issue. Bundled within gulp-imagemin.

nodeg commented 4 years ago

autoreconf is not found as the last line above suggests. autoreconf is part of autoconf, try installing autoconf and dh-autoreconf on your distribution

clse commented 4 years ago

The issue is we shouldn't have to manually install these packages. If they are necessary for this package to work, they should be dependencies.

nodeg commented 4 years ago

@melissaclausse: The packages I mentioned earlier are not npm packages, but packages that have to be installed using the operating system's package manager.

clse commented 4 years ago

Gotcha - thanks for clarifying. Still, this is fully incompatible with production builds that are not happening on my local machine. Is there anything that could fix this that would be set up as a dependency instead?

nodeg commented 4 years ago

imagemin-gifsicle depends on gifsicle-bin which removed i.a. the GNU/Linux binary files of gifsicle due to security vulnerabilites in version 5.0.0. That is why the binary has to be build from source and why you need dh-autoreconf. There is already an upstream issue opened for that: #113

janwidmer commented 3 years ago

gifsicle-bin has been updated via https://github.com/imagemin/gifsicle-bin/pull/118 and released in version 5.2.0 which should include the Linux bin files again. Therefore please adjust the dependency version to ^5.2.0 in the package json. As we are using imagemin-gifsicle, I can only close the issue #113 after getting a new release of imagemin-gifsicle