MySQL Forums
Forum List  »  Source, Builds, Binaries

MySQL 5.0.21 Universal Binary vs OS X (multiple definitions of symbol)
Posted by: Scott Meyers
Date: May 27, 2006 07:22AM

I've encountered a problem which I believe is with the latest Mac OS Universal Binary. When attempting to build PHP I get a number of "multiple definitions of symbol" which pair libmysqlclient.a against native gcc libraries. A selection of the error stream is as follows:

...
.bundle libs/libphp5.so
/usr/bin/ld: multiple definitions of symbol _BN_bin2bn
/usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libcrypto.dylib(bn_lib.o) definition of _BN_bin2bn
/usr/local/mysql/lib/libmysqlclient.a(ssl.o) definition of _BN_bin2bn in section (__TEXT,__text)
/usr/bin/ld: multiple definitions of symbol _DH_free
/usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libcrypto.dylib(dh_lib.o) definition of _DH_free
/usr/local/mysql/lib/libmysqlclient.a(ssl.o) definition of _DH_free in section (__TEXT,__text)
/usr/bin/ld: multiple definitions of symbol _DH_new
/usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libcrypto.dylib(dh_lib.o) definition of _DH_new
/usr/local/mysql/lib/libmysqlclient.a(ssl.o) definition of _DH_new in section (__TEXT,__text)
/usr/bin/ld: multiple definitions of symbol _ERR_error_string
/usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libcrypto.dylib(err.o) definition of _ERR_error_string
/usr/local/mysql/lib/libmysqlclient.a(ssl.o) definition of _ERR_error_string in section (__TEXT,__text)
/usr/bin/ld: multiple definitions of symbol _ERR_get_error
/usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libcrypto.dylib(err.o) definition of _ERR_get_error
/usr/local/mysql/lib/libmysqlclient.a(ssl.o) definition of _ERR_get_error in section (__TEXT,__text)
...

It goes on for awhile like this.

I'm (attempting to) compile on a MBP with the latest version of Xcode and apple developer tools. I'm not sure if anything changed in the last developer update, but that could be the culprit.

I was able compile MySQL myself and then successfully build PHP against that, but I'd feel more confident if I could build against the official binary.

Options: ReplyQuote




Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.