liblit / wala Goto Github PK
View Code? Open in Web Editor NEWThis project forked from wala/wala
T.J. Watson Libraries for Analysis
Home Page: http://wala.sourceforge.net
License: Eclipse Public License 2.0
This project forked from wala/wala
T.J. Watson Libraries for Analysis
Home Page: http://wala.sourceforge.net
License: Eclipse Public License 2.0
The absolute path to each shared library that is a build target is computed by Gradle itself. Each prebuilt (system-installed) shared library gives this information when setting sharedLibraryLinkFile
:
WALA/com.ibm.wala.cast/build.gradle
Line 42 in 4374ead
The dirname
s of these paths also appear as part of -Wl,-rpath
flags wherever we link these shared libraries:
WALA/com.ibm.wala.cast.test/build.gradle
Lines 62 to 65 in 4374ead
WALA/com.ibm.wala.cast.test/build.gradle
Lines 80 to 83 in 4374ead
WALA/com.ibm.wala.cast/build.gradle
Lines 69 to 70 in 4374ead
It would be cleaner to derive -Wl,-rpath
paths from sharedLibraryLinkFile
paths instead of repeating them. I have asked how to do this in the Gradle discussion forum, but have not yet received any replies.
The build.gradle
scripts are mostly platform-independent, but not entirely. To build and test WALA on MacOS, we at least need to fill in the path to the Java dynamic library:
WALA/com.ibm.wala.cast/build.gradle
Lines 44 to 46 in 4374ead
Other fixes might be needed too; we won’t know until we try it and see what breaks.
That being said, is WALA itself even supported on MacOS? If not, then this whole issue is moot and may as well be relabeled wontfix
.
The build.gradle
scripts are mostly platform-independent, but not entirely. To build and test WALA on Windows, we at least need to fill in the path to the Java dynamic library:
WALA/com.ibm.wala.cast/build.gradle
Lines 48 to 50 in 4374ead
Other fixes might be needed too; we won’t know until we try it and see what breaks.
That being said, is WALA itself even supported on Windows? If not, then this whole issue is moot and may as well be relabeled wontfix
.
The Maven build system does something involving Eclipse plug-in packaging. I honestly do not understand any of this in the slightest. It seems to involve .p2
directories, */build.properties
files, */META-INF/MANIFEST.MF
files, */OSGI-INF/l10n/bundle.properties
files, and I can only guess what else. I am completely lost here. Whatever sort of over-engineered Eclipse packaging Maven is doing, Gradle will need to do the same before the latter can replace the former. Halp! 😱
Any WALA maintainer who knows how this all fits together is strongly urged to lend a hand. I am happy to work with you: perhaps we can take this issue down by combining what I have learned about Gradle with what you know about Eclipse.
Using ./gradlew javadoc
to build Javadoc documentation leads to more than two dozen warnings:
com.ibm.wala.util/src/com/ibm/wala/util/collections/Util.java:163: warning - Tag @link: reference not found: java.lang.reflect reflection
com.ibm.wala.util/src/com/ibm/wala/util/collections/Util.java:181: warning - Tag @link: reference not found: java.lang.reflect reflection
com.ibm.wala.core/src/com/ibm/wala/util/ssa/TypeSafeInstructionFactory.java:112: warning - Tag @see: can't find InvokeInstruction(int, int, int[], int, CallSiteReference, BootstrapMethod) in com.ibm.wala.classLoader.JavaLanguage.JavaInstructionFactory
com.ibm.wala.core/src/com/ibm/wala/util/ssa/TypeSafeInstructionFactory.java:224: warning - Tag @see: can't find InvokeInstruction(int, int[], int, CallSiteReference, BootstrapMethod) in com.ibm.wala.classLoader.JavaLanguage.JavaInstructionFactory
com.ibm.wala.core/src/com/ibm/wala/ipa/callgraph/propagation/SSAPropagationCallGraphBuilder.java:193: warning - Tag @see: can't find addConstraintsFromNode(com.ibm.wala.ipa.callgraph.CGNode) in com.ibm.wala.ipa.callgraph.propagation.PropagationCallGraphBuilder
com.ibm.wala.core/src/com/ibm/wala/ipa/summaries/VolatileMethodSummary.java:86: warning - Tag @link: can't find getStatementsAfter(int) in com.ibm.wala.ipa.summaries.VolatileMethodSummary
com.ibm.wala.core/src/com/ibm/wala/ipa/summaries/VolatileMethodSummary.java:86: warning - Tag @see: reference not found: com.ibm.wala.dalvik.ssa.AndroidModelInstructionFectory
com.ibm.wala.core/src/com/ibm/wala/ipa/summaries/VolatileMethodSummary.java:86: warning - Tag @see: reference not found: com.ibm.wala.dalvik.ipa.callgraph.impl.DexFakeRootMethod
com.ibm.wala.core/src/com/ibm/wala/ipa/summaries/VolatileMethodSummary.java:445: warning - Tag @link: can't find isUsed(ProgramCounter) in com.ibm.wala.ipa.summaries.VolatileMethodSummary
com.ibm.wala.core/src/com/ibm/wala/ipa/summaries/VolatileMethodSummary.java:237: warning - Tag @link: can't find isFree(boolean) in com.ibm.wala.ipa.summaries.VolatileMethodSummary
com.ibm.wala.core/src/com/ibm/wala/ipa/summaries/VolatileMethodSummary.java:237: warning - Tag @link: can't find isFree(boolean) in com.ibm.wala.ipa.summaries.VolatileMethodSummary
com.ibm.wala.core/src/com/ibm/wala/ipa/summaries/VolatileMethodSummary.java:259: warning - Tag @link: can't find addStatement(SSAInstructionWithPC) in com.ibm.wala.ipa.summaries.VolatileMethodSummary
com.ibm.wala.core/src/com/ibm/wala/ipa/summaries/VolatileMethodSummary.java:583: warning - Tag @link: can't find getFactory() in com.ibm.wala.ipa.summaries.VolatileMethodSummary
com.ibm.wala.core/src/com/ibm/wala/ipa/summaries/VolatileMethodSummary.java:607: warning - Tag @link: can't find getStatic() in com.ibm.wala.ipa.summaries.VolatileMethodSummary
com.ibm.wala.core/src/com/ibm/wala/ipa/summaries/VolatileMethodSummary.java:349: warning - Tag @link: can't find overwritetatement(SSAInstruction) in com.ibm.wala.ipa.summaries.VolatileMethodSummary
com.ibm.wala.core/src/com/ibm/wala/ssa/SSAPhiInstruction.java:153: warning - Tag @see: can't find getValueString(SymbolTable, ValueDecorator, int) in com.ibm.wala.ssa.SSAInstruction
com.ibm.wala.cast/source/java/com/ibm/wala/cast/ipa/callgraph/GlobalObjectKey.java:29: warning - Tag @see: reference not found: JSSSAPropagationCallGraphBuilder
com.ibm.wala.cast.js/source/com/ibm/wala/cast/js/ipa/callgraph/JSSSAPropagationCallGraphBuilder.java:111: warning - Tag @link: reference not found: org.mozilla.javascript.RhinoToAstTranslator
com.ibm.wala.dalvik/src/com/ibm/wala/dalvik/ipa/callgraph/androidModel/stubs/Overrides.java:79: warning - Tag @see: reference not found: com.ibm.wala.dalvik.ipa.callgraph.propagation.cfa
com.ibm.wala.dalvik/src/com/ibm/wala/dalvik/ipa/callgraph/impl/AndroidEntryPoint.java:219: warning - Tag @link: can't find after(IExecutionOrder) in com.ibm.wala.dalvik.ipa.callgraph.impl.AndroidEntryPoint.ExecutionOrder
com.ibm.wala.dalvik/src/com/ibm/wala/dalvik/ipa/callgraph/impl/AndroidEntryPoint.java:219: warning - Tag @link: can't find between(IExecutionOrder, IExecutionOrder) in com.ibm.wala.dalvik.ipa.callgraph.impl.AndroidEntryPoint.ExecutionOrder
com.ibm.wala.dalvik/src/com/ibm/wala/dalvik/ipa/callgraph/impl/AndroidEntryPoint.java:364: warning - Tag @link: can't find after(IExecutionOrder) in com.ibm.wala.dalvik.ipa.callgraph.impl.AndroidEntryPoint.ExecutionOrder
com.ibm.wala.dalvik/src/com/ibm/wala/dalvik/ipa/callgraph/impl/AndroidEntryPoint.java:311: warning - Tag @link: can't find between(IExecutionOrder, IExecutionOrder) in com.ibm.wala.dalvik.ipa.callgraph.impl.AndroidEntryPoint.ExecutionOrder
com.ibm.wala.dalvik/src/com/ibm/wala/dalvik/ipa/callgraph/impl/AndroidEntryPoint.java:277: warning - Tag @link: can't find between(IExecutionOrder[], IExecutionOrder[]) in com.ibm.wala.dalvik.ipa.callgraph.impl.AndroidEntryPoint.ExecutionOrder
com.ibm.wala.dalvik/src/com/ibm/wala/dalvik/ipa/callgraph/androidModel/structure/AbstractAndroidModel.java:170: warning - Tag @link: can't find enter(ExecutionOrder, int) in com.ibm.wala.dalvik.ipa.callgraph.androidModel.structure.AbstractAndroidModel
com.ibm.wala.dalvik/src/com/ibm/wala/dalvik/ipa/callgraph/androidModel/stubs/package-info.java:56: warning - Tag @see: reference not found: com.ibm.wala.dalvik.ipa.callgraph.propagation.cfa
Some of these should go away once wala#277 is merged, so it is probably not worth working on this until that merge happens. Once the merge is done, any remaining Javadoc build warnings should be investigated and either repaired or suppressed.
Use ./gradelw test
to run WALA’s automated regression tests. Several test suite subprojects pass completely. However, at least the following fail:
com.ibm.wala.cast.js.rhino.test
com.ibm.wala.cast.js.test
com.ibm.wala.core.tests
DynamicCallGraphTest
GetTargetsTest
PruneArrayOutOfBoundExceptionEdge
com.ibm.wala.dalvik.test
DynamicDalvikComparisonTestForAndroidLibs
com.ibm.wala.ide.jdt.test
ECJJavaIRTest
ECJSyncDuplicatorTest
JDTJava15IRTests
JDTJavaIRTests
com.ibm.wala.ide.jsdt.tests
JSProjectScopeTest
I believe that many of these failures are due to resource path / class loader problems. WALA tests commonly need to find other files within the WALA source tree, and use Java class loader facilities to do that. In order for that process to work, Gradle needs to copy the appropriate files into the appropriate run-time resource directories, Gradle needs to set run-time class paths to include those directories, and the test code itself needs to use class loaders that use those class paths.
For the test suites that pass, I have already successfully gotten the class loaders to find the right resources. For the test suites that fail, I am apparently not yet doing this correctly. Some of the testing infrastructure uses class loaders in complex ways, so here I will probably need help from more-experienced WALA maintainers.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.