mozjpeg-bin: mozjpeg@5.0.0 fails to build binary at postinstall

npm@5.5.1 node@8.9.0 Ubuntu 14.04.5 LTS

$ npm i mozjpeg

> mozjpeg@5.0.0 postinstall /home/aandrosov/node_modules/mozjpeg
> node lib/install.js

  ⚠ The `/home/aandrosov/node_modules/mozjpeg/vendor/cjpeg` binary doesn't seem to work correctly
  ⚠ mozjpeg pre-build test failed
  ℹ compiling from source
  ✖ Error: autoreconf -fiv && ./configure --disable-shared --disable-dependency-tracking --with-jpeg8  --prefix="/home/aandrosov/node_modules/mozjpeg/vendor" --bindir="/home/aandrosov/node_modules/mozjpeg/vendor" --libdir="/home/aandrosov/node_modules/mozjpeg/vendor" && make -j4 && make install -j4
Command failed: autoreconf -fiv
autoreconf: Entering directory `.'
autoreconf: configure.ac: not using Gettext
autoreconf: running: aclocal --force 
autoreconf: configure.ac: tracing
autoreconf: configure.ac: not using Libtool
autoreconf: running: /usr/bin/autoconf --force
configure.ac:23: error: possibly undefined macro: AC_PROG_LIBTOOL
      If this token and others are legitimate, please use m4_pattern_allow.
      See the Autoconf documentation.
autoreconf: /usr/bin/autoconf failed with exit status: 1

    at ChildProcess.exithandler (child_process.js:275:12)
    at emitTwo (events.js:126:13)
    at ChildProcess.emit (events.js:214:7)
    at maybeClose (internal/child_process.js:925:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)

About this issue

  • Original URL
  • State: open
  • Created 6 years ago
  • Reactions: 7
  • Comments: 17

Most upvoted comments

Installing the following under Ubuntu 16.04 works for me:

sudo apt-get install autoconf libtool nasm

I have no idea. I’ve never had an npm dependency that had an npm dependency that had an npm dependency that required an entire build chain of requirements. I spent about a day trying to get it working then gave up.

VERY not happy I have to install all this crap on my build server to get it working.

I don’t feel very comfortable to read such a rude message. And I don’t even develop the tool.

Some people are thinking about it and it does not seem trivial. Maybe you can share your knowledge in #33

On Amazon EC2:

# Amazon AMI Linux
yum install autoconf automake libtool nasm

VERY not happy I have to install all this crap on my build server to get it working.

hm… CI does not like this :\

why does the pre build binary does not work in the first place?