Many factors can determine the answer.
First and foremost, what do you want to keep in the tank?
Secondly, will the bookcase take the combined weight of the aquarium, water, rock, sand, pumps, etc.
Third, what are your hobby goals? A nano tank is, in ways, more difficult than a large tank because of the small volume. Which can also mean more dedication to maintenance, especially for a heavier stocked tank.