Skip to Main Content

DevOps, CI/CD and Automation

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Problems w. Sun Studio 12 on S10Sparc compiling MySQL 5.0.51a and PHP 5.2.5

807578Mar 10 2008 — edited Mar 19 2008
Hello All,

I am at my wits end on this, trying to get MySQL and PHP compiled. I have tried CoolStack and for various reasons, it doesn't meet my needs, so am trying to do it by hand. I also tried with Sun Studio 11, with no luck. Oddly enough, about a year ago I was able to compile both packages with Sun Studio 11, but something had gone wrong since then. Any help would be greatly appreciated. Google doesn't come up with anything on the error messages I get.

Details:

$ version
Machine hardware: sun4u
OS version: 5.10
Processor type: sparc
Hardware: SUNW,UltraAX-i2

The following components are installed on your system:


Sun Studio 12
Sun Studio 12 C Compiler
Sun Studio 12 C++ Compiler
Sun Studio 12 Tools.h++ 7.1
Sun Studio 12 C++ Standard 64-bit Class Library
Sun Studio 12 Garbage Collector
Sun Studio 12 Fortran 95
Sun Studio 12 Debugging Tools (including dbx)
Sun Studio 12 IDE
Sun Studio 12 Debugger GUI
Sun Studio 12 Performance Analyzer (including collect, ...)
Sun Studio 12 X-Designer
Sun Studio 12 VIM editor
Sun Studio 12 XEmacs editor
Sun Studio 12 Performance Library
Sun Studio 12 LockLint
Sun Studio 12 Building Software (including dmake)
Sun Studio 12 Documentation Set
Sun Studio 12 /usr symbolic links and GNOME menu item

version of "/opt/SUNWspro/bin/../prod/bin/../../bin/cc": Sun C 5.9 SunOS_sparc Patch 124867-01 2007/07/12
version of "/opt/SUNWspro/bin/../prod/bin/../../bin/CC": Sun C++ 5.9 SunOS_sparc Patch 124863-01 2007/07/25
version of "/opt/SUNWspro/bin/../prod/bin/../../bin/f90": Sun Fortran 95 8.3 SunOS_sparc Patch 127000-01 2007/07/18
version of "/opt/SUNWspro/bin/../prod/bin/../../bin/dbx": Sun Dbx Debugger 7.6 SunOS_sparc Patch 124872-01 2007/07/12
version of "/opt/SUNWspro/bin/../prod/bin/../../bin/analyzer": Sun Analyzer 7.6 SunOS_sparc Patch 126995-01 2007/07/17
version of "/opt/SUNWspro/bin/../prod/bin/../../bin/dmake": Sun Distributed Make 7.8 SunOS_sparc Patch 126503-01 2007/07/19

CC=cc CFLAGS="-xO4 -mt -fsimple=1 -ftrap=%none -xbuiltin=%all -xlibmil -xlibmopt -xstrconst " \
CXX=CC CXXFLAGS="-xO3 -noex -mt -fsimple=1 -ftrap=%none -xbuiltin=%all -xlibmil -xlibmopt " \
./configure \
--prefix=/usr/local/mysql \
--localstatedir=/usr/local/mysql/data \
--libexecdir=/usr/local/mysql/bin \
--with-mysqld-user=mysql \
--with-extra-charsets=complex \
--with-server-suffix=-standard \
--enable-thread-safe-client \
--enable-local-infile \
--with-named-z-libs=no \
--with-big-tables \
--with-readline \
--with-archive-storage-engine \
--with-innodb \
--without-server \
--without-docs \
--without-man \
--without-bench

make

[snip]

mkdir .libs
CC -DDBUG_OFF -xO3 -noex -mt -fsimple=1 -ftrap=%none -xbuiltin=%all -xlibmil -xlibmopt -DHAVE_RWLOCK_T -o gen_lex_hash gen_lex_hash.o ../myisam/libmyisam.a ../myisammrg/libmyisammrg.a ../heap/libheap.a ../vio/libvio.a ../mysys/libmysys.a ../dbug/libdbug.a ../regex/libregex.a ../strings/libmystrings.a -lz -lpthread -lthread -lposix4 -lresolv -lgen -lsocket -lnsl -lm -lpthread -lthread
/usr/local/opt/SUNWspro/prod/lib/CCrti.o(.cpp_finidata+0x4): In function `_cpp_finidata0':
: undefined reference to `_START_'
/usr/local/opt/SUNWspro/prod/lib/CCrti.o(.cpp_finidata+0x8): In function `_cpp_finidata0':
: undefined reference to `_END_'
*** Error code 1
make: Fatal error: Command failed for target `gen_lex_hash'
Current working directory /export/home/source/mysql-5.0.51a/sql
*** Error code 1
make: Fatal error: Command failed for target `lex_hash.h'
Current working directory /export/home/source/mysql-5.0.51a/sql
*** Error code 1
The following command caused the error:
failcom='exit 1'; \
for f in x $MAKEFLAGS; do \
case $f in \
*=* | --[!k]*);; \
k) failcom='fail=yes';; \
esac; \
done; \
dot_seen=no; \
target=`echo all-recursive | sed s/-recursive//`; \
list='. include cmd-line-utils sql-common scripts pstack strings mysys dbug extra regex innobase myisam myisammrg heap vio sql libmysql_r libmysql client tests netware mysql-test support-files tools'; for subdir in $list; do \
echo "Making $target in $subdir"; \
if test "$subdir" = "."; then \
dot_seen=yes; \
local_target="$target-am"; \
else \
local_target="$target"; \
fi; \
(cd $subdir && make $local_target) \
|| eval $failcom; \
done; \
if test "$dot_seen" = "no"; then \
make "$target-am" || exit 1; \
fi; test -z "$fail"
make: Fatal error: Command failed for target `all-recursive'
Current working directory /export/home/source/mysql-5.0.51a
*** Error code 1
make: Fatal error: Command failed for target `all'


PHP dies trying to link sapi/cgi/php-cgi:
sl -lxml2 -lz -lm -lsocket -lnsl -lxml2 -lz -lm -lsocket -lnsl -lxml2 -lz -lm -lsocket -lnsl -o sapi/cgi/php-cgi
ext/mysql/php_mysql.o(.text+0x2688): In function `zif_mysql_set_charset':
/export/home/source/php-5.2.5/ext/mysql/php_mysql.c:1183: undefined reference to `mysql_set_character_set'
collect2: ld returned 1 exit status
*** Error code 1
make: Fatal error: Command failed for target `sapi/cgi/php-cgi'
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 16 2008
Added on Mar 10 2008
5 comments
207 views