Can Chime be configured to process dtrace scripts with #includes in them? I''m in the process of adding a new display, and Chime doesn''t seem to run the preprocessor. It throws an "invalid control directive" error. Thanks, -ps
At first I thought the answer was simple: specify the "cpp" option in the Chime display description. Unfortunately it doesn''t work because Chime reads the contents of a program file into a string buffer then asks DTrace to compile the program as a string. I didn''t realize that the DTrace library ignores the "cpp" option when compiling a program string rather than a program file. I started treating program file contents as strings when I added program placeholders (like macro variables, but replaced by Chime rather than DTrace). I''m sorry, I should have answered this much sooner, but didn''t see it in my email. I''ll let you know as soon as there is a fix or a work-around for this issue. Thanks, Tom This message posted from opensolaris.org
This should work now with the latest Chime version: http://www.opensolaris.org/os/project/dtrace-chime/install/ In the wizard opened by the first toolbar button, go to step "5. Test Run the Display". There you can click the "Add" button to add a row under "DTrace Options" and select "cpp" from the pulldown. Or, if you are generating the display from the command line, use -xcpp. Or you can add the following to your .xml display description manually: <void property="options"> <array class="org.opensolaris.os.dtrace.Option" length="1"> <void index="0"> <object class="org.opensolaris.os.dtrace.Option"> <string>cpp</string> <string>set</string> </object> </void> </array> </void> Tom This message posted from opensolaris.org