title: I cannot build the application because of glibc and libmysqlclient
body: <p>I have an application on my computer and when I try to build it, it says that</p>
  
  <pre><code>/usr/lib/gcc/x86_64-linux-gnu/4.9/../../../x86_64-linux-gnu/libmysqlclient.a(client_plugin.c.o): In function `mysql_load_plugin_v':
  (.text+0x466): warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
  /usr/lib/gcc/x86_64-linux-gnu/4.9/../../../x86_64-linux-gnu/libmysqlclient.a(mf_pack.c.o): In function `unpack_dirname':
  (.text+0x7ab): warning: Using 'getpwnam' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
  /usr/lib/gcc/x86_64-linux-gnu/4.9/../../../x86_64-linux-gnu/libmysqlclient.a(libmysql.c.o): In function `read_user_name':
  (.text+0x2488): warning: Using 'getpwuid' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
  /usr/lib/gcc/x86_64-linux-gnu/4.9/../../../x86_64-linux-gnu/libmysqlclient.a(mf_pack.c.o): In function `unpack_dirname':
  (.text+0x7b7): warning: Using 'endpwent' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
  /usr/lib/gcc/x86_64-linux-gnu/4.9/../../../x86_64-linux-gnu/libmysqlclient.a(client.c.o): In function `mysql_real_connect':
  (.text+0x3e71): warning: Using 'getaddrinfo' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
  /usr/lib/gcc/x86_64-linux-gnu/4.9/../../../x86_64-linux-gnu/libmysqlclient.a(libmysql.c.o): In function `mysql_server_init':
  (.text+0x224e): warning: Using 'getservbyname' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
  /usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/4.9/libstdc++.a(eh_globals.o): undefined reference to symbol '__tls_get_addr@@GLIBC_2.3'
  //lib/x86_64-linux-gnu/ld-linux-x86-64.so.2: error adding symbols: DSO missing from command line
  collect2: error: ld returned 1 exit status
  make[3]: *** [app] Error 1
  make[2]: *** [CMakeFiles/app.dir/all] Error 2
  make[1]: *** [CMakeFiles/app.dir/rule] Error 2
  make: *** [app] Error 2
  *** Failure: Exit code 2 ***
  </code></pre>
  
  <p>I cannot figure out what is happening, because glibc is installed:</p>
  
  <pre><code>$ ldd --version
  ldd (Ubuntu EGLIBC 2.19-0ubuntu6.6) 2.19
  Copyright (C) 2014 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.
  Written by Roland McGrath and Ulrich Drepper.
  </code></pre>
  
  <p>and libmysqlclient is also installed:</p>
  
  <pre><code>$ sudo apt-get install libmysqlclient-dev
  Reading package lists... Done
  Building dependency tree       
  Reading state information... Done
  libmysqlclient-dev is already the newest version.
  The following packages were automatically installed and are no longer required:
    linux-headers-3.13.0-45 linux-headers-3.13.0-45-generic
    linux-image-3.13.0-45-generic linux-image-extra-3.13.0-45-generic
  Use 'apt-get autoremove' to remove them.
  0 upgraded, 0 newly installed, 0 to remove and 20 not upgraded.
  </code></pre>
  
  <p>Any help please?</p>