Git Product home page Git Product logo

Comments (10)

DevSide avatar DevSide commented on June 15, 2024 36

sudo apt-get install libpng16-dev

from imagemin-mozjpeg.

erick2014 avatar erick2014 commented on June 15, 2024 13

For any reason My ubuntu was missing some packages to compile, I had to add a new gpg key:

wget -qO - https://raw.githubusercontent.com/yarnpkg/releases/gh-pages/debian/pubkey.gpg | sudo apt-key add -

then
sudo apt-get install autoconf libtool pkg-config nasm build-essential

and now it compiles the module

from imagemin-mozjpeg.

windware-ono avatar windware-ono commented on June 15, 2024 3

It needs,
autoconf libtool pkg-config nasm
to compile but somehow it builds a shared binary requiring libpng16-dev as well to run.

mozjpeg/vendor/cjpeg: error while loading shared libraries: libpng16.so.16: cannot open shared object file: No such file or directory

A working binary should be provided though.

from imagemin-mozjpeg.

dan-rally avatar dan-rally commented on June 15, 2024 2

Can confirm ~6.0.0 works for me too, ~7.0.0 binary doesn't work and I am not able to install the various build tools etc. Thanks @JimmyMultani

from imagemin-mozjpeg.

JimmyMultani avatar JimmyMultani commented on June 15, 2024 1

Updating to [email protected] allowed us to successfully build on our Ubuntu server. Will this be part of a version update soon?

from imagemin-mozjpeg.

ftreguer avatar ftreguer commented on June 15, 2024 1

I think it's fixed in 8.0.0. I've tested it today, it works for me. Build fails with 6.0.0 and 7.0.0 right now but works fine in 8.0.0

from imagemin-mozjpeg.

thasmo avatar thasmo commented on June 15, 2024

Oh, I guess this related to imagemin/mozjpeg-bin#33 - feel free to close if applicable.

from imagemin-mozjpeg.

Daxy24 avatar Daxy24 commented on June 15, 2024

The /.../source/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="/.../source/node_modules/mozjpeg/vendor" --bindir="/.../source/node_modules/mozjpeg/vendor" --libdir="/.../source/node_modules/mozjpeg/vendor" && make -j1 && make install -j1
Command failed: autoreconf -fiv
/bin/sh: 1: autoreconf: not found

at ChildProcess.exithandler (child_process.js:206:12)
at emitTwo (events.js:106:13)
at ChildProcess.emit (events.js:191:7)
at maybeClose (internal/child_process.js:877:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)

from imagemin-mozjpeg.

barryvanveen avatar barryvanveen commented on June 15, 2024

Is the dependency upon libpng16-dev intentional or incidental?

On our build servers we cannot install libpng16-dev because libpng12-dev is already present. This is currently holding us back from upgrading packages that rely on imagemin-mozjpeg.

Does anyone have a suggestion on how to solve this? I might, for example, be able to compile libpng16-dev from source, but how can I instruct imagemin-mozjpeg to use that compiled version?

Any help would be greatly appreciated!

from imagemin-mozjpeg.

feryardiant avatar feryardiant commented on June 15, 2024

I'm also having same issue and can be fixed just by apt install nasm since autoconf libtool pkg-config nasm build-essential are already installed on my Ubuntu 16.04 (WSL).

> [email protected] postinstall /path/to/project/node_modules/mozjpeg
> node lib/install.js

  ⚠ The `/path/to/project/node_modules/mozjpeg/vendor/cjpeg` binary doesn't seem to work correctly
  ⚠ mozjpeg pre-build test failed
  ℹ compiling from source
  ✔ mozjpeg built successfully

from imagemin-mozjpeg.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.