Ed,

what does

gcc --version

say? I am able to compile with gcc-3.3.1.

in ut0dbg.h we have:

#if defined(__GNUC__) && (__GNUC__ > 2)
# define UT_DBG_FAIL(EXPR) UNIV_UNLIKELY(!((ulint)(EXPR)))
#else
extern ulint    ut_dbg_zero; /* This is used to eliminate
                               compiler warnings */
# define UT_DBG_FAIL(EXPR) !((ulint)(EXPR) + ut_dbg_zero)
#endif

and in ut0dbg.c:

#if defined(__GNUC__) && (__GNUC__ > 2)
#else
/* This is used to eliminate compiler warnings */
ulint   ut_dbg_zero     = 0;
#endif

Looks like your compiler does define __GNUC__ > 2 when you compile ut0dbg.c, but it does NOT define it when you compile ha_innodb.cc. This could be because ha_innodb.cc is C++ code.

Another explanation would be that for some reason make fails to link ./innobase/libut.a in. If you look at the gcc output in compilation, do you see it being linked in?

Regards,

Heikki
Oracle/Innobase


----- Original Message ----- From: "Ed Kasky" <[EMAIL PROTECTED]>
Newsgroups: mailing.database.myodbc
Sent: Sunday, November 06, 2005 10:08 PM
Subject: Error compiling 5.0.15


I am experiencing problems when trying to compile 5.0.15 on RH 7.3.  I run
"configure --prefix /usr/local/mysql" with no apparent errors.  when I run
make I get the following error:

ha_innodb.o: In function `check_trx_exists(THD *)':
ha_innodb.o(.text+0x30a): undefined reference to `ut_dbg_zero'
ha_innodb.o: In function `innobase_query_caching_of_table_permitted(THD *,
char *, unsigned int, unsigned long long *)':
ha_innodb.o(.text+0x3ab): undefined reference to `ut_dbg_zero'
ha_innodb.o(.text+0x3b6): undefined reference to `ut_dbg_zero'
ha_innodb.o: In function `innobase_init(void)':
ha_innodb.o(.text+0x69c): undefined reference to `ut_dbg_zero'
ha_innodb.o(.text+0x72e): undefined reference to `ut_dbg_zero'
ha_innodb.o(.text+0x98c): more undefined references to `ut_dbg_zero' follow
collect2: ld returned 1 exit status
make[4]: *** [mysqld] Error 1
make[4]: Leaving directory `/usr/src/mysql-5.0.15/sql'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/usr/src/mysql-5.0.15/sql'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/usr/src/mysql-5.0.15/sql'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/mysql-5.0.15'
make: *** [all] Error 2

Any ideas are greatly appreciated.

Also, I know I can use the binary but I have been instaling from src for
quite a while and would like to continue if my current OS can handle it.

Thanks in advance....

Ed

. . . . . . . . . . . . . . . . . .
Randomly Generated Quote (614 of 1009):
It is bad luck to be superstitious.
                -- Andrew W. Mathis


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to