MAC Snow Leopard MySQL 32Bit to 64Bit

My MySQL Installation is copied from a 32Bit System to a new Snow Leopard System running with 64Bit.
While Installing some Daemons, i needed to upgrade MySQL to 64Bit.

I downloaded MySQL5 Package from here:


http://www.mysql.com/downloads/mysql/

I ran into some Issues, but at least this worked for me:

First Ive stopped running MySQL-Server:

sudo /Library/StartupItems/MySQLCOM/MySQLCOM stop
sudo gem uninstall mysql

I also had to remove mac ports because it did not work anymore

sudo rm -rf \
    /opt/local \
    /Applications/DarwinPorts \
    /Applications/MacPorts \
    /Library/LaunchDaemons/org.macports.* \
    /Library/Receipts/DarwinPorts*.pkg \
    /Library/Receipts/MacPorts*.pkg \
    /Library/StartupItems/DarwinPortsStartup \
    /Library/Tcl/darwinports1.0 \
    /Library/Tcl/macports1.0 \
    ~/.macports

Then I had to install mysql5-devel

sudo port install mysql5-devel

After that I was able to install the MySQL Gem with explicitly use of 64Bit architecture

sudo env ARCHFLAGS="-arch x86_64" gem install mysql -- --with-mysql-config=/usr/local/mysql/bin/mysql_config

After that i started MySQL again:

sudo /Library/StartupItems/MySQLCOM/MySQLCOM start

Leave a Reply

Your email address will not be published. Required fields are marked *

*

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>