Android: remove --no-daemon arg for Gradle
Allow Gradle builds to run using JVM daemon, this will improve the current build time noticeably for clean builds and hugely for incremental builds. This will bring the Gradle build to comparable speed with a normal Gradle build in Android Studio. Task-number: QTBUG-86674 Pick-to: 5.15 Change-Id: Icc4267223802e4c9350b48099236650c023f868d Reviewed-by: Andy Shaw <andy.shaw@qt.io>
This commit is contained in:
parent
8d8b271fe9
commit
615b92008a
1
src/3rdparty/gradle/CMakeLists.txt
vendored
1
src/3rdparty/gradle/CMakeLists.txt
vendored
@ -6,6 +6,7 @@ qt_copy_or_install(
|
||||
FILES
|
||||
gradlew
|
||||
gradlew.bat
|
||||
gradle.properties
|
||||
DESTINATION
|
||||
"${destination}"
|
||||
)
|
||||
|
3
src/3rdparty/gradle/gradle.pro
vendored
3
src/3rdparty/gradle/gradle.pro
vendored
@ -4,7 +4,8 @@ CONFIG -= qt android_install
|
||||
|
||||
gradle_files.files = \
|
||||
$$PWD/gradlew \
|
||||
$$PWD/gradlew.bat
|
||||
$$PWD/gradlew.bat \
|
||||
$$PWD/gradle.properties
|
||||
gradle_dirs.files = \
|
||||
$$PWD/gradle
|
||||
|
||||
|
9
src/3rdparty/gradle/gradle.properties
vendored
Normal file
9
src/3rdparty/gradle/gradle.properties
vendored
Normal file
@ -0,0 +1,9 @@
|
||||
# Project-wide Gradle settings.
|
||||
# For more details on how to configure your build environment visit
|
||||
# http://www.gradle.org/docs/current/userguide/build_environment.html
|
||||
# Specifies the JVM arguments used for the daemon process.
|
||||
# The setting is particularly useful for tweaking memory settings.
|
||||
org.gradle.jvmargs=-Xmx2048m
|
||||
|
||||
# Enable Gradle caching
|
||||
org.gradle.caching=true
|
@ -51,6 +51,10 @@ android {
|
||||
}
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile) {
|
||||
options.incremental = true
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
@ -2445,7 +2445,7 @@ bool buildAndroidProject(const Options &options)
|
||||
return false;
|
||||
}
|
||||
|
||||
QString commandLine = QLatin1String("%1 --no-daemon %2").arg(shellQuote(gradlePath), options.releasePackage ? QLatin1String(" assembleRelease") : QLatin1String(" assembleDebug"));
|
||||
QString commandLine = QLatin1String("%1 %2").arg(shellQuote(gradlePath), options.releasePackage ? QLatin1String(" assembleRelease") : QLatin1String(" assembleDebug"));
|
||||
if (options.buildAAB)
|
||||
commandLine += QLatin1String(" bundle");
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user