webp-sh / webp_server_go

Go version of WebP Server. A tool that will serve your JPG/PNG/BMP/SVGs as WebP/AVIF format with compression, on-the-fly.
https://docs.webp.sh
GNU General Public License v3.0
1.83k stars 174 forks source link

macOS PKG_CONFIG_PATH libpng.pc not found #203

Closed fffilimonov closed 1 year ago

fffilimonov commented 1 year ago

error while building on macOS 13.3.1 (22E261): Package libpng was not found in the pkg-config search path.

fixed for now: export PKG_CONFIG_PATH=$(find /usr/local/Cellar -name 'pkgconfig' -type d | grep lib/pkgconfig | tr '\n' ':' | sed s/.$//)

n0vad3v commented 1 year ago

Thanks for pointing out!

I don't have any Mac devices at this time, @BennyThink could you help testing this out and update our docs https://github.com/webp-sh/docs.webp.sh/blob/master/content/build.md if needed.

BennyThink commented 1 year ago

Intel Mac?

  1. try brew install vips pkg-config and make again?
  2. brew install libpng and make again?
fffilimonov commented 1 year ago

Yes Intel Mac. I did install vips and pkg-config and did reinstall libpng.

BennyThink commented 1 year ago

Okay I see. Sadly I don't have Intel Mac. Did the above install work for you?

fffilimonov commented 1 year ago

Yes, adding path to PKG_CONFIG_PATH fix the problem.

BennyThink commented 1 year ago

Good. Closing this now