[[HOWTO: Write an installation profile for the Drupal installer:http://drupal.org/node/67921]]
Patterns module:http://drupal.org/project/patterns
Patterns is an option, but there are other ways which are gaining popularity. For example drush (command line drupal - not a module) + features (module).
But also for install profiles there is this API helper module: http://drupal.org/project/install_profile_api
And here is another great page with example profiles: http://api.drupal.org/api/file/developer/example.profile/6
