Detailed tutorials have been posted to the john-users list, separately for Linux (using Fedora 12 as the specific example) and for Solaris 10. These include optional OpenMP parallelization instructions and examples (to use multiple CPUs and/or CPU cores).
There are patches that add support for SHA-crypt (both its SHA-256 and its SHA-512 based flavor) using NVidia GPUs, currently implemented in CUDA - e.g., john-1.7.8-allcuda-0.3.diff is the latest as of this writing (August 2011). (There's also somewhat more experimental OpenCL code, currently for the SHA-256 based flavor only.)
You probably want to use John the Ripper 1.7.6 or newer for this - please see above. However, if you must:
This topic was brought up on john-users, got to YouTube, and someone wrote a blog article on it. Please refer to the latter.
It is not clear why the article proposes that the source files be edited manually instead of the patch being applied, so you may just do the latter. The patch itself may be downloaded from this wiki.
Also, if instructions from the article are followed “literally”, then the resulting shadowfile will possibly end up with mode 644 in a mode 755 home directory of a user - that is, readable to other users of the system used to crack/audit the passwords. To prevent this from happening, umask 077 should be issued before the sudo unshadow … command.
Back to John the Ripper tutorials.