Can't make against Percona-Server-devel-55 headers

Bug #1326368 reported by DenisM on 2014-06-04
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MySQL Data Dumper
High
Max Bubenick

Bug Description

I use Percona Server 5.5. So I've installed Percona-Server-devel-55 rpm instead of mysql-devel.
Cmake is successful:

-- The C compiler identification is GNU
-- The CXX compiler identification is GNU
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Using mysql-config: /usr/bin/mysql_config
-- Found MySQL: /usr/include/mysql, /usr/lib64/libperconaserverclient_r.so;/usr/lib64/libpthread.so;/usr/lib64/libm.so;/usr/lib64/librt.so;/usr/lib64/libssl.so;/usr/lib64/libcrypto.so;/usr/lib64/libdl.so
-- Found ZLIB: /lib64/libz.so
-- checking for one of the modules 'glib-2.0'
-- found glib-2.0, version 2.12.3
-- checking for one of the modules 'gthread-2.0'
-- found gthread-2.0, version 2.12.3
-- checking for module 'libpcre'
-- found libpcre, version 6.6
-- Found PCRE: /usr/include
0
WARNINGSphinx is older than v1.0, not building docs
-- ------------------------------------------------
-- MYSQL_CONFIG = /usr/bin/mysql_config
-- CMAKE_INSTALL_PREFIX = /usr/local
-- BUILD_DOCS = ON
-- RUN_CPPCHECK = OFF
-- Change a values with: cmake -D<Variable>=<Value>
-- ------------------------------------------------
--
-- Configuring done
-- Generating done
-- Build files have been written to: /home/mdb/src/mydumper-0.6.1

But make fails:

Scanning dependencies of target mydumper
[ 20%] Building C object CMakeFiles/mydumper.dir/mydumper.c.o
[ 40%] Building C object CMakeFiles/mydumper.dir/binlog.c.o
[ 60%] Building C object CMakeFiles/mydumper.dir/server_detect.c.o
[ 80%] Building C object CMakeFiles/mydumper.dir/g_unix_signal.c.o
Linking C executable mydumper
CMakeFiles/mydumper.dir/mydumper.c.o: In function `dump_schema_data':
/home/mdb/src/mydumper-0.6.1/mydumper.c:1456: undefined reference to `mysql_query'
/home/mdb/src/mydumper-0.6.1/mydumper.c:1460: undefined reference to `mysql_error'
/home/mdb/src/mydumper-0.6.1/mydumper.c:1457: undefined reference to `mysql_errno'
/home/mdb/src/mydumper-0.6.1/mydumper.c:1458: undefined reference to `mysql_error'
/home/mdb/src/mydumper-0.6.1/mydumper.c:1456: undefined reference to `mysql_use_result'
/home/mdb/src/mydumper-0.6.1/mydumper.c:1471: undefined reference to `mysql_fetch_row'
CMakeFiles/mydumper.dir/mydumper.c.o: In function `estimate_count':
/home/mdb/src/mydumper-0.6.1/mydumper.c:1262: undefined reference to `mysql_real_escape_string'
......

Max Bubenick (max-bubenick) wrote :

try doing this change on CMakeLists.txt

${MYSQL_LIBRARIES_mysqlclient_r}

to

${MYSQL_LIBRARIES}

then

rm CMakeCache.txt
cmake .
make

Or try compiling from the trunk

bzr branch lp:mydumper

DenisM (b48) wrote :

The 1st hint didn't help:

$ cmake .

..............
CMake Warning at CMakeLists.txt:30 (add_executable):
  Cannot generate a safe runtime search path for target mydumper because
  files in some directories may conflict with libraries in implicit
  directories:

    runtime library [libpthread.so] in /usr/lib64 may be hidden by files in:
      /lib64

  Some of these libraries may not be found correctly.

CMake Warning at CMakeLists.txt:33 (add_executable):
  Cannot generate a safe runtime search path for target myloader because
  files in some directories may conflict with libraries in implicit
  directories:

    runtime library [libpthread.so] in /usr/lib64 may be hidden by files in:
      /lib64

  Some of these libraries may not be found correctly.

-- Generating done
-- Build files have been written to: /home/mdb/src/mydumper-0.6.1

$ make

Linking C executable mydumper
CMakeFiles/mydumper.dir/binlog.c.o: In function `get_binlog_file':
/home/mdb/src/mydumper-0.6.1/binlog.c:160: undefined reference to `my_net_read'
collect2: ld returned 1 exit status
make[2]: *** [mydumper] Error 1
make[1]: *** [CMakeFiles/mydumper.dir/all] Error 2
make: *** [all] Error 2

However, the trunk compiled successfully. Thanks a lot.

Changed in mydumper:
status: New → Fix Committed
assignee: nobody → Max Bubenick (max-bubenick)
milestone: none → 0.6.2
importance: Undecided → High
Changed in mydumper:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers