Fedora Core build fails

Bug #772929 reported by Robert Brown (rjbrown99)
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Percona Server moved to https://jira.percona.com/projects/PS
New
Low
Ignacio Nin

Bug Description

I'm building using Percona-Server-55-5.5.11-rel20.2.115.rhel5.src.rpm on Fedora 12 x86_64 platform. After issuing rpmbuild -bb percona-server.spec, it goes for quite a while and then runs into the following error. I made no other changes to the source or spec file. For what it's worth, Percona-Server-55-5.5.8-beta20.0.1 did build successfully on this same system with the same packages installed.

Making all in handlersocket
make[2]: Entering directory `/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/Percona-Server-5.5.11-rel20.2/storage/HandlerSocket-Plugin-for-MySQL/handlersocket'
/bin/sh ../libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I. -I.. -I/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/Percona-Server-5.5.11-rel20.2/sql -I/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/Percona-Server-5.5.11-rel20.2/include -I/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/Percona-Server-5.5.11-rel20.2/regex -I/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/Percona-Server-5.5.11-rel20.2 -I/usr/include/mysql -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -fPIC -g -static-libgcc -fno-omit-frame-pointer -fno-strict-aliasing -DMY_PTHREAD_FASTMUTEX=1 -DDBUG_OFF -I../libhsclient -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -felide-constructors -fno-exceptions -fno-rtti -I/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/release/include -Wall -g -fno-rtti -fno-exceptions -fPIC -DPIC -MT handlersocket_la-database.lo -MD -MP -MF .deps/handlersocket_la-database.Tpo -c -o handlersocket_la-database.lo `test -f 'database.cpp' || echo './'`database.cpp
libtool: compile: g++ -DHAVE_CONFIG_H -I. -I.. -I/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/Percona-Server-5.5.11-rel20.2/sql -I/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/Percona-Server-5.5.11-rel20.2/include -I/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/Percona-Server-5.5.11-rel20.2/regex -I/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/Percona-Server-5.5.11-rel20.2 -I/usr/include/mysql -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -fPIC -g -static-libgcc -fno-omit-frame-pointer -fno-strict-aliasing -DMY_PTHREAD_FASTMUTEX=1 -DDBUG_OFF -I../libhsclient -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -felide-constructors -fno-exceptions -fno-rtti -I/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/release/include -Wall -g -fno-rtti -fno-exceptions -fPIC -DPIC -MT handlersocket_la-database.lo -MD -MP -MF .deps/handlersocket_la-database.Tpo -c database.cpp -fPIC -DPIC -o .libs/handlersocket_la-database.o
In file included from database.cpp:16:
mysql_incl.hpp:43:24: error: mysql_priv.h: No such file or directory
database.cpp:99: error: ISO C++ forbids declaration of 'TABLE' with no type
database.cpp:99: error: expected ';' before '*' token
database.cpp: In constructor 'dena::tablevec_entry::tablevec_entry()':
database.cpp:102: error: class 'dena::tablevec_entry' does not have any field named 'table'
database.cpp: At global scope:
database.cpp:106: error: expected ')' before '*' token
database.cpp:124: error: 'Item_string' does not name a type
database.cpp:125: error: 'Item_int' does not name a type
database.cpp:126: error: 'Item_func_get_lock' does not name a type
database.cpp:127: error: 'Item_func_release_lock' does not name a type
database.cpp: In member function 'long long int dena::expr_user_lock::get_lock()':
database.cpp:118: error: 'lck_func_get_lock' was not declared in this scope
database.cpp: In member function 'long long int dena::expr_user_lock::release_lock()':
database.cpp:121: error: 'lck_func_release_lock' was not declared in this scope
database.cpp: At global scope:
database.cpp:150: error: 'TABLE' has not been declared
database.cpp:157: error: 'ha_rkey_function' has not been declared
database.cpp:158: error: 'TABLE' has not been declared
database.cpp:160: error: 'TABLE' has not been declared
database.cpp:161: error: 'uchar' has not been declared
database.cpp:162: error: 'TABLE' has not been declared
database.cpp:163: error: ISO C++ forbids declaration of 'uchar' with no type
database.cpp:163: error: expected ',' or '...' before '*' token
database.cpp:164: error: 'TABLE' has not been declared
database.cpp:165: error: 'TABLE' has not been declared
database.cpp:166: error: 'TABLE' has not been declared
database.cpp:176: error: ISO C++ forbids declaration of 'THD' with no type
database.cpp:176: error: expected ';' before '*' token
database.cpp:177: error: ISO C++ forbids declaration of 'MYSQL_LOCK' with no type
database.cpp:177: error: expected ';' before '*' token
database.cpp: In constructor 'dena::dbcontext::dbcontext(volatile dena::database*, bool)':
database.cpp:222: error: class 'dena::dbcontext' does not have any field named 'thd'
database.cpp:222: error: class 'dena::dbcontext' does not have any field named 'lock'
database.cpp: At global scope:
database.cpp:237: error: 'THD' was not declared in this scope
database.cpp:237: error: 'thd' was not declared in this scope
database.cpp:237: error: expected primary-expression before 'volatile'
database.cpp:237: error: initializer expression list treated as compound expression
database.cpp:238: error: expected ',' or ';' before '{' token
database.cpp:1182: error: expected '}' at end of input
database.cpp:1182: error: expected '}' at end of input
database.cpp:237: warning: 'dena::<unnamed>::wait_server_to_start' defined but not used
make[2]: *** [handlersocket_la-database.lo] Error 1
make[2]: Leaving directory `/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/Percona-Server-5.5.11-rel20.2/storage/HandlerSocket-Plugin-for-MySQL/handlersocket'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/rbrown/rpmbuild/BUILD/Percona-Server-5.5.11-rel20.2/Percona-Server-5.5.11-rel20.2/storage/HandlerSocket-Plugin-for-MySQL'
make: *** [all] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.J9cOD7 (%build)

