common/makefiles/JavaCompilation.gmk
Print this page
*** 40,51 ****
endif
FALSE_FIND_PATTERN:=-name FILE_NAME_THAT_DOESNT_EXIST
define SetupJavaCompiler
! # param 1 is for example BOOT_JAVAC or NEW_JAVAC
! # This is the name later used to decide which java compiler to use.
# param 2-9 are named args.
# JVM:=The jvm used to run the javac/javah command
# JAVAC:=The javac jar and bootstrap classpath changes, or just bin/javac if JVM is left out
# FLAGS:=Flags to be supplied to javac
# SERVER_DIR:=Use a javac server (-XDserver) and store the server related files here
--- 40,51 ----
endif
FALSE_FIND_PATTERN:=-name FILE_NAME_THAT_DOESNT_EXIST
define SetupJavaCompiler
! # param 1 is for example GENERATE_OLD_BYTECODE or GENERATE_NEW_JDKBYTECODE
! # This is the name of the compiler setup.
# param 2-9 are named args.
# JVM:=The jvm used to run the javac/javah command
# JAVAC:=The javac jar and bootstrap classpath changes, or just bin/javac if JVM is left out
# FLAGS:=Flags to be supplied to javac
# SERVER_DIR:=Use a javac server (-XDserver) and store the server related files here
*** 485,498 ****
endif
# Using sjavac to compile.
$1 := $$($1_ALL_COPY_TARGETS) $$($1_ALL_COPY_CLEAN_TARGETS) $$($1_BIN)/javac_state
! # Create SJAVAC variable,
! # expects $1_JAVAC to be "bootclasspathprepend -jar ...javac.jar"
! # and it is rewritten into "bootclasspathprepend com.sun.tools.sjavac.Main"
! $1_SJAVAC:=$$(word 1,$$($1_JAVAC)) -cp $$(word 3,$$($1_JAVAC)) com.sun.tools.sjavac.Main
# Set the $1_REMOTE to spawn a background javac server.
$1_REMOTE:=--server:portfile=$$($1_SJAVAC_PORTFILE),id=$1,sjavac=$$(subst $$(SPACE),%20,$$(subst $$(COMMA),%2C,$$(strip $$($1_SERVER_JVM) $$($1_SJAVAC))))
$$($1_BIN)/javac_state: $$($1_SRCS) $$($1_DEPENDS)
--- 485,498 ----
endif
# Using sjavac to compile.
$1 := $$($1_ALL_COPY_TARGETS) $$($1_ALL_COPY_CLEAN_TARGETS) $$($1_BIN)/javac_state
! # Create SJAVAC variable form JAVAC variable. Expects $1_JAVAC to be
! # "bootclasspathprepend -cp .../javac.jar com.sun.tools.javac.Main"
! # and javac is simply replaced with sjavac.
! $1_SJAVAC:=$$(subst com.sun.tools.javac.Main,com.sun.tools.sjavac.Main,$$($1_JAVAC))
# Set the $1_REMOTE to spawn a background javac server.
$1_REMOTE:=--server:portfile=$$($1_SJAVAC_PORTFILE),id=$1,sjavac=$$(subst $$(SPACE),%20,$$(subst $$(COMMA),%2C,$$(strip $$($1_SERVER_JVM) $$($1_SJAVAC))))
$$($1_BIN)/javac_state: $$($1_SRCS) $$($1_DEPENDS)