On Mon, Nov 19, 2007 at 08:25:39PM -0800, Rich Morin wrote: > At 20:00 -0800 11/19/07, Mike Shapiro wrote: > > Ah. Apologies for not asking about the platform up front. > > Now that we run everywhere I need to ask that :) > > Not quite everywhere yet, but it's clearly on a roll... > > > > This is likely a porting bug in the MacOS X DTrace. Sun's cpp > > uses a different control line syntax from GNU cpp and I haven't > > yet modified the common DTrace code to understand both of them. > > Ah. > > > Apple guys: can you comment on whether you modified dt_pragma.c > > to understand GCC cpp, which I assume is your default cpp? > > Or please post the code to your latest stuff somewhere. > > Apple has an online source code repository for Darwin, etc, but I > don't know how current it is kept with their binary releases. > > > You will need to modify that. If you haven't done so I can > > give you a quick sketch of what will need to be done there. > > Erm, was this addressed to the "Apple guys" or to me? In any case, > perhaps you could help me to work around the problem while waiting > for Apple to get on board with a fix. > > I gather that the problem is not that cpp can't process the code, > nor that the results wouldn't work if it did, but that cpp isn't > being given command-line options it understands. However, I'm a > bit rusty on cpp, so I'm concerned that the "cpp -C" output I'm > creating might not play nicely with dtrace (like, what about the > lines that start with "#"?). > > So, can you give me a set of commands that will (say) cause cpp to > process my files into vanilla D code, then tell dtrace to use that > code? BTW, many thanks for all the help, guys! > > -r
I was referring to the Apple DTrace developers, some of whom are on this alias. They need to help us debug this or point me to their source. In terms of workarounds just run the script through whatever preprocessor you like, get the result, and skip the -C part. -Mike -- Mike Shapiro, Solaris Kernel Development. blogs.sun.com/mws/ _______________________________________________ dtrace-discuss mailing list [email protected]
