[mrtg] Re: Getting GD1.7.3 to work

AS108 at daimlerchrysler.com AS108 at daimlerchrysler.com
Tue Nov 16 15:23:09 MET 1999



appending -lm worked!!!!!! Great!  thanks yozo!.....don't know why I needed to
specify -lm twice but that's ok.

Andy



                                                           
                                                           
                                                           
                                                           
                                                           
                                                           
                                                           
                                                           
                                                           
                                                           
                                                           




> Ok.  I made sure it was able to see a math.h in /usr/include.  No change.

no. the problem occur when linking object files.

>          /opt/gcc/bin/gcc -I/usr/local/include -I/usr/include/X11
>  -I/opt/libpng/include pngtogd.o -o pngtogd
>  -L. -L/usr/local/lib -L/usr/lib/X11 -L/opt/libpng/lib -lm -lgd -lpng -lz
>  collect2: ld returned 1 exit status
>  /usr/ccs/bin/ld: Unsatisfied symbols:
>     floor (code)
>     pow (code)
>  *** Error exit code 1

I suspect floor() and pow() are used from png or zlib libraries.
edit Makefile such that -lm is appended to LIBS and recompile.

find this line
  LIBS=-lm -lgd -lpng -lz

append -lm and it looks like
  LIBS=-lm -lgd -lpng -lz -lm


another note;
mrtg (actually rateup) requires only libgd.a.
I bet you already get libgd.a.
you can leave other utility programs such as pngtogd not compiled.
try install mrtg using libgd.a.

-- yozo.

--
* To unsubscribe from the mrtg mailing list, send a message with the
  subject: unsubscribe to mrtg-request at list.ee.ethz.ch
* The mailing list archive is at http://www.ee.ethz.ch/~slist/mrtg




--
* To unsubscribe from the mrtg mailing list, send a message with the
  subject: unsubscribe to mrtg-request at list.ee.ethz.ch
* The mailing list archive is at http://www.ee.ethz.ch/~slist/mrtg


More information about the mrtg mailing list