Tags: pkg
Revision history for this message
Robert Brown (rjbrown99) (rjbrown99) wrote :

I'm getting a different build error with Fedora Core 14. It gets the entire way to the end, then I see this:

RPM build errors:
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/adt_null.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/libdaemon_example.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/mypluglib.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/semisync_master.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/semisync_slave.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/auth.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/auth_socket.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/auth_test_plugin.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/qa_auth_client.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/qa_auth_interface.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/qa_auth_server.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/debug/adt_null.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/debug/libdaemon_example.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/debug/mypluglib.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/debug/semisync_master.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/debug/semisync_slave.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/debug/auth.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/debug/auth_socket.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/debug/auth_test_plugin.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/debug/qa_auth_client.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/debug/qa_auth_interface.so
    File not found: /root/rpmbuild/BUILDROOT/Percona-Server-55-5.5.11-rel20.2.1.rhel.x86_64/usr/lib64/mysql/plugin/debug/qa_auth_server.so

Revision history for this message
Robert Brown (rjbrown99) (rjbrown99) wrote :

One other note - you should consider adding an SRPM build dependency on libtool to the spec file. Otherwise the build stops after a while and asks for the path to libtoolize.

Revision history for this message
Greg Hazel (ghazelgmail.com) wrote :

I have the same compilation issue here on the Amazon Linux AMI with Percona-Server 5.5.13.

Revision history for this message
Robert Brown (rjbrown99) (rjbrown99) wrote :

FWIW, here's what happens on Fedora 15 x86_64 with Percona-Server-55-5.5.15-rel21.0.158.rhel6.src.rpm

Linking CXX executable resolve_stack_dump
[ 78%] Built target resolve_stack_dump
Scanning dependencies of target resolveip
[ 78%] Building C object extra/CMakeFiles/resolveip.dir/resolveip.c.o
Linking CXX executable resolveip
[ 78%] Built target resolveip
Scanning dependencies of target bug25714
[ 79%] Building C object tests/CMakeFiles/bug25714.dir/bug25714.c.o
Linking CXX executable bug25714
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0x24): undefined reference to `mysql_net__write__start_semaphore'
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0x70): undefined reference to `mysql_net__write__done_semaphore'
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0xbc): undefined reference to `mysql_net__write__done_semaphore'
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0x108): undefined reference to `mysql_net__write__done_semaphore'
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0x154): undefined reference to `mysql_net__write__start_semaphore'
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0x1a0): undefined reference to `mysql_net__write__done_semaphore'
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0x1ec): undefined reference to `mysql_net__write__done_semaphore'
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0x238): undefined reference to `mysql_net__read__start_semaphore'
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0x27c): undefined reference to `mysql_net__read__done_semaphore'
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0x2cc): undefined reference to `mysql_net__read__done_semaphore'
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0x31c): undefined reference to `mysql_net__read__done_semaphore'
../libmysql/libmysqlclient.a(net_serv.cc.o):(.note.stapsdt+0x36c): undefined reference to `mysql_net__read__done_semaphore'
collect2: ld returned 1 exit status
make[2]: *** [tests/bug25714] Error 1
make[1]: *** [tests/CMakeFiles/bug25714.dir/all] Error 2
make: *** [all] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.Ei6Heo (%build)

Revision history for this message
Oleg Tsarev (tsarev) wrote :

Latest lp:percona-server build succesfully under Fedora Core 15 x84_64.

Revision history for this message
Alexey Kopytov (akopytov) wrote :

Robert,

