> I have been running MySQL in 32-bit mode on Solaris for about a year now. > I've been attempting to compile 3.23.52 in 64 bit mode using the Sun > Workshop 6 Update 2 compiler. Everything works/compiles great until it's
Any reason to go 64-bit? I've compiled 64-bit myself and it seems to work for the rudimentary stuff I was doing .. FWIW, the MySQL docs state that 64-bit compilations aren't supported ... There may be bugs/corruption that you'll run into ... > link time. I think the libtool or /usr/ccs/bin/ld thinks either: > - my system cannot run 64 bit apps > - there's a 32-bit library out there that cannot mate with a > 64-bit library Based on the messages below, it's a 32/64 mismatch. > Is there a way to get libtool to tell me what libraries it is using and > where it is looking? I think if I had that list I could audit it for 32-bit > libs. > (I suspect it may be curses, but I cannot tell where it is looking) > > Here's the barf from the shell: > > /bin/sh ../libtool --mode=link /opt/SUNWspro/bin/CC -O3 > -DDBUG_OFF -DHAVE_CURSES_H -I/opt/src/mysql-3.23.52/include > -DHAVE_RWLOCK_T -o mysql mysql.o readline.o sql_string.o > completion_hash.o ../readline/libreadline.a -lcurses > ../libmysql/libmysqlclient.la -lz -lgen -lsocket -lnsl -lm > /opt/SUNWspro/bin/CC -O3 -DDBUG_OFF -DHAVE_CURSES_H > -I/opt/src/mysql-3.23.52/include -DHAVE_RWLOCK_T -o .libs/mysql mysql.o > readline.o sql_string.o completion_hash.o ../readline/libreadline.a > -lcurses ../libmysql/.libs/libmysqlclient.so -lz -lgen -lsocket -lnsl -lm > -lz -lgen -lsocket -lnsl -lm -R/opt/local/lib/mysql > ld: warning: file ../readline/libreadline.a(readline.o): wrong ELF class: > ELFCLASS64 >From the ld man page: No command-line option is required to distinguish 32-bit or 64-bit objects. The link-editor uses the ELF class of the first input relocatable file it sees to govern the mode in which it will operate. The error message, combined with the above knowledge, means ld is in 32 bit mode and the 64-bit class of libreadline is a mismatch. I don't know what the first relocatable file is in your CC line is, so one way to determine what's going on is to set the LD_OPTIONS environment variable to the proper switch ('-64' I believe) that forces 64-bit mode and retry the compile. Then you'll see complaints about the 'offending' 32-bit libraries which will help you narrow down the problem. You may need to do things like make /usr/lib/sparcv9 come AHEAD of /usr/lib so that the linker attempts the system's 64-bit libs first. Offhand I'm not sure if setting your LDFLAGS will do the trick as I'm not sure if that's used before the default /usr/lib or not. It's been a while since I did this and I no longer have access to the machine to test... Perhaps toying with LD_LIBRARY_PATH (and make LD_RUN_PATH match) environment variables will work .. IE setting them to '/usr/lib/sparcv9:/usr/lib' [snip] HTH, -=| Ben --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php