Some people love the smell of old books. In fact, the smell can be quite pleasant, because one of the odors is related to a chemical found in vanilla.
Books will take on the unpleasant smells of their surroundings, perhaps cookbooks will take on food odors if stored in the kitchen. The International League of Antiquarian Booksellers explains how to get rid of unpleasant book odors. All you need is two containers, some odor absorbing materials (baking soda, charcoal briquettes, or even kitty litter), and time. Check it out.