Copyright (C) 2012 Sony Mobile Communications AB
This file is part of ApkAnalyser.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
==============================================================================
ApkAnalyser is a static, virtual analysis tool for examining and validating the development work of your Android app. It's a complete tool chain which supports modification of the binary application with more printouts. You are then able to repack, install, run and verify the result from logcat. ApkAnalyser also supports resource analysis, and you can decode XML, look up resource references and detect potential issues in your app.
Its a stand-alone J2SE application, released under Apache 2.0 license, 100% written in Java.
Some code of following OSS projects are imported and modified:
Following OSS projects are used as jar library:
Firstly, the latest ApkAnalyser is available at:
ApkAnalyser includes two open source projects, smali and apktool. The projects must be built in sequence of:
All of the projects are managed by Maven2 build system.
http://maven.apache.org/download.html
The project could be built on JDK1.5, 1.6 or 1.7.
Get the latest code git clone git://github.com/sonyxperiadev/ApkAnalyser.git
Build smali project cd smali mvn install
Build apktool project cd ../apktool mvn install
Install jgraphx into local Maven repository cd ../apkanalyser mvn install:install-file -Dfile=lib/jgraphx.jar -DgroupId=com.mxgraph -DartifactId=jgraphx -Dversion=1.7.1.9 -Dpackaging=jar -DgeneratePom=true
Build and package ApkAnalyser mvn assembly:assembly
The executable jar file should be at apkanalyser\target\apkanalyser-{version}-exec.jar
Optionally, Eclipse project could also be generated by "mvn eclipse:eclipse" command.
To launch it, just execute:
java -jar ApkAnalyser.jar
Sometimes, ApkAnalyser consumes lots of memory for analysing the dalvik bytecodes. It may run out of memory expecially for loading more than one big odexed APK files. In that case, the max heap size should be explicitly incrased by "-Xmx1024m" parameter:
java -Xmx1024m -jar ApkAnalyser.jar
Zhang Bojie, Sony Mobile Communications [email protected]