These two threads describe excellent techniques for doing just that:
Advanced Version
Easy version
This one also helps:
Fixing ffmpeg on Ubuntu
The reason I had to do this in the first place was because I wanted to amplify the volume on the h264 encoded mp4 videos my digital camera recorded with the audio in aac format.
To increase the audio volume, simply do this:
ffmpeg -i infile.mp4 -vcodec libx264 -vol 2400 outfile.mp4
Where 2400 stands for increasing the audio volume by 2400% (yes, my microphone kind of sucks :/ )