0

I've upgraded to XCode 5.0.2 along with OS X 10.9 Mavericks and MYSQL 5.6.16 recently. Has anyone had any luck getting the MySQL Connector/C++ to compile and work properly with this setup?

I've been linking with the distributed MySQL Connector/C++ library under Snow Leopard with no problem for a few years now, but when I shifted to the above mentioned setup, I have no luck.

When I use the sql::Driver->connect I get EXC_BAD_ACCESS (code=EXC_I386_GPFLT)

USING:

  • XCode 5.0.2
  • Mavericks 10.9.2
  • MYSQL server 5.6.16 Mac OS X 10.7 (x86, 64-bit), DMG Archive
  • MYSQL Connector/C++ Mac OS X 10.7 (x86, 64-bit), Compressed TAR Archive
  • Boost 1.55

I saw the following post: MySQL Connector/C++ BAD ACCESS crash

So tried I downloading the MYSQL Connector/C++ source 1.1.3 and managed to get the 'static_test' subprogram to work, but the other tests fail with the same sql::Driver->connect returning NULL.

Anybody?

Community
  • 1
  • 1

1 Answers1

2

OK resolved.

The following post is the same problem:

MySQL Connector/C++ BAD ACCESS crash

Just in case someone else has this situation:


  1. I downloaded the MYSQL Connector/C++ source 1.1.13 and CMake
  2. I used the following command line to create a XCode project: cmake -G Xcode
  3. Compiled everything in XCode
  4. Copied the created libs into the mysqlconn/lib directory
Community
  • 1
  • 1
  • hello, I encountered the exactly same issue as yours. I followed the first 3 steps as your instructions. It works fine. But I am stuck at the step 4. I couldn't find the mysqlconn/lib directory. I google it but no answer is found. It's kind of frustrating. And there are so many files created by the project. Moreover, are the created libs are only referring to libmysqlcppconn.7.1.1.3.dylib and libmysqlcppconn-static.a? Thanks for your help. – Jeffrey Jun 17 '14 at 06:26
  • The directory is located in the local directory: /usr/local/mysqlcppconn/lib you'll probably need to use your terminal to get to that directory. Also, aside from the libs you mentioned, I create an alias named: libmysqlcppconn.dylib to point to libmysqlcppconn.7.1.1.3.dylib in the same dir. Hope that helps. – user3387130 Jun 18 '14 at 09:27
  • I cannot find /usr/local/mysqlcppconn/lib directory in my mac either by finder or by terminal. So I created this directory by myself and copied the libs you mentioned to that directory. But I still get the error: EXC_BAD_ACCESS (code=EXC_I386_GPFLT). Is that mysql directory supposed to be built by self? Or is there any other software I need to install? I only install the mysql-5.6.19-osx10.7-x86_64.dmg. But in the environment of Xcode 4 + mac 10.7, mysql works fine. Thanks. – Jeffrey Jun 18 '14 at 23:56
  • problem sovled. After I doing command: sudo ln -s /usr/local/mysql/lib/libmysqlclient.18.dylib /usr/lib/libmysqlclient.18.dylib : I had done this before, but I haven't done this after upgrading my system. Thanks so much! – Jeffrey Jun 19 '14 at 00:40