The build errors from comment #4 seem related to DTrace probes. SystemTap on Linux emulates DTrace, and apparently building with probes enabled is currently broken. The workaround is to either uninstall SystemTap temporarily, or at least rename the dtrace binary, which is used to detect if the platforms supports DTrace probes.

I have reported this as a separate bug #869998.

Revision history for this message
Laurynas Biveinis (laurynas-biveinis) wrote :

Another workaround is to add -DWITH_DTRACE=OFF to the cmake options.

Revision history for this message
Robert Brown (rjbrown99) (rjbrown99) wrote :

Well, I did get it to build RPMS but there is still an issue.

The stock Fedora 15 mysql-libs package shows as providing this:
# rpm -q --provides mysql-libs-5.5.14
config(mysql-libs) = 5.5.14-2.fc15
libmysqlclient.so.18()(64bit)
libmysqlclient.so.18(libmysqlclient_16)(64bit)
libmysqlclient.so.18(libmysqlclient_18)(64bit)
mysql-libs = 5.5.14-2.fc15
mysql-libs(x86-64) = 5.5.14-2.fc15

However, the Percona package only provides this:
# rpm -q --provides Percona-Server-shared-55
libmysqlclient.so.18()(64bit)
libtool(/usr/lib64/mysql/plugin/libfnv1a_udf.la)
libtool(/usr/lib64/mysql/plugin/libfnv_udf.la)
libtool(/usr/lib64/mysql/plugin/libmurmur_udf.la)
mysql-shared
Percona-Server-shared-55 = 5.5.15-rel21.0.1.fc15
Percona-Server-shared-55(x86-64) = 5.5.15-rel21.0.1.fc15

The key difference is this line, which IS in the mysql-libs package but is not in the Percona package.
libmysqlclient.so.18(libmysqlclient_16)(64bit)

By not providing that package, when you try to install another package that has a dependency it automatically wants to install mysql-libs. An example is php-mysql.

Also, the shared-compat package does not provide this either, here's what it provides:
# rpm -q --provides Percona-Server-shared-compat
MySQL-shared
libmysqlclient.so.12()(64bit)
libmysqlclient.so.14()(64bit)
libmysqlclient.so.14(libmysqlclient_14)(64bit)
libmysqlclient.so.15()(64bit)
libmysqlclient.so.15(libmysqlclient_15)(64bit)
libmysqlclient.so.16()(64bit)
libmysqlclient.so.16(libmysqlclient_16)(64bit)
libmysqlclient_r.so.12()(64bit)
libmysqlclient_r.so.14()(64bit)
libmysqlclient_r.so.14(libmysqlclient_14)(64bit)
libmysqlclient_r.so.15()(64bit)
libmysqlclient_r.so.15(libmysqlclient_15)(64bit)
libmysqlclient_r.so.16()(64bit)
libmysqlclient_r.so.16(libmysqlclient_16)(64bit)
mysql-libs
Percona-Server-shared-compat = 5.5.15-1.1.fc15
Percona-Server-shared-compat(x86-64) = 5.5.15-1.1.fc15

What I am now trying to figure out, which I can't yet put my finger on, is how to get the Percona package to provide this:
libmysqlclient.so.18(libmysqlclient_16)(64bit)

So I'm 99% of the way there and stuck on that one dependency.

Revision history for this message
Robert Brown (rjbrown99) (rjbrown99) wrote :

FWIW, here's how I am building things:
rpmbuild -ba --clean --with yassl --target x86_64 percona-server.spec --define "redhat_version 15" --define "gotrevision 1" --define "_libdir /usr/lib64"

My modified .spec is attached, which disables DTRACE, adds back a few paths (not sure if they are used or not..?) from the mysql.spec, and creates a .conf file in /etc/ld.so.conf.d. Still no ideas as to how to make the include work.

Revision history for this message
Robert Brown (rjbrown99) (rjbrown99) wrote :

I do not agree that this is a duplicate. DTRACE is only part of the problem - the dependency issue is separate and renders the current build as inoperable until that is resolved.

Stewart Smith (stewart)
Changed in percona-server:
importance: Undecided → Low
assignee: nobody → Ignacio Nin (ignacio-nin)
Stewart Smith (stewart)
tags: added: pkg
Revision history for this message
Robert Brown (rjbrown99) (rjbrown99) wrote :

For what it's worth, with my build instructions from #9 it does compile properly.

The dependencies from #8 are still a problem, but I did confirm that if I rebuild all of my other Fedora RPMS (with no other changes to those RPMS), they work fine and pick up the correct dependencies.

So, to make this work 'natively' with Fedora 15 the only real issue is to work out how to get the proper dependency from #8.

Revision history for this message
Raghavendra D Prabhu (raghavendra-prabhu) wrote :

Marking this a duplicate of lp:1050654 since it is related to "libmysqlclient.so.18(libmysqlclient_16)(64bit)"

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.