I seem to be perfect to answer your question. I won the NPC Mr. CT title back in 2003 before my lungs decided to stop working.
The key to putting on ANY weight (whether fat or muscle) is to eat more than you burn. Your body is an energy system, so, to more calories that go into it, the more you will weigh. The best way to consume "quality" calories is through protein shakes, weight gain shakes, any kind of animal source protein, beef, chicken, fish, milk, whatever. Eating has to become a major priority especially since we don't absorb food as well as "normal" or rather, non-CFers, do. The plus side is that I can eat an entire bowl of chocolate pudding and never worry about being "fat"....what's that?
The tricky part is telling your body to put on muscle and not fat. To do this, simply put, you need to stimulate muscles to increase in size. Resistance training with weights, using a weight where achieving 8-12 repetitions is difficult, is the key. If you can do more than 12, it's too light. You should make sure you know how to properly perform any exercise because the last thing we need is an injury to worry about.
Let me know if you have any more specific questions. Thanks.