Well
Parse::RecDescent is one way of doing things. It's quite easy to write a parser with this and you can find plenty of info about it on the net. You can find 2 C grammars as part of the
Inline module, one is written with PRD above and the other is done with regexs it seems.