This is a good step by step post on how to configure virtual hosts on how to configure MAMP to run with virtual hosts.
I was trying to install Ubercart Drupal module on my local MAMP install on my Mac. The reason for this was clear, not enough memory allocated
Edit the following line in APPLICATIONS/MAMP/conf/php5/php.ini
memory_limit = 8M ; Maximum amount of memory a script may consume (8MB)
I increased my memory to 16MB and it seemed to do the trick