Hi GP
Welcome to MacRumors.
Have a look with the Search function of MacRumors, this question has been covered several times.
You can plug the output of a guitar into the micrphone input of a Mac with a 1/4" to 3.5 mm adaptor on the guitar cable; this will result in a thin, tweezy and unpleasant sound, because of a mismatch in impedance, and the fact that an electic guitar sound is hugely influenced by the preamp, amp and speaker of a guitar amplifier. A more successful way would be to put a microphone on the speaker of a guitar amp and play through that.
There are a number of interfaces that can help get audio into a Mac, and some of them include special treatment for guitar, to simulate amplification, speakers, and effects (distortion, echo, phasing, flanging, etc.)
The cheapest solution may be the JamPlug or GuitarPlug from DVForge, however, their page seems to be offline and redirects to MacMice.
Some of the many USB and Firewire audio digital interfaces (search this subforum) have high-impedance inputs for guitar.
If you have a few hundred dollars to spend, you could look at the
M-Audio BlackBox, which functions as a standalone guitar effects unit, amp simulator, as well as a USB audio interface to your Mac, with both guitar and microphone input. The
Line6 TonePorts are similar, and Native Instruments
GuitarRig is a more expensive product along the same lines.
Thanks
Trevor
CanadaRAM.com