Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I updated brew sometime ago and recently tried to run webalizer and now get this error:

libpng warning: Application built with libpng-1.2.41 but running with 1.5.10 gd-png error: cannot allocate libpng main struct

I ran libpng-config --cflags --ldflags to get the CFLAGS and LDFLAGS variables, and added them to the info file:

def install
  ENV['CFLAGS']='-I/opt/X11/include/libpng15'
  ENV['LDFLAGS']='-L/opt/X11/lib -lpng15'
  system "./configure", "--disable-debug",
                       "--disable-dependency-tracking",
                       "--prefix=#{prefix}"
  system "make install"
end

brew builds from this info file okay, but I still have the libpng error.

How can I build webalizer so it's using the right libpng library?

share|improve this question

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.