mirror of
https://github.com/revanced/Apktool.git
synced 2025-01-10 20:15:52 +01:00
update build.gradle to handle patching smali
This commit is contained in:
parent
7786ba6fdd
commit
ca917cf103
42
build.gradle
42
build.gradle
@ -13,12 +13,31 @@
|
|||||||
* See the License for the specific language governing permissions and
|
* See the License for the specific language governing permissions and
|
||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
buildscript {
|
||||||
|
repositories {
|
||||||
|
jcenter()
|
||||||
|
}
|
||||||
|
tasks.withType(JavaCompile) {
|
||||||
|
options.encoding = "UTF-8"
|
||||||
|
options.incremental = true
|
||||||
|
}
|
||||||
|
dependencies {
|
||||||
|
classpath 'eu.appsatori:gradle-fatjar-plugin:0.3'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
plugins {
|
||||||
|
id 'net.minecrell.gitpatcher' version '0.7.1'
|
||||||
|
}
|
||||||
|
|
||||||
apply plugin: 'maven'
|
apply plugin: 'maven'
|
||||||
apply from: 'gradle/functions.gradle'
|
apply from: 'gradle/functions.gradle'
|
||||||
|
|
||||||
def apktoolversion_major = '2.0.3'
|
def apktoolversion_major = '2.0.3'
|
||||||
def apktoolversion_minor = 'SNAPSHOT';
|
def apktoolversion_minor = 'SNAPSHOT';
|
||||||
|
|
||||||
|
defaultTasks 'clean', 'applyPatches', 'build', 'fatJar', 'proguard'
|
||||||
|
|
||||||
allprojects {
|
allprojects {
|
||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
sourceCompatibility = 1.7
|
sourceCompatibility = 1.7
|
||||||
@ -58,6 +77,14 @@ build.doFirst {
|
|||||||
"Currently it is set to: " + System.getProperty("java.home")
|
"Currently it is set to: " + System.getProperty("java.home")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
println 'Applying smali patches...'
|
||||||
|
rootProject.tasks.applyPatches
|
||||||
|
}
|
||||||
|
|
||||||
|
clean.doFirst {
|
||||||
|
delete "${rootDir}/brut.apktool.smali"
|
||||||
|
println "deleting ${rootDir}/brut.apktool.smali in favor of smali"
|
||||||
}
|
}
|
||||||
|
|
||||||
task wrapper(type: Wrapper) {
|
task wrapper(type: Wrapper) {
|
||||||
@ -68,17 +95,10 @@ task wrapper(type: Wrapper) {
|
|||||||
task release {
|
task release {
|
||||||
}
|
}
|
||||||
|
|
||||||
buildscript {
|
patches {
|
||||||
repositories {
|
submodule = 'smali'
|
||||||
jcenter()
|
target = file('brut.apktool.smali')
|
||||||
}
|
patches = file('gradle/smali-patches')
|
||||||
tasks.withType(JavaCompile) {
|
|
||||||
options.encoding = "UTF-8"
|
|
||||||
options.incremental = true
|
|
||||||
}
|
|
||||||
dependencies {
|
|
||||||
classpath 'eu.appsatori:gradle-fatjar-plugin:0.3'
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
subprojects {
|
subprojects {
|
||||||
|
Loading…
Reference in New Issue
Block a user