mysqld is not built using usual cmake commands in recent 5.6

Bug #1260273 reported by Valerii Kravchuk on 2013-12-12
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Percona Server
Status tracked in 5.7
5.1
Undecided
Unassigned
5.5
High
Unassigned
5.6
High
Unassigned
5.7
High
Unassigned

Bug Description

With the following recent Percona Server 5.6 source that I've got from Launchpad:

openxs@ao756:~/bzr/percona-5.6$ bzr version-info
revision-id: <email address hidden>
date: 2013-12-03 07:54:17 +0200
build-date: 2013-12-12 12:53:09 +0200
revno: 508
branch-nick: percona-5.6

I can not get mysqld binary created (only mysqld-debug) using usual build steps:

...
[100%] Built target mysqlshow
Scanning dependencies of target mysqlslap
[100%] Building C object client/CMakeFiles/mysqlslap.dir/mysqlslap.c.o
Linking CXX executable mysqlslap
[100%] Built target mysqlslap
Scanning dependencies of target mysqltest
[100%] Building CXX object client/CMakeFiles/mysqltest.dir/mysqltest.cc.o
Linking CXX executable mysqltest
[100%] Built target mysqltest
Scanning dependencies of target mysql_tzinfo_to_sql
[100%] Building CXX object sql/CMakeFiles/mysql_tzinfo_to_sql.dir/tztime.cc.o
Linking CXX executable mysql_tzinfo_to_sql
[100%] Built target mysql_tzinfo_to_sql
[100%] Building CXX object sql/CMakeFiles/mysqld.dir/main.cc.o
Linking CXX executable mysqld-debug
[100%] Built target mysqld
[100%] Building CXX object sql/CMakeFiles/udf_example.dir/udf_example.cc.o
Linking CXX shared module udf_example.so
[100%] Built target udf_example
[100%] Building CXX object mysql-test/lib/My/SafeProcess/CMakeFiles/my_safe_process.dir/safe_process.cc.o
Linking CXX executable my_safe_process
[100%] Built target my_safe_process
openxs@ao756:~/bzr/percona-5.6/Percona-Server-5.6.14-rel62.0$ find . -name mysqld
openxs@ao756:~/bzr/percona-5.6/Percona-Server-5.6.14-rel62.0$ find . -name mysqld-debug
./sql/mysqld-debug
openxs@ao756:~/bzr/percona-5.6/Percona-Server-5.6.14-rel62.0$ make mysqld
[ 6%] Built target strings
[ 8%] Built target taocrypt
[ 11%] Built target zlib
[ 12%] Built target yassl
[ 26%] Built target mysys
[ 26%] Built target dbug
[ 27%] Built target mysys_ssl
[ 27%] Built target comp_err
[ 27%] Built target GenError
[ 28%] Built target slave
[ 31%] Built target binlog
[ 31%] Built target gen_lex_hash
[ 31%] Built target GenServerSource
[ 31%] Built target archive
[ 38%] Built target myisam
[ 38%] Built target blackhole
[ 56%] Built target innobase
[ 60%] Built target heap
[ 62%] Built target myisammrg
[ 62%] Built target federated
[ 62%] Built target csv
[ 62%] Built target gen_pfs_lex_token
[ 73%] Built target perfschema
[ 75%] Built target vio
[ 76%] Built target regex
[ 76%] Built target partition
[ 98%] Built target sql
[ 98%] Built target rpl
[100%] Built target master
[100%] Built target mysqld
openxs@ao756:~/bzr/percona-5.6/Percona-Server-5.6.14-rel62.0$ find . -name mysqld
openxs@ao756:~/bzr/percona-5.6/Percona-Server-5.6.14-rel62.0$

Build steps where like these (from fc -l):

...
1806 cd bzr/percona-5.6
1807 make
1808 export CFLAGS="-O2 -g -fmessage-length=0 -D_FORTIFY_SOURCE=2"
1809 export CXXFLAGS="-O2 -g -fmessage-length=0 -D_FORTIFY_SOURCE=2"
1810 export LIBS=-lrt
1811 cd Percona-Server-5.6.14-rel62.0
1812 cmake . -DCMAKE_BUILD_TYPE=RelWithDebInfo -DBUILD_CONFIG=mysql_release -DFEATURE_SET=community -DWITH_EMBEDDED_SERVER=OFF -DCMAKE_INSTALL_PREFIX=/home/openxs/dbs/p5.6
1813 make
1814 find . -name mysqld
1815 find . -name mysqld-debug
1816 make mysqld
...

There is no problem with 5.5 using the same cmake flags, and there was no problem like this with older PS 5.6.x (5.6.12 at least)

Some details about the build environment:

openxs@ao756:~/bzr/percona-5.6/Percona-Server-5.6.14-rel62.0$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=13.04
DISTRIB_CODENAME=raring
DISTRIB_DESCRIPTION="Ubuntu 13.04"
openxs@ao756:~/bzr/percona-5.6/Percona-Server-5.6.14-rel62.0$ gcc --version
gcc (Ubuntu/Linaro 4.7.3-1ubuntu1) 4.7.3
Copyright (C) 2012 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

openxs@ao756:~/bzr/percona-5.6/Percona-Server-5.6.14-rel62.0$ cmake --version
cmake version 2.8.10.1

tags: added: regression

This is due to cmake changes which make Debug or ReleaseWithDeb
build binaries to be mysqld-debug. Though, in this case a
symlink may be required (which it doesn't do), so may be a bug.

Well, mysql_install_db generated in the process does NOT work as it can not find mysqld. Yes, symlink or just cp solves the problem, but cmake should produce something that is usable "as is" after "make install". It's definitely a bug to fix.

Valerii -

Is this our or upstream bug?

It is NOT an upstream bug, from what I see. I've built 5.6.15 with the same cmake options and I do see mysqld instead of mysqld-debug.

tags: added: pkg
Alexey Kopytov (akopytov) wrote :
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers