Visual Arts Press Blog

The all knowing, ever present VAP knowledge base

Archive for June, 2012

Setting up a Mac for Symfony using MacPorts

without comments

install xcode
install apple command line dev tools
install macports
> sudo xcode-select -switch /Applications/Xcode.app/
> sudo port install php5 +apache2 +mysql5 +pear
> cd /opt/local/apache2/modules
> sudo /opt/local/apache2/bin/apxs -a -e -n "php5" libphp5.so
> sudo port install mysql5-server
> sudo -u _mysql mysql_install_db5
> sudo /opt/local/bin/mysqld_safe5
> /opt/local/lib/mysql5/bin/mysqladmin -u root password 'svavap'
> sudo port install php5-gd
> sudo port install php5-iconv
> sudo port install php5-posix
> sudo port install php5-xml
> sudo port install php5-xsl
> sudo port install php5-mbstring
> sudo port install php5-apc
> sudo port install php5-mysql
> sudo port install php5-pear
> sudo port install php5-imap
> sudo port install git-core
Modify /opt/local/etc/php5/php.ini
To use mysqlnd with a local MySQL server, edit /opt/local/etc/php5/php.ini and set
mysql.default_socket, mysqli.default_socket and pdo_mysql.default_socket
to /opt/local/var/run/mysql5/mysqld.sock

Modify opt/local/apache2/httpd.conf
http://sf-to.org/1.4/check.php

> sudo mkdir /var/mysql
> sudo ln -s /opt
> sudo ln -s /opt/local/var/run/mysql5/mysqld.sock mysql/mysql.sock

sudo launchctl load -w  /Library/LaunchDaemons/org.macports.mysql5.plist
sudo launchctl load -w  /Library/LaunchDaemons/org.macports.apache2.plist

Written by ecorriel

June 8th, 2012 at 3:07 pm

Posted in admin