diff options
author | Yohann Roussel <yroussel@google.com> | 2014-09-08 14:45:14 +0200 |
---|---|---|
committer | Yohann Roussel <yroussel@google.com> | 2014-12-02 18:11:13 +0100 |
commit | b4c49cba57dafdcdfb693a549c5a1dc1beb71c25 (patch) | |
tree | 779bcaabb70535105c12058aa2a77d40be5a10a3 /core/config.mk | |
parent | 7fcb9209ac5823973053d954cf283a4485ad97de (diff) | |
download | build-b4c49cba57dafdcdfb693a549c5a1dc1beb71c25.zip build-b4c49cba57dafdcdfb693a549c5a1dc1beb71c25.tar.gz build-b4c49cba57dafdcdfb693a549c5a1dc1beb71c25.tar.bz2 |
Compile using Jack.
This allows to compile dex targeted java sources using Jack and Jill.
Default is still to compile with the legacy toolchain. Default can be
switched to the new toolchain by setting environement variable:
export ANDROID_COMPILE_WITH_JACK=true
Toolchain can also be forced for one module by defining
LOCAL_USE_JACK:=true # false
in the mk portion defining the module.
Jack execution environement can be controlled with:
Global variable ANDROID_JACK_VM allow to change the jvm executing Jack.
Global variable ANDROID_JACK_VM_ARGS allows to change default args given
to the jvm.
Global variable ANDROID_JACK_EXTRA_ARGS allows to define some default args
to give to Jack
LOCAL_JACK_VM_ARGS allows to override default args given to the jvm for
the module.
LOCAL_JACK_EXTRA_ARGS allows to override default args passed to Jack.
Change-Id: Ib81a0fd5f86a51d1e0edbb81cc791d828a05dd29
Diffstat (limited to 'core/config.mk')
-rw-r--r-- | core/config.mk | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/core/config.mk b/core/config.mk index c9453ef..358aa5e 100644 --- a/core/config.mk +++ b/core/config.mk @@ -365,6 +365,9 @@ endif # --------------------------------------------------------------- # Generic tools. +JACK_JAR := $(HOST_OUT_JAVA_LIBRARIES)/jack.jar +JILL_JAR := $(HOST_OUT_JAVA_LIBRARIES)/jill.jar +JACK_MULTIDEX_DEFAULT_PREPROCESSOR := frameworks/multidex/library/resources/JACK-INF/legacyMultidexInstallation.jpp LEX := prebuilts/misc/$(BUILD_OS)-$(HOST_PREBUILT_ARCH)/flex/flex-2.5.39 # The default PKGDATADIR built in the prebuilt bison is a relative path @@ -404,6 +407,18 @@ MKTARBALL := build/tools/mktarball.sh TUNE2FS := $(HOST_OUT_EXECUTABLES)/tune2fs$(HOST_EXECUTABLE_SUFFIX) E2FSCK := $(HOST_OUT_EXECUTABLES)/e2fsck$(HOST_EXECUTABLE_SUFFIX) JARJAR := $(HOST_OUT_JAVA_LIBRARIES)/jarjar.jar +# call jack +# +# $(1): vm +# $(2): vm arguments +# $(3): jack perf arguments +define call-jack +$(1) $(2) -cp $(JACK_JAR) com.android.jack.Main $(3) +endef +DEFAULT_JACK_VM := java +DEFAULT_JACK_VM_ARGS := -Dfile.encoding=UTF-8 -Xmx3584m -Xms2560m -XX:+TieredCompilation +DEFAULT_JACK_EXTRA_ARGS := -D sched.runner=single-threaded --sanity-checks off +JILL := java -Xmx3500m -cp $(JILL_JAR) com.android.jill.Main PROGUARD := external/proguard/bin/proguard.sh JAVATAGS := build/tools/java-event-log-tags.py LLVM_RS_CC := $(HOST_OUT_EXECUTABLES)/llvm-rs-cc$(HOST_EXECUTABLE_SUFFIX) |