Bug #7961 'classic' fails to link: 'innobase_use_checksums' unresolved (without InnoDB)
Submitted: 17 Jan 2005 17:02 Modified: 17 Jan 2005 17:40
Reporter: Joerg Bruehe Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Compiling Severity:S3 (Non-critical)
Version:5.0.3-pre OS:Any (All)
Assigned to: Joerg Bruehe CPU Architecture:Any

[17 Jan 2005 17:02] Joerg Bruehe
Description:
Typical symptom when linking 'classic' (= --without-innodb) is:

cxx -DMYSQL_SERVER -DDEFAULT_MYSQL_HOME="\"/usr/local/mysql\"" -DDATADIR="\"/usr/local/mysql/data\"" -DSHAREDIR="\"/usr/local/mysql/share/mysql\"" -DHAVE_CONFIG_H -I. -I. -I.. -I../zlib -I../include -I../regex -I.  -I../extra    -O3 -DDBUG_OFF -O4 -pthread -ansi_alias -fast -inline speed -noexceptions -nortti   -DUNDEF_HAVE_GETHOSTBYNAME_R -DSNPRINTF_RETURN_TRUNC -I/usr/include/cxx -I/usr/include/cxx_cname -I/usr/include -I/usr/include.dtk -c -o mysqld.o mysqld.cc
cxx: Warning: mysqld.cc, line 2155: statement is unreachable
  return(0);                                    /* purecov: deadcode */
--^
cxx: Error: mysqld.cc, line 4419: identifier "innobase_use_checksums" is
          undefined
Disable with --skip-innodb-checksums.", (gptr*) &innobase_use_checksums,
-------------------------------------------------^
cxx: Info: 1 error detected in the compilation of "mysqld.cc".
gmake[4]: *** [mysqld.o] Error 1

or, as gcc writes it:
gcc -DMYSQL_SERVER -DDEFAULT_MYSQL_HOME="\"/usr/local/mysql\"" -DDATADIR="\"/usr/local/mysql/data\"" -DSHAREDIR="\"/usr/local/mysql/share/mysql\"" -DHAVE_CONFIG_H -I. -I. -I.. -I../zlib -I../include -I../regex -I.  -I../extra    -O3 -DDBUG_OFF    -fno-implicit-templates -fno-exceptions -fno-rtti -c -o mysqld.o mysqld.cc
mysqld.cc:4418: `innobase_use_checksums' was not declared in this scope
mysqld.cc:4420: `innobase_use_checksums' was not declared in this scope
make[4]: *** [mysqld.o] Error 1

This is a build based on changeset
ChangeSet
  1.1771 05/01/13 15:10:12 lenz@mysql.com +1 -0
  - keep 5.0.3-alpha version string (after-merge fix)

How to repeat:
Try to build '--without-innodb'.

Suggested fix:
Guard the lines by an  '#ifdef HAVE_INNOBASE_DB'.
[17 Jan 2005 17:40] Joerg Bruehe
Patch committed, revied by Paul and Kaamos, and pushed.
No doc change necessary.