[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
soot.PackAdjuster missing from soot 1.2.2 - how do we add our Packs
It looks like soot 1.2.2 is missing the soot.PackAdjuster class?
http://www.sable.mcgill.ca/soot/tutorial/phase-options
says:
"These transformers belong to a Pack. The Pack keeps a collection of
transformers, and can execute them, in order, when called. To add a
transformer to some Pack without modifying Soot itself, give an
alternate implementation of soot.PackAdjuster which modifies Packs as
needed. If you include this PackAdjuster in your CLASSPATH before the
default implementation, yours will be called by Java instead of Soot's
do-nothing implementation.."
soot.Main.java says:
/** Initializes various Soot data and calls the PackAdjuster.
* Must be called! */
public static void initApp()
{
packageInclusionFlags.add(new Boolean(false));
packageInclusionMasks.add("java.");
packageInclusionFlags.add(new Boolean(false));
packageInclusionMasks.add("sun.");
packageInclusionFlags.add(new Boolean(false));
packageInclusionMasks.add("javax.");
}
CHANGES says:
Improvements in 021400
...
7. Added soot.PackAdjuster and soot.jimple.StmtPrinter classes.
These classes can be overridden by placing custom classes with the
same names earlier in the CLASSPATH. This permits external classes
to be called by Soot at strategic moments in Soot's execution.
However, soot.PackAdjuster is not present in soot 1.2.2
What I'm trying to do is add a bunch of Transforms and use the command
line interface in soot.Main However, I don't see how we can add our
own Packs and still use the command line processing in soot.Main.
I'd rather not modify Soot.main, since I'd prefer that users download
the soot jar file and use it as is. Replicating Soot.main and adding
my changes is one solution, but seems like code duplication.
Any suggestions?
-Christopher
Christopher Hylands cxh@eecs.berkeley.edu University of California
Ptolemy/Gigascale Silicon Research Center US Mail: 558 Cory Hall #1770
ph: (510)643-9841 fax:(510)642-2739 Berkeley, CA 94720-1770
home: (510)526-4010 (Office: 400A Cory)