Unfortunately, I don't have a good handle on the gd 1 vs. 2 distribution in
the real world.  There's no nice gdVersion() function, so I didn't put it
into the checkVersion stuff.  Any kind of test would be looking for
breadcrumbs in the iterations of gd.h...

I do know that the two versions (1.7.2-1.8.4 and 2.0+) are incompatible.
Which is why most OS/distros don't have 2.0 yet.  Those that do refer to it
as gd2, because most packages don't like it or haven't been tested with it.

In the Linux world, I'm running gd-1.8.4, which is

$ ls -l /usr/lib/libgd.*
-rw-r--r--    1 root     root       211850 Jan 24  2003 /usr/lib/libgd.a
lrwxrwxrwx    1 root     root           14 Dec 15 12:20 /usr/lib/libgd.so ->
libgd.so.1.8.4
lrwxrwxrwx    1 root     root           14 Dec 15 12:06
/usr/lib/libgd.so.1 -> libgd.so.1.8.4
lrwxrwxrwx    1 root     root           14 Dec 15 12:06
/usr/lib/libgd.so.1.8 -> libgd.so.1.8.4
-rwxr-xr-x    1 root     root       183332 Jan 24  2003
/usr/lib/libgd.so.1.8.4

On Tom's site - http://www.boutell.com/gd/ - Version 2.0.21 is listed as
Stable, so it's probably the one you want to use, but with the lack of
real-world gd2 binaries, it's probably SAFEST to install gd 1.8.4 and let
ntop find it as libgd.  Unfortunately, that doesn't seem to be the way
FreeBSD packaged things - they have gd1 and gd2 instead.

So your manual ln is probably the only answer.

You could add a simple if test in configureextra/freebsd which prints a
large WARNING box with the ln -s suggestion if it doesn't find it...  Off
the cuff (meaining it probably won't be quite right):

if test -f /usr/lib/libgd.so; then
  echo ""
else if test -f /usr/lib/libgd1.so &&
        test -f /usr/lib/libgd2.so; then
  echo "*******************************************************************"
  echo "*"
  echo "* WARNING: libgd1 and libgd2 are both defined.  ntop looks for
libgd.
  echo "*          pick one and create a symbolic link via ln -sf
/usr/lib/libgd1.so /usr/lib/libgd.so"
  echo "*"
  echo "*  This ./configure will probably fail"
  echo "*"
  echo "*******************************************************************"
else if test -f /usr/lib/libgd2.so; then
...

-----Burton



> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of
> Stanley Hopcroft
> Sent: Wednesday, January 28, 2004 12:01 AM
> To: [EMAIL PROTECTED]
> Subject: Re: [Ntop] Re: configureextra/FREEBSD getting libgd1 into LIBS
> Was: Building ntop (probably silly comments about gd).
>
>
> Dear Sir,
>
> I am writing to thank you for your help in this matter and say,
>
> On Tue, Jan 27, 2004 at 09:21:21PM -0800, Burton Strauss wrote:
> > Ug...
> >
> > Off the cuff, I don't think there's an externally accessible
> end point cleanup.
> > There IS a case statement in ./configure, but that will cause problems
> > as all of the validation up to that point would have been done WITH
> > -lgd.
> >
> > The best answer probably is to require the ln you proposed
> originally and live with that.  It's a one time 'fix'.
> >
>
> ln -s /usr/local/libgd1.so /usr/local/lib/libgd.so (and so on) for
> FreeBSD users of the gd-1.8.4.2 port/package then.
>
> It may be possible to use the gd-2.x port and not have this trouble (I
> think gd-2.x is installed as libgd.so).
>
> On the whole, it's a small price to pay for what seems to be a fairly
> painless configure/build process.
>
> > -----Burton
> >
> >
>
> Yours sincerely.
>
> --
> ------------------------------------------------------------------------
> Stanley Hopcroft
> ------------------------------------------------------------------------
>
> '...No man is an island, entire of itself; every man is a piece of the
> continent, a part of the main. If a clod be washed away by the sea,
> Europe is the less, as well as if a promontory were, as well as if a
> manor of thy friend's or of thine own were. Any man's death diminishes
> me, because I am involved in mankind; and therefore never send to know
> for whom the bell tolls; it tolls for thee...'
>
> from Meditation 17, J Donne.
> _______________________________________________
> Ntop mailing list
> [EMAIL PROTECTED]
> http://listgateway.unipi.it/mailman/listinfo/ntop
>

_______________________________________________
Ntop mailing list
[EMAIL PROTECTED]
http://listgateway.unipi.it/mailman/listinfo/ntop

Reply via email to