Jump to content

Recommended Posts

  • 39 years later...
Posted

Hi,

I want to know how i can link the MySQL Libraies for compile Mangos, and what libraries is need by Mangos Compilation.

I need that becouse i Compile my own mysql, and i put the name of mysqlone, so i have some problems with the compilation.

becouse the program run like this: "rpm -qa | grep mysqlone" if i put "rpm -qa | grep mysql" dont appear any.

Thanks For your help.

Posted

That command show this:

libmysqlclient_r.so.15 (libc6,x86-64) => /usr/lib64/libmysqlclient_r.so.15

libmysqlclient_r.so (libc6,x86-64) => /usr/lib64/libmysqlclient_r.so

libmysqlclient.so.15 (libc6,x86-64) => /usr/lib64/libmysqlclient.so.15

libmysqlclient.so (libc6,x86-64) => /usr/lib64/libmysqlclient.so

Here is the error

make[5]: Nothing to be done for `install-data-am'.
make[5]: Leaving directory `/root/Desktop/Mangos/Sources/objdir/src/shared'
make[4]: Leaving directory `/root/Desktop/Mangos/Sources/objdir/src/shared'
make[3]: Leaving directory `/root/Desktop/Mangos/Sources/objdir/src/shared'
make[2]: Leaving directory `/root/Desktop/Mangos/Sources/objdir/src/shared'
Making install in realmd
make[2]: Entering directory `/root/Desktop/Mangos/Sources/objdir/src/realmd'
/bin/sh ../../libtool --tag=CXX --mode=link g++  -DDO_MYSQL -march=nocona -m64 -msse3 -o mangos-realmd -L../../dep/src/sockets -L/opt/Test/lib ../../dep/ACE_wrappers/ace/libACE.la  -rdynamic -L/usr/lib64/mysql -lmysqlclient_r -lz -lpthread -lcrypt -lnsl -lm -lpthread -lrt -lz  -L/usr/kerberos/lib64 -lssl -lcrypto -ldl -lz    AuthSocket.o Main.o RealmList.o ../shared/Database/libmangosdatabase.a ../shared/Config/libmangosconfig.a ../shared/Auth/libmangosauth.a ../shared/libmangosshared.a ../framework/libmangosframework.a ../../dep/src/sockets/libmangossockets.a -lpthread 
g++ -DDO_MYSQL -march=nocona -m64 -msse3 -o .libs/mangos-realmd -rdynamic AuthSocket.o Main.o RealmList.o  -L/root/Desktop/Mangos/Sources/objdir/dep/src/sockets -L/opt/Test/lib ../../dep/ACE_wrappers/ace/.libs/libACE.so -L/usr/lib64/mysql /usr/lib64/mysql/libmysqlclient_r.a -lrt -L/usr/kerberos/lib64 -lssl -lcrypto -ldl /usr/lib64/mysql/libz.a -lcrypt -lnsl -lm ../shared/Database/libmangosdatabase.a ../shared/Config/libmangosconfig.a ../shared/Auth/libmangosauth.a ../shared/libmangosshared.a ../framework/libmangosframework.a ../../dep/src/sockets/libmangossockets.a -lpthread  -Wl,--rpath -Wl,/opt/Test/lib
../shared/Database/libmangosdatabase.a(DatabaseMysql.o): In function `~DatabaseMysql':
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:64: undefined reference to `mysql_close'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:68: undefined reference to `mysql_server_end'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:64: undefined reference to `mysql_close'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:68: undefined reference to `mysql_server_end'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:64: undefined reference to `mysql_close'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:68: undefined reference to `mysql_server_end'
../shared/Database/libmangosdatabase.a(DatabaseMysql.o): In function `DatabaseMysql::_TransactionCmd(char const*)':
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:315: undefined reference to `mysql_query'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:318: undefined reference to `mysql_error'
../shared/Database/libmangosdatabase.a(DatabaseMysql.o): In function `DatabaseMysql::DirectExecute(char const*)':
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:295: undefined reference to `mysql_query'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:298: undefined reference to `mysql_error'
../shared/Database/libmangosdatabase.a(DatabaseMysql.o): In function `DatabaseMysql::_Query(char const*, st_mysql_res**, st_mysql_field**, unsigned long*, unsigned int*)':
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:190: undefined reference to `mysql_query'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:193: undefined reference to `mysql_error'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:203: undefined reference to `mysql_store_result'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:204: undefined reference to `mysql_affected_rows'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:205: undefined reference to `mysql_field_count'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:218: undefined reference to `mysql_fetch_fields'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:214: undefined reference to `mysql_free_result'
../shared/Database/libmangosdatabase.a(DatabaseMysql.o): In function `DatabaseMysql':
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:48: undefined reference to `mysql_server_init'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:50: undefined reference to `mysql_thread_safe'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:48: undefined reference to `mysql_server_init'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:50: undefined reference to `mysql_thread_safe'
../shared/Database/libmangosdatabase.a(DatabaseMysql.o): In function `DatabaseMysql::Initialize(char const*)':
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:79: undefined reference to `mysql_init'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:109: undefined reference to `mysql_options'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:127: undefined reference to `mysql_options'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:140: undefined reference to `mysql_real_connect'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:146: undefined reference to `mysql_get_client_info'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:147: undefined reference to `mysql_get_server_info'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:157: undefined reference to `mysql_autocommit'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:173: undefined reference to `mysql_error'
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:174: undefined reference to `mysql_close'
../shared/Database/libmangosdatabase.a(DatabaseMysql.o): In function `DatabaseMysql::escape_string(char*, char const*, unsigned long)':
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:419: undefined reference to `mysql_real_escape_string'
../shared/Database/libmangosdatabase.a(DatabaseMysql.o): In function `DatabaseMysql::ThreadEnd()':
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:37: undefined reference to `mysql_thread_end'
../shared/Database/libmangosdatabase.a(DatabaseMysql.o): In function `DatabaseMysql::ThreadStart()':
/root/Desktop/Mangos/Sources/src/shared/Database/DatabaseMysql.cpp:32: undefined reference to `mysql_thread_init'
../shared/Database/libmangosdatabase.a(QueryResultMysql.o): In function `QueryResultMysql::EndQuery()':
/root/Desktop/Mangos/Sources/src/shared/Database/QueryResultMysql.cpp:69: undefined reference to `mysql_free_result'
/root/Desktop/Mangos/Sources/src/shared/Database/QueryResultMysql.cpp:69: undefined reference to `mysql_free_result'
../shared/Database/libmangosdatabase.a(QueryResultMysql.o): In function `QueryResultMysql::NextRow()':
/root/Desktop/Mangos/Sources/src/shared/Database/QueryResultMysql.cpp:46: undefined reference to `mysql_fetch_row'
../shared/Database/libmangosdatabase.a(QueryResultMysql.o): In function `QueryResultMysql::EndQuery()':
/root/Desktop/Mangos/Sources/src/shared/Database/QueryResultMysql.cpp:69: undefined reference to `mysql_free_result'
/root/Desktop/Mangos/Sources/src/shared/Database/QueryResultMysql.cpp:69: undefined reference to `mysql_free_result'
/root/Desktop/Mangos/Sources/src/shared/Database/QueryResultMysql.cpp:69: undefined reference to `mysql_free_result'
../shared/Database/libmangosdatabase.a(SqlDelayThread.o): In function `SqlDelayThread::run()':
/root/Desktop/Mangos/Sources/src/shared/Database/SqlDelayThread.cpp:30: undefined reference to `mysql_thread_init'
/root/Desktop/Mangos/Sources/src/shared/Database/SqlDelayThread.cpp:47: undefined reference to `mysql_thread_end'
collect2: ld returned 1 exit status
make[2]: *** [mangos-realmd] Error 1
make[2]: Leaving directory `/root/Desktop/Mangos/Sources/objdir/src/realmd'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/root/Desktop/Mangos/Sources/objdir/src'
make: *** [install-recursive] Error 1

So i dont know, how i can compile! :'(

  • 1 month later...
Posted

I never be able to fix this issue, so bad!

i try with:

export CPPFLAGS="-I/usr/include/mysql"

export LDFLAGS="-L/usr/lib64/mysql -lmysqlclient -lmysqlclient_r -lz -lm"

try with

--with-mysql-libs="/usr/lib64/mysql" --with-mysql-includes="/usr/include/mysql"

Nothing, so bad! :'(

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use