No. Any government official can resign and run for public office after a lapse of two years according to the Constitution. But, a General out of uniform would lose his main power base. The constituency of a general is the Army. Take Musharraf for example. He couldn't survive as President for one year after giving up his uniform. Now that he is trying to stage a comeback into mainstream politics, it is almost impossible.
The parliamentary system of politics pretty much ensures that an individual alone cannot rise to the top of the Pakistani government - you need a very large political base spread throughout the country (or at least a base in the larger provinces) to get parliamentarians elected to office and then elect you as PM.
At the local level, especially where there is little media coverage of local issues and personalities (the larger cities get plenty of coverage), it'll be very hard for new candidates supporting this 'new leader' to get name recognition and outshine the established politicians from the mainstream parties, and offer themselves as a choice. Even when the established parties like the PPP and PML-N pick new candidates, they have their 'brand' to lend to new faces.
That is why Imran Khan, even if he gets elected to parliament himself, will have a tough time forming a government since he (AFAIK) has no effective grassroots political organization across Pakistan. His fan base is mostly amongst sections of the Urban middle class who are aware of him through the media. For him to be an effective politician, his party needs to start organizing and interacting with locals and articulating his platform (with IK travelling across the country to such gatherings) NOW in order to have any chance of success in the next elections. And he needs to start buying airtime on national TV promoting and explaining his vision and plans for addressing the day to day issues important to common Pakistanis.
On Musharraf - I think he would have been successful as a political leader had he not made the mistakes (dismissal of the judiciary, media crackdown) he did in 2007. Had he given up power in 2007 when it seemed the judiciary would not entertain his attempts at extending his rule, he could have used the PML-Q platform to become a national leader.
Still might happen though - Pakistanis have given Sharif and Bhutto two turns each in office despite their failures (though none of those elections were considered free and fair), so they may change their mind about Musharraf as well. He still has a fan base in the Middle Class like does IK.