Compiling the standard distribution under OS X

Some of these instructions are based on recommendations from other Mac users who have compiled NEURON under OS X. Please let us know if you have additional suggestions.

Make sure the OS X Developer Tools have been installed.

The OS X Developer Tools provide the software compiler and linker needed to compile NEURON and NEURON's mod files.
1. You're going to use the Terminal application a lot.
If it isn't in your Dock already, open /Applications/Utilities, then find Terminal and drag it to the Dock.

2. Start the Terminal application. At its prompt, type the command

  gcc -v
If the response is
  gcc: command not found
then you need to install the OS X Developer Tools.

3. If you need to install the OS X Developer Tools, look in the Applications/Installers folder to see if the installer is already there. If it isn't, look on the CD-ROM that came with your Mac.

Note: in Mac OS X 10.2 (Jaguar), the default "Easy Install" of the Developers Tools is not sufficient--you need to customize the install so that that the BSD SDK is included also.

Installing NEURON itself

You need to run the Terminal application to execute the installation commands (e.g. gunzip). Terminal's launcher will be in your Dock if you followed the instructions above.
In the following, mm and nn signify the version numbers of the gzipped source files.

Full installation of NEURON with InterViews

0. Set the IDIR environment variable.
  IDIR=/Applications/NEURON-n.n

1. Create a neuron directory in your home directory, put the gzipped source files in it, and jump in after them.

  cd $HOME
  mkdir neuron
  mv iv-mm.tar.gz neuron
  mv nrn-nn.tar.gz neuron
  cd neuron
2. Install InterViews
  tar xzf iv-mm.tar.gz
  cd iv-mm
  ./configure --prefix=$IDIR/iv --enable-carbon # if this fails, you probably don't have the developer tools installed
  make
  make install
3. Install NEURON
  cd $HOME/neuron
  tar xzf nrn-nn.tar.gz
  cd nrn-nn
  ./configure --prefix=$IDIR/nrn --with-iv=$IDIR/iv --enable-carbon
  make
  make install
  make after_install
The program icons will be in /Applications/NEURON-n.n
You may drag them to the Dock, or make aliases to put on the Desktop.