According to Mark T. Valites:
> Your suggestion about old header files hanging around got me thinking
> that the header files might have come from the original gcc package from
> sunfreeware that I had installed. Since I had upgraded and compiled
> gcc-3.0.1 since then, I removed the packgare (pkdrm SMCgcc), cd'd into
> my precompiled gcc-3.0.1 directory, and did another "make install".
> This time the compile got along quite a bit furthur, but now bombs out
> with a different error.
>
> <snip>
> Making all in htfuzzy
> make[1]: Entering directory `/usr/local/src/htdig-3.2.0b4-102801/htfuzzy'
> /bin/sh ../libtool --mode=compile c++ -DHAVE_CONFIG_H -I. -I.
> -I../include
> -DDEFAULT_CONFIG_FILE=\"/usr/local/htdig/conf/htdig.conf\"
> -I../include -I../htlib -I../htnet
> -I../htcommon -I../htword -I../db
> -I../db -DMV=\"/usr/local/bin/mv\"
> -I/usr/local/include -g -O2 -Wall -fno-rtti -fno-exceptions -c Accents.cc
> c++ -DHAVE_CONFIG_H -I. -I. -I../include
> -DDEFAULT_CONFIG_FILE=\"/usr/local/htdig/conf/htdig.conf\" -I../include
> -I../htlib -I../htnet -I../htcommon -I../htword -I../db -I../db
> -DMV=\"/usr/local/bin/mv\" -I/usr/local/include -g -O2 -Wall -fno-rtti
> -fno-exceptions -c Accents.cc -o Accents.o
> In file included from ../htword/WordList.h:82,
> from ../htcommon/HtWordList.h:23,
> from Fuzzy.h:32,
> from Accents.h:20,
> from Accents.cc:23:
> ../htword/WordDB.h: In member function `int WordDB::Stat(void*,
> void*(*)(unsigned int), int)':
> ../htword/WordDB.h:103: no matching function for call to
> `__db::stat64(DB*&,
> void*&, void*(*&)(unsigned int), u_int32_t&)'
> make[1]: *** [Accents.lo] Error 1
> make[1]: Leaving directory `/usr/local/src/htdig-3.2.0b4-102801/htfuzzy'
> make: *** [all-recursive] Error 1
OK, I've seen this error before! It was reported 2-3 weeks ago.
At the time, I tried to find where it was picking up the definition for
__db::stat64, which really should have been DB::stat or something of
the sort, but gave up because I couldn't find either. I now figured out
why I couldn't find it. As far as I can guess, gcc 3.0.* is redefining
the calls to the C library stat() fuction to use stat64(), but the macro
they use to do this is also hitting other occurrences of stat() as in the
function pointer call db->stat(...), so the call is being interpreted as a
call to an undefined C++ method rather that the derefencing of a function
pointer. Redefining the name of this "stat" field to avoid the conflict
would require changing lots of db source files, but it might be effective.
Here's the kicker, though: there is no db.h file in the 3.2.0b3 &
3.2.0b4 distributions!!!! Somehow when the db code was rearranged,
that header file was lost, so the compiler ends up using the one in the
standard C headers, i.e. in /usr/include. That this words at all is
rather amazing, but it could potentially be the cause of all sorts of
wierdness we've seen reported on some systems.
Obviously we need to find the appropriate version of this file and put
it back. As for the clobbered db->stat() calls, maybe the easy fix is
to simply put parentheses around the "db->stat" part, thus...
return (db->stat)(db, sp, db_malloc, (u_int32_t) flags);
in htword/WordDB.h, and anywhere else where this comes up
(htdb/htdb_dump.cc and htdb/htdb_stat.cc come to mind). If you give
this trick a try, let me know if it fixes this problem.
> The above compile was done on my desktop ultra 5, so it took forever.
> After it failed there, I tried the same options and compile on a
> sunfire since it was faster to play with, but could not replicate the
> results, and instead get the following:
>
> /usr/include/sys/time_impl.h:15: warning: ignoring #pragma ident
> In file included from /usr/include/synch.h:19,
> from mutex.h:39,
> from db_int.h:261,
> from db_err.c:29:
> /usr/include/sys/synch.h:9: warning: ignoring #pragma ident
> db_err.c: In function `CDB_db_strerror':
> db_err.c:248: warning: implicit declaration of function `snprintf'
> db_err.c: In function `CDB___db_err':
> db_err.c:278: `__builtin_va_alist' undeclared (first use in this function)
> db_err.c:278: (Each undeclared identifier is reported only once
> db_err.c:278: for each function it appears in.)
> db_err.c:275: warning: `ap' might be used uninitialized in this function
> db_err.c: In function `CDB___db_errcall':
> db_err.c:328: warning: implicit declaration of function `vsnprintf'
> db_err.c: In function `CDB___db_logmsg':
> db_err.c:408: `__builtin_va_alist' undeclared (first use in this function)
> db_err.c:395: warning: `ap' might be used uninitialized in this function
> make[1]: *** [db_err.lo] Error 1
> make[1]: Leaving directory `/usr/netscape/src/htdig-3.2.0b4-102801/db'
> make: *** [all-recursive] Error 1
>
> I've seen the immeadiate above error in a couple of the list archives,
> but the top one looked promising to me. I'd be content with initially
> getting this to run on my ultra 5 for now.... Any insight?
Well, in case you haven't noticed yet, that is the exact same error
you reported previously (see below), so now I'm confused. Did you used
to get the same error on the ultra 5 that you still get on the sunfire,
before you removed the original SMCgcc package on the ultra? Did you
try the same fix on the sunfire? It still seems to me to be a header
file conflict on the sunfire, as I said previously.
> Gilles Detillieux wrote:
> >According to Mark T. Valites:
> >
> >>gcc-3.0.2 resulted in the same exact error with the 3.1.6 snapshot on
> >>the sunfire with solaris 8.
> >>
> >>However, htdig-3.2.0b4 snapshot gives me a different result with 3.0.2:
> >>
> >> from db_err.c:29:
> >>/usr/include/sys/time_impl.h:15: warning: ignoring #pragma ident
> >>In file included from /usr/include/synch.h:19,
> >> from mutex.h:39,
> >> from db_int.h:261,
> >> from db_err.c:29:
> >>/usr/include/sys/synch.h:9: warning: ignoring #pragma ident
> >>db_err.c: In function `CDB_db_strerror':
> >>db_err.c:248: warning: implicit declaration of function `snprintf'
> >>db_err.c: In function `CDB___db_err':
> >>db_err.c:278: `__builtin_va_alist' undeclared (first use in this function)
> >>db_err.c:278: (Each undeclared identifier is reported only once
> >>db_err.c:278: for each function it appears in.)
> >>db_err.c:275: warning: `ap' might be used uninitialized in this function
> >>db_err.c: In function `CDB___db_errcall':
> >>db_err.c:328: warning: implicit declaration of function `vsnprintf'
> >>db_err.c: In function `CDB___db_logmsg':
> >>db_err.c:408: `__builtin_va_alist' undeclared (first use in this function)
> >>db_err.c:395: warning: `ap' might be used uninitialized in this function
> >>make[1]: *** [db_err.lo] Error 1
> >>make[1]: Leaving directory `/usr/netscape/src/htdig-3.2.0b4-102101/db'
> >>make: *** [all-recursive] Error 1
> >>
> >
> >This error implies to me that the compiler is picking up some definitions
> >from a header file somewhere that end up using builtin operators that the
> >compiler itself doesn't support. I believe this would be caused by having
> >header files on your system that aren't appropriate for the compiler your
> >running. I.e. they come from a different compiler version, or a different
> >compiler altogether.
--
Gilles R. Detillieux E-mail: <[EMAIL PROTECTED]>
Spinal Cord Research Centre WWW: http://www.scrc.umanitoba.ca/~grdetil
Dept. Physiology, U. of Manitoba Phone: (204)789-3766
Winnipeg, MB R3E 3J7 (Canada) Fax: (204)789-3930
_______________________________________________
htdig-general mailing list <[EMAIL PROTECTED]>
To unsubscribe, send a message to <[EMAIL PROTECTED]> with a
subject of unsubscribe
FAQ: http://htdig.sourceforge.net/FAQ.html