# Distributions

Mac OS X Distribution.
For Mac OS X, Cain is distributed as an application bundle. The Python source code and the command line executables are placed in a folder called `Cain.app`. From the Finder, this appears as an application called Cain. You can make the application bundle by executing `make bundle` in `stlib/applications/stochastic`. This copies the appropriate content into the `Cain.app/Contents/Resources` directory. I pack the application bundle and example data files (in `stlib/data/stochastic`) into a disk image for easy distribution.

To make a disk image, use Disk Utility. Click New Image and make a 40 MB image called Cain. Quit Disk Utility. In the mounted devices, changed the name to Cain. Drag the application bundle to the disk image. Rename the data folder "stochastic" to "CainExamples". Remove the folder "CainExamples/sbml/bmd-2007-9-25". Drag the data folder to the disk image. Finally, eject the disk image.

Microsoft Windows Distribution.
For MS Windows, Cain is distributed as a frozen executable. I use py2exe to accomplish this. (See that web site for details on how the Python interpreter and the Python source are packed into a stand-alone executable.) Execute `make win` in `stlib/applications/stochastic` to build the Cain executable in the `dist` directory. I use Inno Setup to make an installer.