https://github.com/rochus-keller/FreePascalBeen dabbling with that sometime ago and is the best yet. Do not use on trunk, though.
(And I wonder why he used C++, this could all be done in FreePascal. Seems he used some older project)
With fpc itself:
To get the parse tree, compile with -vp option. Generates a file called tree.log.
This is not enough to create a syntax tree for the whole language.
I have an adapted D7 grammar -for Gold - that parses most, but not all constructs associated with {$mode delphi} if that helps, but that won't work for {$mode objfpc}
You may also want to look at the parser that Lazarus uses, which is a very modified version of mwparser.
You can also have a look at the Castalia parser wich also has roots in TmwParser. I have translated that to fpc, but also does not parse objfpc, only mode delphi.
I guess the Lazarus parser or fcl-passrc are your best options, besides the standard fpc-ebnf (with a grammar) and fcl-passrc packages.
fcl-passrc is used for pas2js and parses 99% or so.